# delivery



# create booking

##### Endpoint

<table border="1" id="bkmrk-endpoint-method-auth" style="border-collapse: collapse; width: 100%;"><colgroup><col style="width: 33.3333%;"></col><col style="width: 33.3333%;"></col><col style="width: 33.3333%;"></col></colgroup><tbody><tr><td>**Endpoint**</td><td>**Method**  
</td><td>**Authentication**</td></tr><tr><td>/booking/delivery/user/create</td><td>POST</td><td>yes</td></tr></tbody></table>

##### Authentication

<table border="1" id="bkmrk-endpoint-method-serv" style="border-collapse: collapse; width: 100%; height: 59.757px;"><colgroup><col style="width: 29.5467%;"></col><col style="width: 45.5054%;"></col><col style="width: 24.9617%;"></col></colgroup><tbody><tr style="height: 29.8785px;"><td style="height: 29.8785px;">**Type**  
</td><td style="height: 29.8785px;">**Token source**  
</td><td style="height: 29.8785px;">**Server**  
</td></tr><tr style="height: 29.8785px;"><td style="height: 29.8785px;">Bearer</td><td style="height: 29.8785px;">[USAPI LOGIN](https://documentation.onindonesia.id/books/usapi/page/login "USAPI LOGIN")</td><td style="height: 29.8785px;">usapi</td></tr></tbody></table>

<table border="1" id="bkmrk-field-data-type-note" style="border-collapse: collapse; width: 915px; height: 1134.28px; border-width: 1px; border-style: solid;" width="144"><colgroup><col span="2" style="width: 9.66667px;" width="72"></col><col style="width: 10.1667px;"></col></colgroup><tbody><tr style="height: 31.7969px;"><td class="align-center" height="20" style="width: 54pt; height: 31.7969px;" width="72">**Field**</td><td class="align-center" style="width: 27pt; height: 31.7969px;" width="72">**Data Type**</td><td class="align-center" style="width: 27pt; height: 31.7969px;">**Notes**</td></tr><tr style="height: 29.7969px;"><td height="20" style="height: 29.7969px;">package\_info</td><td style="height: 29.7969px;">Array of Objects</td><td style="height: 29.7969px;">  
</td></tr><tr style="height: 29.7969px;"><td height="20" style="height: 29.7969px;">- origin\_id</td><td style="height: 29.7969px;">Integer</td><td style="height: 29.7969px;">  
</td></tr><tr style="height: 29.7969px;"><td height="20" style="height: 29.7969px;">- destination\_id</td><td style="height: 29.7969px;">Integer</td><td style="height: 29.7969px;">  
</td></tr><tr style="height: 29.7969px;"><td height="20" style="height: 29.7969px;">- service\_id</td><td style="height: 29.7969px;">Integer</td><td style="height: 29.7969px;">  
</td></tr><tr style="height: 29.7969px;"><td height="20" style="height: 29.7969px;">- sender\_name</td><td style="height: 29.7969px;">String</td><td style="height: 29.7969px;">  
</td></tr><tr style="height: 29.7969px;"><td height="20" style="height: 29.7969px;">- sender\_phone</td><td style="height: 29.7969px;">String</td><td style="height: 29.7969px;">  
</td></tr><tr style="height: 29.7969px;"><td height="20" style="height: 29.7969px;">- sender\_address</td><td style="height: 29.7969px;">String</td><td style="height: 29.7969px;">  
</td></tr><tr style="height: 29.7969px;"><td height="20" style="height: 29.7969px;">- receiver\_name</td><td style="height: 29.7969px;">String</td><td style="height: 29.7969px;">  
</td></tr><tr style="height: 29.7969px;"><td height="20" style="height: 29.7969px;">- receiver\_phone</td><td style="height: 29.7969px;">String</td><td style="height: 29.7969px;">  
</td></tr><tr style="height: 29.7969px;"><td height="20" style="height: 29.7969px;">- receiver\_address</td><td style="height: 29.7969px;">String</td><td style="height: 29.7969px;">  
</td></tr><tr style="height: 29.7969px;"><td height="20" style="height: 29.7969px;">- goods\_id</td><td style="height: 29.7969px;">Integer</td><td style="height: 29.7969px;">  
</td></tr><tr style="height: 29.7969px;"><td height="20" style="height: 29.7969px;">- goods\_desc</td><td style="height: 29.7969px;">String</td><td style="height: 29.7969px;">  
</td></tr><tr style="height: 29.7969px;"><td height="20" style="height: 29.7969px;">- goods\_weight</td><td style="height: 29.7969px;">Float</td><td style="height: 29.7969px;">  
</td></tr><tr style="height: 29.7969px;"><td height="20" style="height: 29.7969px;">- length</td><td style="height: 29.7969px;">Float</td><td style="height: 29.7969px;">  
</td></tr><tr style="height: 29.7969px;"><td height="20" style="height: 29.7969px;">- width</td><td style="height: 29.7969px;">Float</td><td style="height: 29.7969px;">  
</td></tr><tr style="height: 29.7969px;"><td height="20" style="height: 29.7969px;">- height</td><td style="height: 29.7969px;">Float</td><td style="height: 29.7969px;">  
</td></tr><tr style="height: 29.7969px;"><td height="20" style="height: 29.7969px;">- voucher</td><td style="height: 29.7969px;">String</td><td style="height: 29.7969px;">  
</td></tr><tr style="height: 29.7969px;"><td height="20" style="height: 29.7969px;">- notes</td><td style="height: 29.7969px;">String</td><td style="height: 29.7969px;">  
</td></tr><tr style="height: 29.7969px;"><td height="20" style="height: 29.7969px;">- insurance\_exist</td><td style="height: 29.7969px;">Boolean</td><td style="height: 29.7969px;">  
</td></tr><tr style="height: 29.7969px;"><td height="20" style="height: 29.7969px;">- koli</td><td style="height: 29.7969px;">Integer</td><td style="height: 29.7969px;">  
</td></tr><tr style="height: 29.7969px;"><td height="20" style="height: 29.7969px;">- origin\_city</td><td style="height: 29.7969px;">Integer</td><td style="height: 29.7969px;">  
</td></tr><tr style="height: 29.7969px;"><td height="20" style="height: 29.7969px;">- destination\_city</td><td style="height: 29.7969px;">Integer</td><td style="height: 29.7969px;">  
</td></tr><tr style="height: 29.7969px;"><td height="20" style="height: 29.7969px;">- goods\_value</td><td style="height: 29.7969px;">Float</td><td style="height: 29.7969px;">  
</td></tr><tr style="height: 29.7969px;"><td height="20" style="height: 29.7969px;">- estimate\_price</td><td style="height: 29.7969px;">Integer</td><td style="height: 29.7969px;">  
</td></tr><tr style="height: 29.7969px;"><td height="20" style="height: 29.7969px;">- packing\_value</td><td style="height: 29.7969px;">Integer</td><td style="height: 29.7969px;">  
</td></tr><tr style="height: 29.7969px;"><td height="20" style="height: 29.7969px;">- payment\_type</td><td style="height: 29.7969px;">String</td><td style="height: 29.7969px;">Possible values: <div><div>"CASH", "COC", "TRANSFER", "QRIS"</div></div></td></tr><tr style="height: 29.7969px;"><td height="20" style="height: 29.7969px;">department</td><td style="height: 29.7969px;">String</td><td style="height: 29.7969px;">  
</td></tr><tr style="height: 29.7969px;"><td height="20" style="height: 29.7969px;">mode</td><td style="height: 29.7969px;">String</td><td style="height: 29.7969px;">  
</td></tr><tr style="height: 29.7969px;"><td height="20" style="height: 29.7969px;">pickup\_loc</td><td style="height: 29.7969px;">Object</td><td style="height: 29.7969px;">  
</td></tr><tr style="height: 29.7969px;"><td height="20" style="height: 29.7969px;">- lat</td><td style="height: 29.7969px;">Float</td><td style="height: 29.7969px;">  
</td></tr><tr style="height: 29.7969px;"><td height="20" style="height: 29.7969px;">- long</td><td style="height: 29.7969px;">Float</td><td style="height: 29.7969px;">  
</td></tr><tr style="height: 29.7969px;"><td height="20" style="height: 29.7969px;">- urban\_id</td><td style="height: 29.7969px;">Integer</td><td style="height: 29.7969px;">  
</td></tr><tr style="height: 29.7969px;"><td height="20" style="height: 29.7969px;">- sub\_district\_id</td><td style="height: 29.7969px;">Integer</td><td style="height: 29.7969px;">  
</td></tr><tr style="height: 29.7969px;"><td height="20" style="height: 29.7969px;">- city\_id</td><td style="height: 29.7969px;">Integer</td><td style="height: 29.7969px;">  
</td></tr><tr style="height: 29.7969px;"><td height="20" style="height: 29.7969px;">- full\_address</td><td style="height: 29.7969px;">String</td><td style="height: 29.7969px;">  
</td></tr><tr style="height: 29.7969px;"><td height="20" style="height: 29.7969px;">phone\_number</td><td style="height: 29.7969px;">String</td><td style="height: 29.7969px;">  
</td></tr><tr style="height: 29.7969px;"><td height="20" style="height: 29.7969px;">relation\_mode</td><td style="height: 29.7969px;">String</td><td style="height: 29.7969px;">  
</td></tr></tbody></table>


##### Body request

```json
{
    "package_info": [
        {
            "origin_id": 25207,
            "destination_id": 25208,
            "service_id": 2,
            "sender_name": "Test",
            "sender_phone": "000000",
            "sender_address": "test",
            "receiver_name": "Test",
            "receiver_phone": "000000",
            "receiver_address": "Test",
            "goods_id": 31,
            "goods_desc": "Test",
            "goods_weight": 4,
            "length": 0,
            "width": 0,
            "height": 0,
            "voucher": "",
            "notes": "",
            "insurance_exist": false,
            "koli": 1,
            "origin_city": 476,
            "destination_city": 156,
            "goods_value": 0,
            "estimate_price": 60000,
            "packing_value": 2000,
            "payment_type": "QRIS"
        }
    ],
    "department": "ONDELIVERY",
    "mode": "PICKUP",
    "pickup_loc": {
        "lat": -6.1613542,
        "long": 106.9257834,
        "urban_id": 0,
        "sub_district_id": 0,
        "city_id": 156,
        "full_address": "  Cakung Barat, Cakung Barat, "
    },
    "phone_number": "000000",
    "relation_mode": "1"
}
```

<details id="bkmrk-result-example-body-"><summary>Result example</summary>

<p class="callout info">200 Ok</p>

```javascript
insert code here
```

</details><details id="bkmrk-error-example-body-r"><summary>Error example</summary>

<p class="callout danger">Body request example</p>

```javascript
insert code here
```

</details>

# Booking details

##### Endpoint

<table border="1" id="bkmrk-endpoint-method-auth" style="border-collapse: collapse; width: 100%; height: 59.5938px;"><colgroup><col style="width: 33.3333%;"></col><col style="width: 33.3333%;"></col><col style="width: 33.3333%;"></col></colgroup><tbody><tr style="height: 29.7969px;"><td style="height: 29.7969px;">**Endpoint**</td><td style="height: 29.7969px;">**Method**  
</td><td style="height: 29.7969px;">**Authentication**</td></tr><tr style="height: 29.7969px;"><td style="height: 29.7969px;"><span data-offset-key="9ghc6-1-0"><span data-text="true">/booking/delivery/user/detail</span></span></td><td style="height: 29.7969px;">GET</td><td style="height: 29.7969px;">yes</td></tr></tbody></table>

##### Authentication

<table border="1" id="bkmrk-endpoint-method-serv" style="border-collapse: collapse; width: 100%; height: 59.757px;"><colgroup><col style="width: 29.5467%;"></col><col style="width: 45.5054%;"></col><col style="width: 24.9617%;"></col></colgroup><tbody><tr style="height: 29.8785px;"><td style="height: 29.8785px;">**Type**  
</td><td style="height: 29.8785px;">**Token source**  
</td><td style="height: 29.8785px;">**Server**  
</td></tr><tr style="height: 29.8785px;"><td style="height: 29.8785px;">Bearer</td><td style="height: 29.8785px;">[USAPI LOGIN](https://documentation.onindonesia.id/books/usapi/page/login "USAPI LOGIN")</td><td style="height: 29.8785px;">USAPI</td></tr></tbody></table>

##### Param request

<table border="1" id="bkmrk-properties-propertie" style="border-collapse: collapse; width: 100%; height: 59.5938px;"><colgroup><col style="width: 34.7245%;"></col><col style="width: 29.676%;"></col><col style="width: 35.5995%;"></col></colgroup><tbody><tr style="height: 29.7969px;"><td style="height: 29.7969px;">**Properties**  
</td><td style="height: 29.7969px;">**Required**</td><td style="height: 29.7969px;">**Description**</td></tr><tr style="height: 29.7969px;"><td style="height: 29.7969px;">booking\_id</td><td style="height: 29.7969px;">yes</td><td style="height: 29.7969px;">booking code generated from </td></tr></tbody></table>

##### Link example

<span class="resolvedVariable" data-testid="resolvedVariable" spellcheck="false"><span data-offset-key="9ghc6-0-0"><span data-text="true">{{demo}}</span></span></span><span data-offset-key="9ghc6-1-0"><span data-text="true">/booking/delivery/user/detail?booking\_id=11113BE</span></span>

<details id="bkmrk-result-example-body-"><summary>Result example</summary>

<p class="callout info">OK (200)</p>

```json
{
    "package_info": [
        {
            "id": 4062,
            "booking_onapps_id": 4080,
            "destination_id": 25208,
            "origin_id": 25207,
            "service_id": 2,
            "sender_name": "Test",
            "sender_phone": "000000",
            "sender_address": "test",
            "receiver_name": "Test",
            "receiver_phone": "000000",
            "receiver_address": "Test",
            "goods_id": 31,
            "goods_desc": "Test",
            "goods_weight": 4,
            "length": 0,
            "width": 0,
            "height": 0,
            "koli": 1,
            "notes": "",
            "insurance_exist": false,
            "goods_value": 0,
            "packing_value": 0,
            "estimate_price": 60000,
            "voucher": null,
            "voucher_id": null,
            "discount_value": null,
            "voucher_type": null,
            "payment_type": "QRIS",
            "payment_note": "00020101021226570011ID.DANA.WWW011893600915060486424802096048642480303UKE51440014ID.CO.QRIS.WWW0215ID20243148326170303UKE5204899953033605405600005802ID5925PT OnIndonesia Sistem Tek6015Kota Jakarta Ut610514240627201156QVVSAkXzjPkQaR60490011ID.DANA.WWW0425MER20210714007745096086410501163042741",
            "createdAt": "2024-05-15T09:53:02.732Z",
            "updatedAt": "2024-05-15T09:53:02.732Z",
            "insurance_fee": 0,
            "fee_after_discount": 60000,
            "total_fee": 60000
        }
    ],
    "type": "PICKUP",
    "user": "usernew1",
    "address": {
        "lat": -6.1613542,
        "long": 106.9257834,
        "urban_id": 0,
        "sub_district_id": 0,
        "city_id": 156,
        "full_address": "  Cakung Barat, Cakung Barat, "
    },
    "timestamp": "2024-05-15T09:53:02.325Z",
    "phone_number": "000000",
    "status": "BOOKING_CANCELLED",
    "booking_id": "11113BE",
    "driver_id": null,
    "kurir_name": null,
    "kurir_phone": null,
    "exp_payment_time": "2024-05-15T09:53:32.324Z"
}
```

</details><details id="bkmrk-error-example-body-r"><summary>Error example</summary>

<p class="callout danger">Body request example</p>

```javascript
insert code here
```

</details>

# Booking check QRIS

##### Endpoint

<table border="1" id="bkmrk-endpoint-method-auth" style="border-collapse: collapse; width: 100%; height: 59.5938px;"><colgroup><col style="width: 33.3333%;"></col><col style="width: 33.3333%;"></col><col style="width: 33.3333%;"></col></colgroup><tbody><tr style="height: 29.7969px;"><td style="height: 29.7969px;">**Endpoint**</td><td style="height: 29.7969px;">**Method**  
</td><td style="height: 29.7969px;">**Authentication**</td></tr><tr style="height: 29.7969px;"><td style="height: 29.7969px;"><span data-offset-key="9ghc6-1-0"><span data-text="true">/booking/delivery/user/detail/qr</span></span></td><td style="height: 29.7969px;">GET</td><td style="height: 29.7969px;">yes</td></tr></tbody></table>

##### Authentication

<table border="1" id="bkmrk-endpoint-method-serv" style="border-collapse: collapse; width: 100%; height: 59.757px;"><colgroup><col style="width: 29.5467%;"></col><col style="width: 45.5054%;"></col><col style="width: 24.9617%;"></col></colgroup><tbody><tr style="height: 29.8785px;"><td style="height: 29.8785px;">**Type**  
</td><td style="height: 29.8785px;">**Token source**  
</td><td style="height: 29.8785px;">**Server**  
</td></tr><tr style="height: 29.8785px;"><td style="height: 29.8785px;">Bearer</td><td style="height: 29.8785px;">[USAPI LOGIN](https://documentation.onindonesia.id/books/usapi/page/login "USAPI LOGIN")</td><td style="height: 29.8785px;">USAPI</td></tr></tbody></table>

##### Param request

<table border="1" id="bkmrk-properties-propertie" style="border-collapse: collapse; width: 100%; height: 59.5938px;"><colgroup><col style="width: 34.7245%;"></col><col style="width: 29.676%;"></col><col style="width: 35.5995%;"></col></colgroup><tbody><tr style="height: 29.7969px;"><td style="height: 29.7969px;">**Properties**  
</td><td style="height: 29.7969px;">**Required**</td><td style="height: 29.7969px;">**Description**</td></tr><tr style="height: 29.7969px;"><td style="height: 29.7969px;">booking\_id</td><td style="height: 29.7969px;">yes</td><td style="height: 29.7969px;">booking code generated from </td></tr></tbody></table>

##### Link example

<span class="resolvedVariable" data-testid="resolvedVariable" spellcheck="false"><span data-offset-key="9ghc6-0-0"><span data-text="true">{{demo}}</span></span></span><span data-offset-key="9ghc6-1-0"><span data-text="true">/booking/delivery/user/detail/qr?booking\_id=11113BE</span></span>

<details id="bkmrk-result-example-body-"><summary>Result example</summary>

<p class="callout info">OK (200)</p>

```json
{
    "qr_status": "EXPIRED"
}
```

</details><details id="bkmrk-error-example-body-r"><summary>Error example</summary>

<p class="callout danger">Body request example</p>

```javascript
insert code here
```

</details>