NAV undefined
undefined O'zbekcha English Русский
bash

Kirish

Api Url http://api.bts.uz:8080/index.php

Version 1.0 End point http://api.bts.uz:8080/index.php

Mahalliy Buyurtmalar

Buyurtma yaratish

curl
--request POST \
--url "http://api.bts.uz:8080/index.php?r=v1/order/add" \
--header "Authorization: Bearer <token>"
--header 'content-type: application/json'
--data{
         "senderDelivery":1,
         "senderCityId":3,
         "senderAddress":"Toshkent sh., Bobur ko‘chasi, 5-A",
         "senderReal":"Jurabek Turdiyev",
         "senderPhone":"+998 99 1234567",
         "weight":2,
         "packageId":4,
         "postTypeId":16,
         "postTypes":[
              {
                  "name": "Kitob",
                  "code": "ZFD21AD",
                  "count": 1
              },
              {
                  "name": "Daftar",
                  "code": "AV2321",
                  "count": 2
              }
         ],
         "receiverDelivery":1,
         "receiver":"Odil Ahkmedov",
         "receiverCityId":3,
         "receiverAddress":"Gozovo qish. 41 uy",
         "clientId":abc123mn12,
         "volume":0,
         "takePhoto":1,
         "piece":1,
         "senderDate":"2018-02-06",
         "receiverDate":"2018-02-07",
         "receiverPhone":"+998 99 1234567",
         "receiverPhone1":null,
        }  

SUCCESS

{
    "orderId": 229234,
    "customer": {
        "id": 79,
        "name": "ООО JOHD "
    },
    "status": {
        "id": 1,
        "info": "Mijozda"
    },
    "senderRegion": {
        "id": 2,
        "name": "Andijon viloyati"
    },
    "senderCity": {
        "id": 3,
        "name": "Asaka tumani",
        "regionId": 2
    },
    "senderBranch": {
        "id": 93,
        "name": "ASAKA BTS"
        "regionId": 2
    },
    "senderDelivery": 1,
    "senderAddress": "Toshkent sh., Bobur ko‘chasi, 7-A",
    "senderReal": "Jurabek Turdiyev",
    "senderPhone": "+998 99 1234567",
    "receiver": "Odil Ahkmedov",
    "receiverRegion": {
        "id": 2,
        "name": "Andijon viloyati"
    },
    "receiverCity": {
        "id": 3,
        "name": "Asaka tumani"
    },
    "receiverBranch": {
        "id": 93,
        "name": "ASAKA BTS"
        "regionId": 2
    },
    "receiverDelivery": 1,
    "receiverAddress": "Gozovo qish. 41 uy",
    "receiverPhone": "+998 99 1234568",
    "receiverPhone1": null,
    "package": {
        "id": 8,
        "name": "BTS PAKETLAR"
    },
    "postType": {
        "id": 4,
        "name": "HUJJATLAR"
    },
    "cost": "12000.00",
    "weight": "2.000",
    "piece": 1,
    "clientId": abc123mn12,
    "volume": 0,
    "takePhoto": 0,
    "senderSign": null,
    "receiverSign": null,
    "senderDate": "2018-02-06",
    "receiverDate": "2018-02-07",
    "barcode": "60000006106"
    "labelEncode": "<encoded_file>"
}

Failure Validation error

{
"errors": {
    "senderPhone": [
        "«Telefon» ni to'ldirishingiz kerak."
    ],
    "weight": [
        "«Kg» to'ldirilishi kerak."
    ]
}
}

HTTP Request

POST /order/add

Query Parameters

Parameter Type Description
senderCityId* integer Yuboruvchining shahri. Shaharlar ro'yxati
senderAddress* string Yuboruvchining manzili
senderDelivery integer 1-Kurerga qo'ng'iroq qiling, 0-BTS ofisiga olib ketish.
senderReal* string Yuboruvchining to'liq ismi
senderPhone* string Yuboruvchining telefon raqami
weight* double Jo'natma og'irligi
packageId* integer Qadoqlash turi. Qadoqlash turlari
postTypeId* integer Yuborish turi Yuborish turlari
receiver* string Qabul qiluvchining to'liq ismi
receiverAddress* string Qabul qiluvchining manzili
receiverDelivery integer 1-Agar kurer yetkazib bersa, 0-qabul qiluvchi BTSni ofisdan olsa.
receiverCityId* integer Qabul qiluvchining shahri. Shaharlar ro'yxati
receiver_branch_id integer receiverDelivery = 0 yuborilsa receiver_branch_id qiymatiga "receiverCityId" da mavjud bolgan ofis "id"si biriktiriladiСписок филиалов
clientId string Mijoz shtrix kodi
volume number Hajm (hajm = uzunlik * balandlik * kenglik) yuborish
takePhoto integer 1 - oluvchining fotosurati kerak, 0 - shart emas. standart 0. Qabul qilingan qiymatlar
is_test integer 1 - sinov uchun, 0 - kerak emas. standart 0. Qabul qilingan qiymatlar
senderSign string Yuboruvchining imzosi
receiverSign string qabul qiluvchining imzosi
piece integer joʻnatma soni, standart 1
senderDate date Taqdim etilgan sana, boshlang'ich buyurtma sanasi
receiverDate date Qabul qilingan sana, standart buyurtma sanasi
receiverPhone* string Qabul qiluvchining telefon raqami
receiverPhone1 string Qabul qiluvchining qo'shimcha telefon raqami
bringBackMoney integer 1 - tovar uchun pul qaytarilishi kerak, 0 - etkazib berishda naqd pul yo'q.
back_money integer siz bringBackMoney 1 ga teng bo'lganda miqdorni ko'rsatishingiz kerak.
bringBackWaybill integer 1-Qaytish hujjati kerak
additionalInfo string Sharhlar (Hujjatning bir nusxasi qaytariladi)
labelEncode string Shtrix-kod (fayl)

Buyurtma ma'lumotlari

Http request

GET /order/detail&id=<orderId>

Parameter Type Description
orderId integer Buyurtma raqami
curl
--request GET \
--url "http://api.bts.uz:8080/index.php?r=v1/order/detail&id=<orderId>" \
--header "Authorization: Bearer <token>"

JSON формат:

{
    "orderId": "<orderId>",
    "customer": {
        "id": 79,
        "name": "ООО JOHD "
    },
    "status": {
        "id": 1,
        "info": "Mijozda"
    },
    "senderRegion": {
        "id": 2,
        "name": "Andijon viloyati"
    },
    "senderCity": {
        "id": 3,
        "name": "Asaka tumani",
        "regionId": 2
    },
    "senderBranch": {
        "id": 93,
        "name": "ASAKA BTS"
        "regionId": 2
    },
    "senderDelivery": 1,
    "senderAddress": "г.Ташкент,ул.Бабаева,7-А",
    "senderPhone": "+998 99 1234567",
    "receiver": "Odil Ahkmedov",
    "receiverRegion": {
        "id": 2,
        "name": "Andijon viloyati"
    },
    "receiverCity": {
        "id": 3,
        "name": "Асака туман"
    },
    "receiverBranch": {
        "id": 93,
        "name": "ASAKA BTS"
        "regionId": 2
    },
    "receiverDelivery": 1,
    "receiverAddress":"Gozovo qish. 41 uy",
    "receiverPhone": "+998 99 1234568",
    "receiverPhone1": null,
    "package": {
        "id": 8,
        "name": "BTS PAKETLAR"
    },
    "postType": {
        "id": 4,
        "name": "HUJJATLAR"
    },
    "cost": "12000.00",
    "weight": "2.000",
    "piece": 1,
    "volume": "0",
    "urgent": 0,
    "takePhoto": 0,
    "senderSign": null,
    "receiverSign": null,
    "senderDate": "2018-02-06",
    "receiverDate": "2018-02-07",
    "barcode": "60000006106"
    "labelEncode": "<encoded_file>"

    
}

Buyurtmani o'chirish

Http request

GET /order/cancel&id=<orderId>

Parameter Type Description
orderId integer Buyurtma raqami
curl
--request GET \
--url "http://api.bts.uz:8080/index.php?r=v1/order/cancel&id=<orderId>" \
--header "Authorization: Bearer <token>"

JSON формат:

{
    "orderId": "229234",
    "status": {
        "id": 0,
        "name": "Bekor qilingan buyurtma"
    },
}

Buyurtma kalkulyator

Buyurtma narxi.

Http Request

POST /order/calculate

curl
--request POST \
--url "http://api.bts.uz:8080/index.php?r=v1/order/calculate" \
--header "Authorization: Bearer <token>"\
--data
{
    "senderCityId": 3,
    "receiverCityId": 3,
    "weight": 1,
    "volume": null,
    "senderDate": "2018-02-06",
    "senderDelivery": 1,
    "receiverDelivery": 1
}

SUCCESS

{
    "summaryPrice": 10000,
    "requestData": {
        "weight": 1,
        "volume": null,
        "senderCityId": 3,
        "receiverCityId": 3,
        "senderDate": "2018-02-06",
        "senderDelivery": 1,
        "receiverDelivery": 1
    }
}

FAILURE

{
    "errors": {
        "senderCityId": [
            "«Yuborish shahri» ni to'ldirishingiz kerak."
        ]
    }
}
Parameter Type Description
senderCityId* integer Yuboruvchining shahri. Shaharlar ro'yxati
weight* double Jo'natma og'irligi
receiverCityId* integer Qabul qiluvchining shahri. Shaharlar ro'yxati
volume number Hajm (hajm = uzunlik * balandlik * kenglik) yuborish
senderDate date Taqdim etilgan sana, boshlang'ich buyurtma sanasi
senderDelivery integer 2-Kuryer chaqirish (uzoq qishloqdan), 1-kurer chaqarish (shahar markazidan), 0-BTS ofisiga olib ketish.
receiverDelivery integer 2-Agar kurer yetkazib bersa (uzoq qishloqga), 1-agar kurer yetkazib bersa (shahar markaziga), 0-agar qabul qiluvchi BTSni ofisdan olsa.

Hozirgi holat

Http request

GET /order/track&id=<orderId>

curl
--request GET \
--url "http://api.bts.uz:8080/index.php?r=v1/order/track&id=<orderId>" \
--header "Authorization: Bearer <token>"
Parameter Type Description
orderId integer Buyurtma ID si

SUCCESS

{
    "orderId": 229234,
    "status": {
        "id": 1,
        "name": "new"
    }
}

Kuzatuv

Http request

GET /order/history&id=<orderId>

Parameter Type Description
orderId integer Buyurtma ID si
curl
--request GET \
--url "http://api.bts.uz:8080/index.php?r=v1/order/history&id=<orderId>" \
--header "Authorization: Bearer <token>"

SUCCESS:

{
   {
    "message": "message1",
    "timestamp": 1720690236,
    "status_id": 4,
    "location": "QUSHBEGI BTS (PVZ)"
   },
   {
    "message": "message2",
    "timestamp": 1720690321,
    "status_id": 5,
    "location": "JARQO'RG'ON BTS"
   },
}

Bekor qilish sabablari

Http request

GET v1/order/cancellation&id=<orderId>

Parameter Type Description
orderId integer Buyurtma ID si
curl
--request GET \
--url "http://api.bts.uz:8080/index.php?r=v1/order/cancellation&id=<orderId>" \
--header "Authorization: Bearer <token>"

SUCCESS:

[
   {
    "employee": "Jon Done",
    "description": "Saqlash muddati tugagan",
    "date": 2024-08-20 14:29:06
   },
   {
    "employee": "Jon Done",
    "description": "Noto`g`ri manzil",
    "date": 2024-08-23 14:29:06
   }
]

Statuslar ro'yxati

id info
0 Rad etilgan
1 Yuboruvchida
2 Kuryer buyurtmani qabul qildi
3 Jo'natuvchining ofisida
4 Yetkazish ofisida
5 Kuryer yetkazmoqda
6 Yetkazib berilgan
7 Qaytarish
8 Tranzit ofisda
10 В сортировочном центре (РЦ)
31 Omborda
32 Qopda
33 Transportda
34 RC kuryerka

Заявки Международный

Buyurtma yaratish

curl
--request POST \
--url "http://api.bts.uz:8080/index.php?r=v1/international/add" \
--header "Authorization: Bearer <token>"
--header 'content-type: application/json'
--data{
         "ParcelNumber":"366489851",
         "ReceiverPhone":"+998 99 1234567",
         "ReceiverPhone1":"+998 88 1234567",
         "ReceiverPatronymic":"Johnson",
         "ReceiverSurname":"Elizabeth"
         "ReceiverFirstName":"Emily",
         "ReceiverPassposrtSerial":"AC",
         "ReceiverPassposrtNumber":"0579415",
         "ReceiverPinfl":"12345678912345",
         "ReceiverAddress":"Toshkent sh., Bobur ko‘chasi, 5-A",
         "ReceiverCustomsAgree":"1",
         "ParcelWeight":"13",
         "ParcelValue":"3",
         "ParcelDeclareCurrency":"RUB",
         "ReceiverCityId":"3",
         "ReceiverBranchId":62,
         "ReceiverDelivery":0,
         "products":{
            {
                "ProductDescription":"Футболка1",
                "ProductDescriptionRu":"ФутболкаRu1",
                "ProductQuantity":"2",
                "ProductWeight":"4",
                "ProductDeclareValue":"1",
                "ProductUrl":"url1",
                "ProductUnit":"kg",
                "HsCodeIs":"6211390000",
                "ProductModel":"2324345",
                "ProductImei":"2342342341245",
            },
            {
                "ProductDescription":"Футболка2",
                "ProductDescriptionRu":"ФутболкаRu2",
                "ProductQuantity":"1",
                "ProductWeight":"5",
                "ProductDeclareValue":"1",
                "ProductUrl":"url2",
                "ProductUnit":"kg",
                "HsCodeIs":"546567565",
                "ProductModel":"6523434",
                "ProductImei":"324234523412",
            },
            {
                ....
            }
         }
        }  

SUCCESS

{
    "ParcelNumber": "366489851"
    "ReceiverPhone": "+998 99 1234567",
    "ReceiverPhone1": "+998 88 1234567",
    "ReceiverPatronymic": 2,
    "ReceiverSurname": Elizabeth,
    "ReceiverFirstName": Emily,
    "ReceiverPassposrtSerial": AC,
    "ReceiverPassposrtNumber": 0579415,
    "ReceiverPinfl": 12345678912345,
    "ReceiverAddress":"Toshkent sh., Bobur ko‘chasi, 5-A",
    "ReceiverCustomsAgree": 1,
    "ParcelWeight": "4"
    "ParcelValue": "312412 "
    "ParcelDeclareCurrency": "RUB"
    "ReceiverDelivery": 0,
    "branch": {
        "ReceiverBranchId": 62,
        "name": "ASAKA BTS"
    },
    "city": {
        "ReceiverCityId": 3,
        "name": "Asaka tumani"
    },
    "products": {
        {
            "ProductDescription": "Футболка1",
            "ProductDescriptionRu": "ФутболкаRu1",
            "ProductQuantity": "2",
            "ProductWeight": "4",
            "ProductDeclareValue": "1",
            "ProductUrl": "url1",
            "ProductUnit": "kg",
            "HsCodeIs": "6211390000",
            "ProductModel": "2324345",
            "ProductImei": "2342342341245"
        },
        {
            "ProductDescription": "Футболка2",
            "ProductDescriptionRu": "ФутболкаRu2",
            "ProductQuantity": "1",
            "ProductWeight": "5",
            "ProductDeclareValue": "1",
            "ProductUrl": "url2",
            "ProductUnit": "kg",
            "HsCodeIs": "546567565",
            "ProductModel": "6523434",
            "ProductImei": "324234523412"
        },
        {
            ....
        }
    },
}

Failure Validation error

{
"errors": {
    "ReceiverPhone": [
        "«Telefon» ni to'ldirishingiz kerak."
    ],
    "ParcelWeight": [
        "«Kg» to'ldirilishi kerak."
    ]
}
}

HTTP Request

POST /international/add

Query Parameters

Parameter Type Description
ParcelNumber* string _ParcelNumber
ReceiverPhone* string _ReceiverPhone
ReceiverPhone1 string _ReceiverPhone1
ReceiverPatronymic string _ReceiverPatronymic
ReceiverSurname* string _ReceiverSurname
ReceiverFirstName* string _ReceiverFirstName
ReceiverPassposrtSerial* string _ReceiverPassposrtSerial
ReceiverPassposrtNumber* string _ReceiverPassposrtNumber
ReceiverPinfl* string _ReceiverPinfl
ReceiverAddress string _ReceiverAddress
ReceiverCustomsAgree string _ReceiverCustomsAgree
ParcelWeight* string _ParcelWeight
ParcelValue string _ParcelValue
ParcelDeclareCurrency* string _ParcelDeclareCurrency
ReceiverCityId integer Qabul qiluvchining shahri. Shaharlar ro'yxati
ReceiverBranchId integer receiverDelivery = 0 yuborilsa receiver_branch_id qiymatiga "receiverCityId" da mavjud bolgan ofis "id"si biriktiriladiСписок филиалов
ReceiverDelivery* string 1-Kurerga qo'ng'iroq qiling, 0-BTS ofisiga olib ketish.
products array Product_array
ProductDescription* text _ProductDescription
ProductDescriptionRu* text _ProductDescriptionRu
ProductQuantity* string _ProductQuantity
ProductWeight* string _ProductWeight
ProductDeclareValue* string _ProductDeclareValue
ProductUrl* string _ProductUrl
ProductUnit* string Weight:Kilogram (kg),Gram (g),Tonne (t). Quantity: Piece (pcs). Volume: Litre (L), Millilitre (mL), Cubic meter (m³)
HsCodeIs* string _HsCodeIs
ProductModel string _ProductModel
ProductImei string _ProductImei

Hozirgi holat

Http request

GET /international/track-by-barcode&barcode=<barcode>

curl
--request GET \
--url "http://api.bts.uz:8080/index.php?r=v1/international/track-by-barcode&barcode=<barcode>" \
--header "Authorization: Bearer <token>"
Parameter Type Description
barcode string Штрих-код заявки

SUCCESS

{
    "barcode": 01000865704,
    "status": {
        "code": 200,
        "message": "In the sorting center"
    }
}

Манифест

curl
--request POST \
--url "http://api.bts.uz:8080/index.php?r=v1/international/manifest" \
--header "Authorization: Bearer <token>"
--header 'content-type: application/json'
--data{
         "ManifestNumber":"12345672121",
         "Parcels"{
            {
                "ParcelNumber":"867465466877546"
            },
            {
                "ParcelNumber":"543655876765767"
            }
         },
         "ManifestDetails"{
                "ParcelsCount":"2",
                "Date":"2024-10-10"
         },
        }  

SUCCESS

{
    "success": true,
    "message": "Manifest processed successfully.."
}

Failure Validation error

{
"errors": {
    "ManifestNumber": [
        "ManifestNumber cannot be blank.."
    ],
    "ParcelsCount": [
        "ParcelsCount cannot be blank.."
    ]
}
}

HTTP Request

POST /international/manifest

Query Parameters

Parameter Type Description
ManifestNumber* string _ManifestNumber
Date* string Date
ParcelNumber* string ParcelNumber
ParcelsCount* string ParcelsCount

Statuslar ro'yxati

code info
100 Yuboruvchida
110 Bojxonaga kirdi
120 Bojxonadan chiqdi
130 Bojxona tomonidan bekor qilindi
200 Saralash markazida
300 Qabul qiluvchi ofisida
400 Kuryer yetkazmoqda
500 Yetkazib berildi

Katalog

Shaharlar ro'yxati

id regionId Mahsulot nomi tuldirish shart
1 14 Shahrisabz shahar
2 3 Pop tumani
3 2 Asaka tumani
4 5 Toshkent tumani
5 5 Yangiyo'l shahar
6 5 Ohangaron shahar
7 5 Nurafshon shahar
8 11 Nukus shahar
9 11 Taxiatosh tumani
10 4 Xiva shahar
11 11 Amudaryo tumani
12 11 Beruniy tumani
13 11 Qonliko'l tumani
14 11 Qorauzak tumani
15 11 Kegeyli tumani
16 11 Qo'ng'irot tumani
17 11 Mo'ynaq tumani
18 11 Nukus tumani
19 11 Taxtako'prik tumani
20 11 To'rtko'l tumani
21 11 Xo‘jayli tumani
22 11 Chimboy tumani
23 11 Shumanay tumani
24 11 Ellikqala tumani
25 2 Andijon shahar
26 2 Xonobod shahar
27 2 Andijon tumani
28 2 Baliqchi tumani
29 2 Buloqboshi tumani
30 2 Bo'z tumani
31 2 Jalaquduq tumani
32 2 Izboskan tumani
33 2 Ulug'nor tumani
34 2 Marhamat tumani
35 2 Paxtaobod tumani
36 2 Xo'jaobod tumani
37 2 Oltinko'l tumani
38 2 Qo'rg'ontepa tumani
39 2 Shahrixon tumani
40 7 Buxoro shaxri
41 7 Kogon shaxri
42 7 Buxoro tumani
43 7 Vobkent tumani
44 7 Jondor tumani
45 7 Kogon tumani
46 7 Olot tumani
47 7 Peshku tumani
48 7 Romitan tumani
49 7 Shofirkon tumani
50 7 Qorako'l tumani
51 7 Qorovulbozor tumani
52 7 G'ijduvon tumani
53 9 Arnasoy tumani
54 9 Baxmal tumani
55 9 G'allaorol tumani
56 9 Do'stlik tumani
57 9 Jizzax shahri
58 9 Jizzax
59 9 Zarbdor tumani
60 9 Zafarobod tumani
61 9 Zomin tumani
62 9 Mirzacho'l tumani
63 9 Paxtakor tumani
64 9 Forish tumani
65 9 Yangiobod tumani
66 14 Qarshi shahri
67 14 Qarshi tumani
68 14 Muborak tumani
69 14 G'uzor tumani
70 14 Qamashi tumani
71 14 Chiroqchi tumani
72 14 Shahrisabz tumani
73 14 Qasbi tumani
74 14 Kasan tumani
75 14 Kitob tumani
76 14 Nishon tumani
77 14 Mirishkor tumani
78 14 Dehqonobod tumani
79 14 Yakkabog' tumani
80 10 Navoiy shahri
81 10 Zarafshon shahri
82 10 Karmana tumani
83 10 Tomdi tumani
84 10 Navbahor tumani
85 10 Nurota tumani
86 10 Xatirchi tumani
87 10 Qiziltepa tumani
88 10 Konimex tumani
89 10 Uchquduq shahri
90 3 Namangan shahri
91 3 Mingbuloq tumani
92 3 Kosonsoy tumani
93 3 Namangan tumani
94 3 Narin tumani
95 3 To'raqo'rg'on tumani
96 3 Uychi tumani
97 3 Uchqo'rg'on tumani
98 3 Chortoq tumani
99 3 Chust tumani
100 3 Yangiqo'rg'on tumani
101 8 Samarqand shahri
102 8 Urgut tumani
103 8 Paxtachi tumani
104 8 Kattako'rg'on tumani
105 8 Samarqand tumani
106 8 Bulung'ur tumani
107 8 Jomboy tumani
108 8 Qo'shrabot tumani
109 8 Narpay tumani
110 8 Toyloq tumani
111 8 Pastdarg'om tumani
112 8 Nurobod tumani
113 8 Kattako'rg'on shahri
114 8 Payariq tumani
115 8 Oqdaryo tumani
116 8 Ishtixon tumani
117 13 Termiz shahri
118 13 Termiz tumani
119 13 Muzrabot tumani
120 13 Oltinsoy tumani
121 13 Denov tumani
122 13 Sariosiyo tumani
123 13 Qiziriq tumani
124 13 Jarqo'rg'on tumani
125 13 Angor tumani
126 13 Qumqo'rg'on tumani
127 13 Boysut tumani
128 13 Sho'rchi tumani
129 13 Sherobod tumani
130 13 Uzun tumani
131 12 Guliston shahri
132 12 Yangiyer shahri
133 12 Shirin shahri
134 12 Oqoltin tumani
136 12 Guliston tumani
137 12 Mirzaobod tumani
138 12 Sayxunobod tumani
139 12 Sardoba tumani
140 12 Sirdaryo tumani
141 12 Xovos tumani
142 5 Angren shahri
143 5 Bekobod shahri
144 5 Olmaliq shahri
145 5 Chirchiq shahri
146 5 Bekobod tumani
147 5 Bo'stonliq tumani
148 5 Qibray tumani
149 5 Zangiota tumani
150 5 Quyi Chirchiq tumani
151 5 Oqqo'rg'on tumani
152 5 Parkent tumani
154 5 O'rta Chirchiq tumani
155 5 Chinoz tumani
156 5 Yuqori Chirchiq tumani
157 5 Bo'ka tumani
158 5 Yangiyo'l tumani
159 5 Ohangaron tumani
160 15 Farg'ona shahri
161 15 Marg'ilon shahri
162 15 Quvasoy shahri
163 15 Qo'qon shahri
164 15 Bag'dod tumani
165 15 Buvayda tumani
166 15 Dang'ara tumani
167 15 Yaypan tumani
168 15 Oltiariq tumani
169 15 Beshariq tumani
170 15 Qo'shtepa tumani
171 15 Rishton tumani
172 15 So'x tumani
173 15 Toshloq tumani
174 15 Uchko'prik tumani
175 15 Farg'ona tumani
176 15 O'zbekiston tumani
177 15 Qo'qon tumani
178 15 Furqat tumani
179 4 Urganch shahri
180 4 Bog'ot tumani
181 4 Urganch tumani
182 4 Qo'shko'pir tumani
183 4 Xonqa tumani
184 4 Yangiariq tumani
185 4 Xiva tumani
186 4 Yangibozor tumani
187 4 Hazorasp tumani
188 4 Shovot tumani
189 4 Gurlen tumani
190 6 Bektemir tumani
191 6 Mirabad tumani
192 6 M. Ulug'bek tumani
193 6 Sergeli tumani
194 6 Almazar tumani
195 6 Uchtepa tumani
196 6 Yashnobod tumani
197 6 Chilonzor tumani
198 6 Shayxontohur tumani
199 6 Yunusobod tumani
200 6 Yakkasaroy tumani
201 5 Piskent tumani
167 15 Ёзёвон туман
58 9 Шароф Рашидов
217 11 Бўзатов тумани
14 11 Қораузак туман
219 14 Kokdala tumani
218 4 Тупроққалъа туман
135 12 Боёвут туман
220 13 Бандихон

Hududlar

id name
4 Xorazm viloyati
15 Farg'ona viloyati
5 Toshkent viloyati
6 Toshkent
12 Sirdaryo viloyati
13 Surxondaryo viloyati
8 Samarqand viloyati
3 Namangan viloyati
10 Navoiy viloyati
14 Qashqadaryo viloyati
11 Qoraqalpog'iston
9 Jizzax viloyati
7 Buxoro viloyati
2 Andijon viloyati

Filiallar

Http request

GET /directory/branches&regionId=<Id>

Parameter Type Description
regionId integer Hudud raqami (Majburiy emas)
curl
--request GET \
--url "http://api.bts.uz:8080/index.php?r=directory/branches&regionId=<Id>" \
--header "Authorization: Bearer <token>"

JSON формат:

{
  {
    "id": 10,
    "name": "KARSHI BTS",
    "regionId": 14,
    "cityId": 66,
    "address": "KARSHI 5-Mikro rayon ul. Nasaf. or: Nikoh uyi orqa tomoni ",
    "lat_long": "38.837395,65.783467",
    "phone": "1230",
    "video_link": "https://youtu.be/g6TsS5PLTF0",
    "working_hours": {
        "1": "08:00-20:00",
        "2": "08:00-20:00",
        "3": "08:00-20:00",
        "4": "08:00-20:00",
        "5": "08:00-20:00",
        "6": "08:00-16:00",
        "7": "08:00-16:00"
    }
  },
}

Filiallar (cityId)

Http request

GET /directory/branches-with-city&cityId=<Id>

Parameter Type Description
cityId integer Номер города (Не обязательно)
curl
--request GET \
--url "http://api.bts.uz:8080/index.php?r=directory/branches-with-city&cityId=<Id>" \
--header "Authorization: Bearer <token>"

JSON формат:

{
  {
    "id": 79,
    "name": "MALIKA BOZOR BTS",
    "regionId": 6,
    "cityId": 198,
    "address": "Toshkent, Labzak ko'ch 2/122. Mag 118 or: Tramvay aylanasi",
    "lat_long": "41.338727,69.269875",
    "phone": "1230",
    "video_link": "",
    "working_hours": {
        "1": "09:00-18:00",
        "2": "09:00-18:00",
        "3": "09:00-18:00",
        "4": "09:00-18:00",
        "5": "09:00-18:00",
        "6": "09:00-18:00",
        "7": "09:00-18:00"
    }
  },
  {
    "id": 24,
    "name": "SHAYXONTOHUR BTS",
    "regionId": 6,
    "cityId": 198,
    "address": "TASHKENT, ul. Furkat 6. Mo'ljal: Xadra,Asaka Bankni orqasi",
    "lat_long": "41.319124,69.240262",
    "phone": "1230",
    "video_link": "https://youtu.be/g6TsS5PLTF0",
    "working_hours": {
        "1": "27/7",
        "2": "27/7",
        "3": "27/7",
        "4": "27/7",
        "5": "27/7",
        "6": "27/7",
        "7": "27/7"
    }
  }
}

Yuborish turlari

id name
4 HUJJATLAR
5 ZAPCHASTLAR
6 DORI-DARMONLAR
7 ORGTEXNIKA
8 KITOBLAR
9 SHISHA BUYUMLARI
10 REKLAMA MAHSULOTLARI
11 KIYIM-POYABZALLAR
12 UYALI TELEFON
13 PASSPORT
14 PARFUMERIYA
15 MAHSULOTLAR
16 KIMYOVIY MODDALAR
17 PROTEZLAR (TISH)
18 URUG'LAR
19 PLASTIK KARTA
20 MUHR
21 SANTEXNIKA
22 MEBEL
23 TIBBIY ASBOBLAR
24 MATOLAR
25 USKUNALAR
26 KANSTOVARLAR
27 XO'JALIK MAHSULOTLARI
28 O'YINCHOQLAR
29 BIJUTERIYA
30 KOSMETIKA
31 MAISHIY TEXNIKA
32 QURITILGAN MEVALAR
33 QURILISH MATERIALLARI

Qadoqlash turlari

id name
4 SUMKA
5 KONTEYNER
6 KONVERT
7 QUTI
8 BTS PAKETLAR
9 QADOQSIZ
10 ZAVOD QADOQLASHI

Ha yoki Yo'q

Qiymatlar Tavsiflar
1 Yoqilgan
0 O'chirilgan

Statuslar ro'yxati

id info
0 Rad etilgan
1 Yuboruvchida
2 Kuryer buyurtmani qabul qildi
3 Jo'natuvchining ofisida
4 Yetkazish ofisida
5 Kuryer yetkazmoqda
6 Yetkazib berilgan
7 Qaytarish
8 Tranzit ofisda
10 В сортировочном центре (РЦ)
31 Omborda
32 Qopda
33 Transportda
34 RC kuryerka

Fulfillment WMS

Http request

POST /auth

curl \
--request POST \
--url "http://wms.bts:8040/v1/auth/login" \
--header  "accept: "application/json"
--header  "Content-Type: "application/json"
--data '{
    "login": "login",
    "password": "password"
}'

SUCCESS:


  {
    "access_token": "string",
    "refresh_token": "string"
  }
Parameter Type Description
login string foydalanuvchi inn yoki tel raqam, tuldrish shart
password string parolni tuldirish shart

Yetkazib beruvchi yaratish

Http request

POST v1/purveyor/create

curl \
--request POST \
--url "http://wms.bts.uz:8040/v1/purveyor/create" \
--header  "Authorization: "Bearer token"
--header  "accept: "application/json"
--header  "Content-Type: "application/json"
--data '{
    "group": "group",
    "code": "code",
    "name": "name",
    "full_name": "full_name",
    "name_eng": "name_eng",
    "stock_percentage": "stock_percentage",
    "stock_expiry": "stock_expiry",
    "legal_entity": "legal_entity",
    "inn": "inn",
    "kpp": "kpp",
    "okpp": "okpp",
    "is_buyer": "is_buyer",
    "main_delivery_address": "main_delivery_address",
    "depositor": "depositor",
    "contract_number": "contract_number",
    "contract_date": "contract_date",
    "bank_details": "bank_details",
    "contact_info": "contact_info",
    "additional_details": "additional_details",
    "is_supplier": "is_supplier"
}'

SUCCESS:


  {
    "message": "Record successfully created.",
    "data": {
        "id": 14,
        "group": "string",
        "code": "string",
        "name": "string",
        "full_name": "string",
        "name_eng": "string",
        "contractBankDetail": {
            "id": 11,
            "supplier_buyer_id": 14,
            "contract_number": "string",
            "contract_date": "2024-11-11",
            "bank_details": "string",
            "contact_info": "string",
            "additional_details": "string",
            "main_delivery_address": "string"
        },
        "entityType": {
            "id": 11,
            "stock_percentage": "0.00",
            "stock_expiry": 0,
            "supplier_buyer_id": 14,
            "legal_entity": true
        },
        "supplierBuyerStatus": {
            "id": 11,
            "supplier_buyer_id": 14,
            "is_supplier": true,
            "is_buyer": true,
            "depositor": true
        },
        "taxInfo": {
            "id": 11,
            "supplier_buyer_id": 14,
            "inn": "string",
            "kpp": "string",
            "okpo": "string"
        },
        "_links": {
            "self": {
                "href": "http:/wms.bts.uz:8040/v1/purveyor/view?id=14"
            }
        }
    }
}
Parameter Type Description
group string Mahsulot guruhi tuldirish shart
code string Mahsulot kodi tuldirish shart
name string Mahsulot nomi tuldirish shart
full_name string Mahsulotning to'liq nomi tuldirish shart
name_eng string Inglizcha nom (mahsulotning ingliz tilidagi nomi)
stock_percentage string Yaroqlilik zaxirasi foizi
stock_expiry string Yaroqlilik muddati
legal_entity boolean Yuridik/jismoniy shaxs (Да/Нет)
inn integer Soliq to'lovchining identifikatsiya raqami
kpp integer Kompaniya ro'yxatidan o'tgan kod
okpp integer Yetkazib beruvchi
is_buyer boolean Xaridor (Да/Нет)
main_delivery_address string Asosiy yetkazib berish manzili
depositor boolean Omborchi (mahsulot uchun javobgar omborchi)
contract_number integer Shartnoma raqami
contract_date string Shartnoma sanasi
bank_details string Bank rekvizitlari
contact_info string Aloqa ma'lumotlari
additional_details string Qo'shimcha rekvizitlar
is_supplier boolean Yetkazib beruvchi (Да/Нет)

Yetkazib beruvchi ro'yxat

Http request

GET v1/purveyor/clients

curl \
--request GET \
--url "http://wms.bts.uz:8040/v1/purveyor/clients" \
--header  "Authorization: "Bearer token"
--header  "accept: "application/json"
--header  "Content-Type: "application/json"

SUCCESS:


  {
    "message": "Data successfully retrieved.",
    "data": {
        "items": [
            {
                "id": 12,
                "group": "string",
                "code": "string",
                "name": "string",
                "full_name": "string",
                "name_eng": "string",
                "contractBankDetail": {
                    "id": 9,
                    "supplier_buyer_id": 12,
                    "contract_number": "string",
                    "contract_date": "2024-10-10",
                    "bank_details": "string",
                    "contact_info": "string",
                    "additional_details": "string",
                    "main_delivery_address": "string"
                },
                "entityType": {
                    "id": 9,
                    "stock_percentage": "20.00",
                    "stock_expiry": 0,
                    "supplier_buyer_id": 12,
                    "legal_entity": true
                },
                "supplierBuyerStatus": {
                    "id": 9,
                    "supplier_buyer_id": 12,
                    "is_supplier": true,
                    "is_buyer": true,
                    "depositor": true
                },
                "taxInfo": {
                    "id": 9,
                    "supplier_buyer_id": 12,
                    "inn": "string",
                    "kpp": "string",
                    "okpo": "string"
                },
                "_links": {
                    "self": {
                        "href": "http://wms.bts.uz:8040/v1/purveyor/view?id=12"
                    }
                }
            }
        ],
        "_links": {
            "self": "/v1/purveyor/clients?page=1",
            "first": "/v1/purveyor/clients?page=1",
            "last": "/v1/purveyor/clients?page=1"
        },
        "_meta": {
            "totalCount": 11,
            "pageCount": 1,
            "currentPage": 1,
            "perPage": 20
        }
    }
}
Parameter Type Description
group string Mahsulot guruhi
code string Mahsulot kodi
name string Mahsulot nomi
full_name string Mahsulotning to'liq nomi
name_eng string Inglizcha nom (mahsulotning ingliz tilidagi nomi)
stock_percentage string Yaroqlilik zaxirasi foizi
stock_expiry string Yaroqlilik muddati
legal_entity boolean Yuridik/jismoniy shaxs (Да/Нет)
inn integer Soliq to'lovchining identifikatsiya raqami
kpp integer Kompaniya ro'yxatidan o'tgan kod
okpp integer Yetkazib beruvchi
is_buyer boolean Xaridor (Да/Нет)
main_delivery_address string Asosiy yetkazib berish manzili
depositor boolean Omborchi (mahsulot uchun javobgar omborchi)
contract_number integer Shartnoma raqami
contract_date string Shartnoma sanasi
bank_details string Bank rekvizitlari
contact_info string Aloqa ma'lumotlari
additional_details string Qo'shimcha rekvizitlar
is_supplier boolean Yetkazib beruvchi (Да/Нет)

Yetkazib beruvchi statusini yangilash

Http request

POST v1/purveyor/client-status

curl \
--request POST \
--url "http://wms.bts.uz:8040/v1/purveyor/client-status" \
--header  "Authorization\: "Bearer token"
--header  "accept\: "application/json"
--header  "Content-Type\: "application/json"
--data '{
    "status" => [
                  {"id": 1,"status": "ok"},
                  {"id": 2,"status": "ok"}
       ]
}'

SUCCESS:


{
  "message": "supplier-buyers successfully updated to delivered status"
}
  
Parameter Type Description
status array Bazangizga muvaffaqiyatli saqlangan purveyor IDlarini OK statusi bilan yuborishingiz kerak bo'ladi.

Mahsulot yaratish

Http request

POST v1/product/create

curl \
--request POST \
--url "http://wms.bts.uz:8040/v1/product/create" \
--header  "Authorization: "Bearer token"
--header  "accept: "application/json"
--header  "Content-Type: "application/json"
--data '{
    "group": "group",
    "code": "code",
    "name": "name",
    "full_name": "full_name",
    "gtin": "gtin",
    "article": "article",
    "nomenclature_type": "nomenclature_type",
    "shelf_life_stock": "shelf_life_stock",
    "abc_class": "abc_class",
    "kis_code": "kis_code",
    "comment": "comment",
    "is_set": "is_set",
    "weight": "weight",
    "net_weight": "net_weight",
    "min_shelf_life_stock": "min_shelf_life_stock",
    "name_eng": "name_eng",
    "tsd_name": "tsd_name",
    "volume": "volume",
    "net_volume": "net_volume",
    "shelf_life_deviation_days": "shelf_life_deviation_days",
    "min_shelf_life_period": "min_shelf_life_period",
    "shelf_life_deviation_period": "shelf_life_deviation_period",
    "depositor": "depositor",
    "seasonal_abc_coefficient": "seasonal_abc_coefficient",
    "specification": "specification",
    "storage_period_days": "storage_period_days",
    "default_status": "default_status",
    "temperature_mode": "temperature_mode",
    "base_packaging": "base_packaging",
    "billing_packaging": "billing_packaging",
    "report_packaging": "report_packaging",
    "unit": "unit"
}'

SUCCESS:


  {
    "message": "Record successfully created.",
    "data": {
        "id": 34,
        "supplier_buyer_id": 5,
        "group": "string",
        "code": "12345",
        "name": "string",
        "full_name": "string",
        "gtin": "1234",
        "article": "string",
        "nomenclature_type": "string",
        "unit": "string",
        "comment": "string",
        "productPackagin": {
            "id": 5,
            "product_id": 34,
            "base_packaging": "string",
            "billing_packaging": "string",
            "report_packaging": "string"
        },
        "productShelfLive": {
            "id": 8,
            "product_id": 34,
            "shelf_life_stock": "40.00",
            "min_shelf_life_stock": "33.00",
            "shelf_life_deviation_days": 0,
            "shelf_life_period": 0,
            "min_shelf_life_period": 0,
            "shelf_life_deviation_period": 0,
            "storage_period_days": 0,
            "specification": "string",
            "temperature_mode": "string"
        },
        "productTechnical": {
            "id": 15,
            "product_id": 34,
            "weight": "20.000",
            "net_weight": "50.000",
            "volume": "30.000",
            "net_volume": "60.000",
            "is_set": true,
            "kis_code": "string",
            "default_status": "string"
        },
        "_links": {
            "self": {
                "href": "http:/wms.bts.uz:8040:/v1/product/view?id=34"
            }
        }
    }
}
Parameter Type Description
group string Mahsulot guruhi tuldirish shart
code string Mahsulot kodi tuldirish shart
name string Mahsulot nomi tuldirish shart
full_name string Mahsulotning to'liq nomi tuldirish shart
gtin integer GTIN (Global Trade Item Number - xalqaro savdo birligi raqami) tuldirish shart
article string Mahsulot artikuli (artikul raqami) tuldirish shart
nomenclature_type string Nomenklatura turi (mahsulotning turi) tuldirish shart
shelf_life_stock integer Yaroqlilik zaxirasi (mahsulotning maksimal saqlash muddati) tuldirish shart
abc_class string ABC sinfi (ABC tahlili bo'yicha mahsulot klassifikatsiyasi)
kis_code string KIS kodi (Kompyuter axborot tizimi kodi) tuldirish shart
comment string Izoh (qo'shimcha izoh yoki sharh)
is_set boolean To'plam (komplektmi yoki yo'qmi) 1 yoki 0 tuldirish shart
weight integer Og'irlik (mahsulotning og'irligi) tuldirish shart
net_weight integer Netto og'irlik (qadoqdagi sof og'irlik) tuldirish shart
min_shelf_life_stock string Minimal yaroqlilik zaxirasi (qabul qilish paytidagi minimal saqlash muddati)
name_eng string Inglizcha nom (mahsulotning ingliz tilidagi nomi)
tsd_name string TSD nomi (terminal yoki skanerlarda ishlatiladigan nom)
volume integer Hajm (mahsulot hajmi) tuldirish shart
net_volume integer Netto hajm (qadoqdagi sof hajm) tuldirish shart
shelf_life_deviation_days string Yaroqlilik muddatining chetlashishi kunlarda (maximal og'ish)
min_shelf_life_period integer Minimal yaroqlilik zaxirasi muddati (qabul qilish paytidagi minimal yaroqlilik muddati)
shelf_life_deviation_period string Yaroqlilik muddatining chetlashishi davri (maksimal og'ish davri)
depositor string Omborchi (mahsulot uchun javobgar omborchi)
seasonal_abc_coefficient integer Mavsumiy ABC koeffitsienti (mavsumiy mahsulotlarning ABC tahlili bo'yicha koeffitsienti)
specification string Spetsifikatsiya (mahsulot tavsifi yoki texnik talablari) tuldirish shart
storage_period_days string Saqlash muddati kunlarda (mahsulotning maksimal saqlash muddati)
default_status string Sukut bo'yicha status (mahsulotning boshlang'ich holati)
temperature_mode string Harorat rejimi (mahsulotni saqlash harorati) tuldirish shart
base_packaging string Asosiy o'ram (mahsulotning asosiy qadoqlanishi) tuldirish shart
billing_packaging string Billing uchun o'ram (billing jarayonida foydalaniladigan o'ram)
report_packaging string Hisobot uchun o'ram (hisobotlar uchun ishlatiladigan o'ram)
unit integer O'lchov birligi (masalan, kg, dona, litr) tuldirish shart

Mahsulot ro'yxat

Http request

GET v1/product/clients

curl \
--request GET \
--url "http://wms.bts.uz:8040/v1/product/clients" \
--header  "Authorization: "Bearer token"
--header  "accept: "application/json"
--header  "Content-Type: "application/json"

SUCCESS:


  {
    "message": "Data successfully retrieved.",
    "data": {
        "items": [
            {
                "id": 39,
                "supplier_buyer_id": 5,
                "group": "stringcceee",
                "code": "stringcccee",
                "name": "stringcceee",
                "full_name": "string",
                "gtin": "112",
                "article": "string",
                "nomenclature_type": "11",
                "unit": "22",
                "comment": "string",
                "productPackagin": {
                    "id": 7,
                    "product_id": 39,
                    "base_packaging": "string",
                    "billing_packaging": "string",
                    "report_packaging": "string"
                },
                "productShelfLive": {
                    "id": 10,
                    "product_id": 39,
                    "shelf_life_stock": "22.00",
                    "min_shelf_life_stock": "0.00",
                    "shelf_life_deviation_days": 2,
                    "shelf_life_period": 2,
                    "min_shelf_life_period": 2,
                    "shelf_life_deviation_period": 2,
                    "storage_period_days": 2,
                    "specification": "string",
                    "temperature_mode": "string"
                },
                "productTechnical": {
                    "id": 18,
                    "product_id": 39,
                    "weight": "88.000",
                    "net_weight": "55.000",
                    "volume": "77.000",
                    "net_volume": "44.000",
                    "is_set": true,
                    "kis_code": "99",
                    "default_status": "string"
                },
                "_links": {
                    "self": {
                        "href": "http://wms.bts.uz:8040/v1/product/view?id=39"
                    }
                }
            }
        ],
        "_links": {
            "self": "/v1/product/clients?page=1",
            "first": "/v1/product/clients?page=1",
            "last": "/v1/product/clients?page=1"
        },
        "_meta": {
            "totalCount": 3,
            "pageCount": 1,
            "currentPage": 1,
            "perPage": 20
        }
    }
}
Parameter Type Description
group string Mahsulot guruhi
code string Mahsulot kodi
name string Mahsulot nomi
full_name string Mahsulotning to'liq nomi
gtin integer GTIN (Global Trade Item Number - xalqaro savdo birligi raqami)
article string Mahsulot artikuli (artikul raqami)
nomenclature_type string Nomenklatura turi (mahsulotning turi)
shelf_life_stock integer Yaroqlilik zaxirasi (mahsulotning maksimal saqlash muddati)
abc_class string ABC sinfi (ABC tahlili bo'yicha mahsulot klassifikatsiyasi)
kis_code string KIS kodi (Kompyuter axborot tizimi kodi)
comment string Izoh (qo'shimcha izoh yoki sharh)
is_set boolean To'plam (komplektmi yoki yo'qmi) 1 yoki 0
weight integer Og'irlik (mahsulotning og'irligi)
net_weight integer Netto og'irlik (qadoqdagi sof og'irlik)
min_shelf_life_stock string Minimal yaroqlilik zaxirasi (qabul qilish paytidagi minimal saqlash muddati)
name_eng string Inglizcha nom (mahsulotning ingliz tilidagi nomi)
tsd_name string TSD nomi (terminal yoki skanerlarda ishlatiladigan nom)
volume integer Hajm (mahsulot hajmi)
net_volume integer Netto hajm (qadoqdagi sof hajm)
shelf_life_deviation_days string Yaroqlilik muddatining chetlashishi kunlarda (maximal og'ish)
min_shelf_life_period integer Minimal yaroqlilik zaxirasi muddati (qabul qilish paytidagi minimal yaroqlilik muddati)
shelf_life_deviation_period string Yaroqlilik muddatining chetlashishi davri (maksimal og'ish davri)
depositor string Omborchi (mahsulot uchun javobgar omborchi)
seasonal_abc_coefficient integer Mavsumiy ABC koeffitsienti (mavsumiy mahsulotlarning ABC tahlili bo'yicha koeffitsienti)
specification string Spetsifikatsiya (mahsulot tavsifi yoki texnik talablari)
storage_period_days string Saqlash muddati kunlarda (mahsulotning maksimal saqlash muddati)
default_status string Sukut bo'yicha status (mahsulotning boshlang'ich holati)
temperature_mode string Harorat rejimi (mahsulotni saqlash harorati)
base_packaging string Asosiy o'ram (mahsulotning asosiy qadoqlanishi)
billing_packaging string Billing uchun o'ram (billing jarayonida foydalaniladigan o'ram)
report_packaging string Hisobot uchun o'ram (hisobotlar uchun ishlatiladigan o'ram)
unit integer O'lchov birligi (masalan, kg, dona, litr)

Qabul qilinishi kerak bo'lgan mahsulotlar statusini yangilash

Http request

POST v1/product/client-status

curl \
--request POST \
--url "http://wms.bts.uz:8040/v1/product/client-status" \
--header  "Authorization\: "Bearer token"
--header  "accept\: "application/json"
--header  "Content-Type\: "application/json"
--data '{
    "status" => [
                  {"id": 1,"status": "ok"},
                  {"id": 2,"status": "ok"}
       ]
}'

SUCCESS:


{
  "message": "products successfully updated to delivered status"
}
  
Parameter Type Description
status array Bazangizga muvaffaqiyatli saqlangan product IDlarini OK statusi bilan yuborishingiz kerak bo'ladi.

Tovarlarni qabul qilish

Http request

POST v1/receiving-goods/create

curl \
--request POST \
--url "http://wms.bts.uz:8040/v1/receiving-goods/create" \
--header  "Authorization: "Bearer token"
--header  "accept: "application/json"
--header  "Content-Type: "application/json"
--data '{
    "number": "number",
    "date": "date",
    "counterparty": "counterparty",
    "arrival_date": "arrival_date",
    "comment": "comment",
    "vehicle_model": "vehicle_model",
    "vehicle_number": "vehicle_number",
    "driver_name": "driver_name",
    "driver_document": "driver_document",
    "contract_number": "contract_number",
    "contract_date": "contract_date",
    "nomenclature": "nomenclature",
    "quantity": "quantity",
    "price": "price",
    "total_amount": "total_amount",
    "kis_number": "kis_number",
    "kis_date": "kis_date",
    "accept_by_places": "accept_by_places",
    "vehicle_type": "vehicle_type",
    "vat_rate": "vat_rate",
    "vat_amount": "vat_amount",
    "price_includes_vat": "price_includes_vat",
    "discount_amount": "discount_amount",
    "under_delivery_percent": "under_delivery_percent",
    "over_delivery_percent": "over_delivery_percent",
    "nomenclature_package": "nomenclature_package",
    "package_quantity": "package_quantity"
}'

SUCCESS:


  {
    "message": "Record successfully created.",
    "data": {
        "id": 11,
        "number": "string",
        "date": "2024-11-11",
        "counterparty": "string",
        "arrival_date": "2024-11-11",
        "comment": "string",
        "vehicle_model": "string",
        "vehicle_number": "string",
        "driver_name": "string",
        "driver_document": "string",
        "contract_number": "string",
        "contract_date": "2024-11-11",
        "acceptance_gate": null,
        "nomenclature": "string",
        "quantity": 11,
        "price": "44.00",
        "total_amount": "55.00",
        "supplierDetail": {
            "id": 8,
            "supplier_id": 11,
            "kis_number": null,
            "kis_date": "2024-11-11",
            "accept_by_places": true,
            "vehicle_type": null,
            "vat_rate": "444.00",
            "vat_amount": "66.00",
            "price_includes_vat": true,
            "discount_amount": "44.00",
            "under_delivery_percent": "20.00",
            "over_delivery_percent": "30.00"
        },
        "supplierPackage": {
            "id": 2,
            "supplier_id": 11,
            "nomenclature_package": "string",
            "package_quantity": 0
        },
        "_links": {
            "self": {
                "href": "http:/wms.bts.uz:8040/v1/receiving-goods/view?id=11"
            }
        }
    }
}
Parameter Type Description
number integer Yetkazib berish raqami tuldirish shart
date string Yetkazib berish sanasi tuldirish shart
counterparty string Kontragent (yukni yetkazib beruvchi tashkilot) tuldirish shart
arrival_date string Yuk qabul qilingan sana
comment string Izoh (qo'shimcha izoh yoki sharh)
vehicle_model string Transport vositasining modeli
vehicle_number integer Transport vositasining davlat raqami
driver_name string Haydovchining to'liq ismi
driver_document string Haydovchiga tegishli hujjat (pasport, litsenziya va h.k.)
contract_number integer Shartnoma raqami
contract_date string Shartnoma sanasi
nomenclature string Nomenklatura (yukning turi yoki mahsulotlar ro‘yxati) tuldirish shart
quantity integer Mahsulot miqdori tuldirish shart
price integer Mahsulotning bir dona yoki birlik narxi tuldirish shart
total_amount integer Jami summa (narx * miqdor) tuldirish shart
kis_number integer KIS tizimidagi buyurtma raqami
kis_date string KIS tizimida buyurtma kiritilgan sana
accept_by_places boolean Yuk joylari bo‘yicha qabul qilish (true/false)
vehicle_type string Transport vositasi turi (masalan, yuk mashinasi, avtobus)
vat_rate integer QQS stavkasi (foizda)
vat_amount integer QQS summasi
price_includes_vat boolean Narxga QQS kiritilganmi (true/false)
discount_amount integer Chegirma summasi
under_delivery_percent integer Yetkazib berilmagan mahsulot foizi
over_delivery_percent integer Ortiqcha yetkazib berilgan mahsulot foizi
nomenclature_package string Nomenklatura qadoqlanishi turi
package_quantity integer Qadoqlar soni

Qabul qilinishi kerak bo'lgan tovar ro'yxati

Http request

GET v1/receiving-goods/clients

curl \
--request GET \
--url "http://wms.bts.uz:8040/v1/receiving-goods/clients" \
--header  "Authorization: "Bearer token"
--header  "accept: "application/json"
--header  "Content-Type: "application/json"

SUCCESS:


  {
    "message": "Data successfully retrieved.",
    "data": {
        "items": [
            {
                "id": 10,
                "number": "string",
                "date": "2024-11-11",
                "counterparty": "string",
                "arrival_date": "2024-11-11",
                "comment": "string",
                "vehicle_model": "string",
                "vehicle_number": "string",
                "driver_name": "string",
                "driver_document": "string",
                "contract_number": "string",
                "contract_date": "2024-11-11",
                "acceptance_gate": null,
                "nomenclature": "string",
                "quantity": 20,
                "price": "200.00",
                "total_amount": "2000.00",
                "supplierDetail": {
                    "id": 7,
                    "supplier_id": 10,
                    "kis_number": null,
                    "kis_date": "2024-11-11",
                    "accept_by_places": true,
                    "vehicle_type": null,
                    "vat_rate": "20.00",
                    "vat_amount": "30.00",
                    "price_includes_vat": true,
                    "discount_amount": "40.00",
                    "under_delivery_percent": "25.00",
                    "over_delivery_percent": "50.00"
                },
                "supplierPackage": {
                    "id": 1,
                    "supplier_id": 10,
                    "nomenclature_package": "string11",
                    "package_quantity": 0
                },
                "_links": {
                    "self": {
                        "href": "http://wms.bts.uz:8040/v1/receiving-goods/view?id=10"
                    }
                }
            }
        ],
        "_links": {
            "self": "/v1/receiving-goods/clients?page=1",
            "first": "/v1/receiving-goods/clients?page=1",
            "last": "/v1/receiving-goods/clients?page=1"
        },
        "_meta": {
            "totalCount": 2,
            "pageCount": 1,
            "currentPage": 1,
            "perPage": 20
        }
    }
}
Parameter Type Description
number integer Yetkazib berish raqami
date string Yetkazib berish sanasi
counterparty string Kontragent (yukni yetkazib beruvchi tashkilot)
arrival_date string Yuk qabul qilingan sana
comment string Izoh (qo'shimcha izoh yoki sharh)
vehicle_model string Transport vositasining modeli
vehicle_number integer Transport vositasining davlat raqami
driver_name string Haydovchining to'liq ismi
driver_document string Haydovchiga tegishli hujjat (pasport, litsenziya va h.k.)
contract_number integer Shartnoma raqami
contract_date string Shartnoma sanasi
nomenclature string Nomenklatura (yukning turi yoki mahsulotlar ro‘yxati)
quantity integer Mahsulot miqdori
price integer Mahsulotning bir dona yoki birlik narxi
total_amount integer Jami summa (narx * miqdor)
kis_number integer KIS tizimidagi buyurtma raqami
kis_date string KIS tizimida buyurtma kiritilgan sana
accept_by_places boolean Yuk joylari bo‘yicha qabul qilish (true/false)
vehicle_type string Transport vositasi turi (masalan, yuk mashinasi, avtobus)
vat_rate integer QQS stavkasi (foizda)
vat_amount integer QQS summasi
price_includes_vat boolean Narxga QQS kiritilganmi (true/false)
discount_amount integer Chegirma summasi
under_delivery_percent integer Yetkazib berilmagan mahsulot foizi
over_delivery_percent integer Ortiqcha yetkazib berilgan mahsulot foizi
nomenclature_package string Nomenklatura qadoqlanishi turi
package_quantity integer Qadoqlar soni

Qabul qilinishi kerak bo'lgan tovarlar statusini yangilash

Http request

POST v1/receiving-goods/client-status

curl \
--request POST \
--url "http://wms.bts.uz:8040/v1/receiving-goods/client-status" \
--header  "Authorization\: "Bearer token"
--header  "accept\: "application/json"
--header  "Content-Type\: "application/json"
--data '{
    "status" => [
                  {"id": 1,"status": "ok"},
                  {"id": 2,"status": "ok"}
       ]
}'

SUCCESS:


{
  "message": "supplier successfully updated to delivered status"
}
  
Parameter Type Description
status array Bazangizga muvaffaqiyatli saqlangan receiving_goods IDlarini OK statusi bilan yuborishingiz kerak bo'ladi.

Xatoliklar

Xatolik kodi Ma'nosi
400 Bad Request -- Your request sucks
401 Unauthorized -- Your API key is wrong
403 Forbidden -- The kitten requested is hidden for administrators only
404 Not Found -- The specified kitten could not be found
405 Method Not Allowed -- You tried to access a kitten with an invalid method
406 Not Acceptable -- You requested a format that isn't json
410 Gone -- The kitten requested has been removed from our servers
429 Too Many Requests -- You're requesting too many kittens! Slow down!
500 Internal Server Error -- We had a problem with our server. Try again later.
503 Service Unavailable -- We're temporarially offline for maintanance. Please try again later.