> For the complete documentation index, see [llms.txt](https://docs.lionparcel.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.lionparcel.com/api/api-reference-en/api-reference/stt-booking-for-client.md).

# STT Booking for Client

This page explains the function of the STT Booking for Client API, an API used to create shipping orders and generate a tracking number (STT) directly through the client system.

### **Description**

The STT Booking API is used by clients to create shipment orders directly in the Lion Parcel system. Through this API, clients can generate an STT/receipt for each package sent without having to create it manually at the agent.

If your company has many branches or warehouse locations (fulfillment centers), each branch must use **a different API credential**. This ensures routing accuracy, tracking precision, and proper shipment operations management within the Lion Parcel network.<br>

### **Important Parameter Explanation**

**1. Insurance:** Determines whether the package uses the insurance service.

* Values for the insurance parameter:
  * **true**, the package will be insured and an additional insurance fee will be charged
    * Insurance cost is calculated based on: **item value (price) × insurance percentage** as agreed with Lion Parcel.
  * **false:** the package does not use additional insurance.
* **Note:** Make sure the field **price** is filled in correctly because it is the basis for premium calculation.

**2. Commodity:** Used to identify the type of commodity being shipped.

* The commodity value must match Lion Parcel's official commodity list.
* Each commodity has different tariff configurations, handling, and operational rules\
  (for example: electronics, fragile, documents, food, etc.).
* Filling in an incorrect commodity can cause tariff differences or shipment rejection.

**3. COD:** Enables the service **Cash on Delivery (COD)**.

* If the package is a COD package, then:
  * cod = true
  * **cod\_value** : the COD amount to be charged to the buyer.
* The COD amount will be processed according to the COD cooperation scheme between the Client and Lion Parcel.
* **Note:** If **cod = true** however **cod\_value** if not filled in, the shipment is considered invalid.

**4. Interpack Document:** Used only for service code "INTERPACK"

* If the package is an INTERPACK package, then:
  * The INTERPACK DOCUMENT parameter must be filled in according to **the regulations of the destination country**, because **each country has different document completeness requirements** (see [reference table](#tabel-referensi-ketentuan-interpack-document-per-negara) for document completeness by country).
  * Not all parameters in INTERPACK DOCUMENT are mandatory for all countries; the Mandatory/Optional status of each parameter follows the destination country's requirements as listed on the [reference table](#tabel-referensi-ketentuan-interpack-document-per-negara).
  * The value format for each parameter must comply with the applicable requirements.

<details>

<summary>Reference Table of Interpack Document Requirements by Country</summary>

<table><thead><tr><th width="72">No</th><th width="128">Country</th><th>Country Code</th><th>Other Commodities (CIPL)</th><th>Recipient Email</th><th>Before &#x26; After Packing Photos</th><th>Identity Card Photo</th><th>Identity Number</th><th>Tax Registration Card Photo</th><th>Tax Registration Number</th><th>Status</th></tr></thead><tbody><tr><td>1</td><td>Australia</td><td>AU</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Active</td></tr><tr><td>2</td><td>Austria</td><td>AUT</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Active</td></tr><tr><td>3</td><td>Bangladesh</td><td>BGD</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Active</td></tr><tr><td>4</td><td>Belgium</td><td>BEL</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Active</td></tr><tr><td>5</td><td>Brazil</td><td>BR</td><td>Required</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Required</td><td>Optional</td><td>Active</td></tr><tr><td>6</td><td>Brunei</td><td>BN</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Active</td></tr><tr><td>7</td><td>Cambodia</td><td>KH</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Active</td></tr><tr><td>8</td><td>Canada</td><td>CA</td><td>Required</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Required</td><td>Optional</td><td>Active</td></tr><tr><td>9</td><td>China</td><td>CHN</td><td>Required</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Active</td></tr><tr><td>10</td><td>Colombia</td><td>CO</td><td>Required</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Required</td><td>Optional</td><td>Active</td></tr><tr><td>11</td><td>Costa Rica</td><td>CR</td><td>Required</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Required</td><td>Optional</td><td>Active</td></tr><tr><td>12</td><td>Denmark</td><td>DK</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Active</td></tr><tr><td>13</td><td>Egypt</td><td>EGY</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Active</td></tr><tr><td>14</td><td>Finland</td><td>FI</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Active</td></tr><tr><td>15</td><td>France</td><td>FR</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Active</td></tr><tr><td>16</td><td>Germany</td><td>DE</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Active</td></tr><tr><td>17</td><td>Greece</td><td>GRC</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Active</td></tr><tr><td>18</td><td>Hong Kong</td><td>HK</td><td>Required</td><td>Optional</td><td>Required</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Active</td></tr><tr><td>19</td><td>India</td><td>IN</td><td>Required</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Required</td><td>Optional</td><td>Active</td></tr><tr><td>20</td><td>Indonesia</td><td>ID</td><td>Required</td><td>Required</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Optional</td><td>Active</td></tr><tr><td>21</td><td>Italy</td><td>ITA</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Active</td></tr><tr><td>22</td><td>Japan</td><td>JP</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Active</td></tr><tr><td>23</td><td>Kazakhstan</td><td>KZ</td><td>Required</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Required</td><td>Optional</td><td>Active</td></tr><tr><td>24</td><td>South Korea</td><td>KR</td><td>Required</td><td>Required</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Optional</td><td>Active</td></tr><tr><td>25</td><td>Kuwait</td><td>KWT</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Active</td></tr><tr><td>26</td><td>Macau</td><td>MO</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Active</td></tr><tr><td>27</td><td>Malaysia</td><td>MY</td><td>Required</td><td>Optional</td><td>Required</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Active</td></tr><tr><td>28</td><td>Mexico</td><td>MX</td><td>Required</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Required</td><td>Optional</td><td>Active</td></tr><tr><td>29</td><td>Monaco</td><td>MC</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Active</td></tr><tr><td>30</td><td>Morocco</td><td>MRC</td><td>Required</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Required</td><td>Optional</td><td>Active</td></tr><tr><td>31</td><td>Netherlands</td><td>NL</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Active</td></tr><tr><td>32</td><td>New Zealand</td><td>NZ</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Active</td></tr><tr><td>33</td><td>Oman</td><td>OMN</td><td>Required</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Required</td><td>Optional</td><td>Active</td></tr><tr><td>34</td><td>Pakistan</td><td>PAK</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Active</td></tr><tr><td>35</td><td>Peru</td><td>PE</td><td>Required</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Required</td><td>Optional</td><td>Active</td></tr><tr><td>36</td><td>Philippines</td><td>PH</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Active</td></tr><tr><td>37</td><td>Qatar</td><td>QA</td><td>Required</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Required</td><td>Optional</td><td>Active</td></tr><tr><td>38</td><td>Saudi Arabia</td><td>SA</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Active</td></tr><tr><td>39</td><td>Singapore</td><td>SG</td><td>Required</td><td>Optional</td><td>Required</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Active</td></tr><tr><td>40</td><td>South Africa</td><td>ZAF</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Active</td></tr><tr><td>41</td><td>Spain</td><td>ESP</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Active</td></tr><tr><td>42</td><td>Sri Lanka</td><td>SLK</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Active</td></tr><tr><td>43</td><td>Sweden</td><td>SWE</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Active</td></tr><tr><td>44</td><td>Taiwan</td><td>TW</td><td>Required</td><td>Optional</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Optional</td><td>Active</td></tr><tr><td>45</td><td>Thailand</td><td>TH</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Active</td></tr><tr><td>46</td><td>Timor-Leste</td><td>TL</td><td>Required</td><td>Optional</td><td>Required</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Active</td></tr><tr><td>47</td><td>Turkey</td><td>TR</td><td>Required</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Required</td><td>Optional</td><td>Active</td></tr><tr><td>48</td><td>United Arab Emirates</td><td>AE</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Active</td></tr><tr><td>49</td><td>United Kingdom</td><td>UK</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Active</td></tr><tr><td>50</td><td>United States of America</td><td>US</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Active</td></tr><tr><td>51</td><td>Venezuela</td><td>VE</td><td>Required</td><td>Required</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Optional</td><td>Active</td></tr><tr><td>52</td><td>Vietnam</td><td>VN</td><td>Required</td><td>Required</td><td>Required</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Optional</td><td>Active</td></tr></tbody></table>

</details>

### **Endpoint**

<table data-header-hidden><thead><tr><th width="141.59375"></th><th></th></tr></thead><tbody><tr><td><code>POST</code></td><td><a href="https://api-stg-middleware.thelionparcel.com/client/booking"><code>https://api-stg-middleware.thelionparcel.com/client/booking</code></a></td></tr><tr><td>URL</td><td><code>[BASE_URL]/client/booking</code></td></tr></tbody></table>

### Header

<table><thead><tr><th width="145.82421875">Name</th><th>Value</th></tr></thead><tbody><tr><td>Content-Type</td><td><code>application/json</code></td></tr><tr><td>Authorization</td><td><code>Bearer eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjI0MTYxMTc4MzAsImlhdCI6MTc4NTM5NzgzMCwidXNlcm5hbWUiOiJCT09LSU5HQVBJQ09SUERVQUJFTEFTIiwiY2xpZW50X2NvZGUiOiJDTDQzNDU5IiwiY2xpZW50X2NvZGVfZ2VuZXNpcyI6IkNMNDM0NTkiLCJpbnRlZ3JhdGlvbl90b2tlbl9pZCI6NTMsInNob3BfZG9tYWluIjoiYm9va2luZ2FwaS5jb20iLCJwbGF0Zm9ybSI6IkFQSSBMaW9uIFBhcmNlbCJ9.At7BM4uqQWpWgJ6u-xqygXQ0fO3VcPruNMNLBobUORWVyfxr63KCOgWt9cbzOK-4ikdNmd-R7Np2oC0SdLifXLWjTfWhz2wQS7aITK0YjOMkBtrCsqWHG8xsK8MiXJheko4w8C9vn4vATMI7BDL1iySw8uXbpICiU7k8TvgF4U-uxsOZlIvfEva5S17ZGeGRYTik9qjIst7Aq8IlJBww3meEl9znlNkdyuFgLZg_cUU1Jc6o5-5fUkljHelDyFuPuDm3KEDuds3ov0YKTi1EYQu266KzTXdhgWtyf6-98RHQlbic6o_RZ4KeNb6YrtC63AHHLonmkrmUGH7TdH09sQ</code></td></tr></tbody></table>

### **Request Body**

| Field                       | Data Type       | Is Required                                       | Sample Value              | Description                                                                    |
| --------------------------- | --------------- | ------------------------------------------------- | ------------------------- | ------------------------------------------------------------------------------ |
| stt\_no                     | STRING          | NO                                                | 98LP1657731805369         | Manual STT number                                                              |
| stt\_no\_ref\_external      | STRING          | NO                                                | INV261101DO               | Client reference number                                                        |
| stt\_tax\_number            | STRING          | NO                                                | 09.314.652.0-987.319      | Client tax numbers                                                             |
| stt\_goods\_estimate\_price | INT             | YES                                               | 10000                     | Client estimated goods price                                                   |
| stt\_goods\_status          | STRING          | NO                                                | ecommers                  | Client goods status                                                            |
| stt\_origin                 | STRING          | YES                                               | KEBON JERUK, WEST JAKARTA | Origin route                                                                   |
| stt\_destination            | STRING          | YES                                               | KEBON JERUK, WEST JAKARTA | Destination route                                                              |
| stt\_sender\_name           | STRING          | YES                                               | Liona                     | Sender Name                                                                    |
| stt\_sender\_phone          | INT             | YES                                               | 0872849283718             | Sender phone                                                                   |
| stt\_sender\_address        | STRING          | YES                                               | Kedoya Raya Street        | Sender Address                                                                 |
| stt\_recipient\_name        | STRING          | YES                                               | Lio Lio                   | Consignee’s name                                                               |
| stt\_recipient\_address     | STRING          | YES                                               | Jl Belimbing 05           | Consignee’s address for delivery                                               |
| stt\_recipient\_phone       | INT             | YES                                               | 08123123123123            | Consignee’s contact number                                                     |
| stt\_insurance\_type        | STRING          | YES                                               | free                      | Insurance type, free or basic                                                  |
| stt\_product\_type          | STRING          | YES                                               | REGPACK                   | Product name                                                                   |
| stt\_commodity\_code        | STRING          | YES                                               | ABR036                    | Commodity code                                                                 |
| stt\_is\_cod                | BOOLEAN         | YES                                               | true                      | True, if the shipment is COD.                                                  |
| stt\_is\_woodpacking        | BOOLEAN         | YES                                               | no                        | True, if the shipment uses wood packing.                                       |
| stt\_pieces                 | ARRAY OF OBJECT | YES                                               | Raw data                  | <p>Package detail per piece<br>Max total 15 pcs<br>Max total weight 400 Kg</p> |
| stt\_cod\_amount            | INT             | <p>YES if shipment is COD</p><p><br></p><p>NO</p> | 10000                     | COD amount to be payment                                                       |

**\[stt\_pieces] structure**

| Field                     | Data Type | Is Required | Sample Value | Description         |
| ------------------------- | --------- | ----------- | ------------ | ------------------- |
| stt\_piece\_length        | INT       | YES         | 10           | Actual piece length |
| stt\_piece\_width         | INT       | YES         | 20           | Actual piece width  |
| stt\_piece\_height        | INT       | YES         | 30           | Actual piece height |
| stt\_piece\_gross\_weight | FLOAT64   | YES         | 1            | Actual gross weight |

### Packages and product information

`stt_pieces` describes the parcels in the shipment. Each object in this array represents one physical package, along with its dimensions and weight. Send at least one and at most 15 objects `stt_pieces` in one shipment.

`products` is optional and describes the contents of the items to be printed on the label. You can send up to 50 product entries. The value `qty` indicates the number of units for each product and does not determine the number of parcels.

Example: one parcel can contain three red shirts. Send one object `stt_pieces` and one product entry with `name: "Red Shirt"` and `qty: 3`.

If `products` not sent, the label does not display item information. The label displays the names of the first eight product entries at most, in array order `products`.

| Key     | Data Type | Required | Sample Value   | Description             |
| ------- | --------- | -------- | -------------- | ----------------------- |
| name    | STRING    | FALSE    | case iphone 15 | min 1 char, max 50 char |
| variant | STRING    | FALSE    | red            | min 1 char, max 50 char |
| qty     | INTEGER   | FALSE    | 1              | Minimum 1 - no max      |

**\[Detail] Interpack Document Structure**

| Key                            | Data Type       | Required | Sample Value                     | Description                                    |
| ------------------------------ | --------------- | -------- | -------------------------------- | ---------------------------------------------- |
| cipls                          | ARRAY OF OBJECT | TRUE     | -                                | Maximum 15 items                               |
| commodity\_name                | STRING          | TRUE     | GEN                              | Commodity name (free text)                     |
| item\_detail                   | STRING          | TRUE     | Electronics                      | Item detail (free text)                        |
| quantity                       | INTEGER         | TRUE     | 1                                | Item quantity                                  |
| item\_price                    | INTEGER         | TRUE     | 100000                           | Price per item                                 |
| recipient\_email               | STRING          | TRUE     | <tester@gmail.com>               | Recipient email                                |
| recipient\_identity\_number    | STRING          | TRUE     | 2276543210123456                 | Recipient identity number                      |
| recipient\_tax\_number         | STRING          | TRUE     | 1126543210123456                 | Recipient tax number                           |
| identity\_card\_file           | STRING (URL)    | TRUE     | <https://example.com/ktp.jpg>    | Recipient ID card photo file (.jpg/.jpeg/.png) |
| tax\_number\_file              | STRING (URL)    | TRUE     | <https://example.com/npwp.jpg>   | Recipient tax ID photo file (.jpg/.jpeg/.png)  |
| package\_before\_packing\_file | STRING (URL)    | TRUE     | <https://example.com/before.jpg> | Package photo before packing (.jpg/.jpeg/.png) |
| package\_after\_packing\_file  | STRING (URL)    | TRUE     | <https://example.com/after.jpg>  | Package photo after packing (.jpg/.jpeg/.png)  |

## Test It: STT Booking for Client

> Create a shipment order directly and generate an STT (tracking number), without any manual step at a branch. Each branch or fulfillment center must use its own credentials.<br>

```json
{"openapi":"3.0.3","info":{"title":"Lion Parcel API","version":"1.1.1"},"tags":[{"name":"STT Booking","description":"Create a shipping order (STT) directly."}],"servers":[{"url":"https://api-stg-middleware.thelionparcel.com","description":"Staging"}],"paths":{"/client/booking":{"post":{"operationId":"sttBookingClient","summary":"Test It: STT Booking for Client","description":"Create a shipment order directly and generate an STT (tracking number), without any manual step at a branch. Each branch or fulfillment center must use its own credentials.\n","tags":["STT Booking"],"parameters":[{"name":"Authorization","in":"header","required":true,"description":"Staging Bearer token for this client.","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["stt"],"properties":{"stt":{"$ref":"#/components/schemas/SttBookingRequestBase"}}}}}},"responses":{"201":{"description":"STT created successfully.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SttBookingResponseSuccess"}}}},"400":{"description":"Could not create the STT.","content":{"application/json":{"schema":{"type":"object","properties":{"code":{"type":"integer","description":"HTTP status code."},"message":{"$ref":"#/components/schemas/ErrorMessage"}}}}}}}}}},"components":{"schemas":{"SttBookingRequestBase":{"type":"object","description":"Shared fields for creating an STT (shipping order) across Client, CBP, and POS booking.","required":["stt_goods_estimate_price","stt_origin","stt_destination","stt_sender_name","stt_sender_phone","stt_sender_address","stt_recipient_name","stt_recipient_address","stt_recipient_phone","stt_insurance_type","stt_product_type","stt_commodity_code","stt_is_cod","stt_is_woodpacking","stt_pieces"],"properties":{"stt_no":{"type":"string","description":"Manual STT number. Leave empty to let the system generate one."},"stt_no_ref_external":{"type":"string","description":"Your own external reference number for this order."},"stt_tax_number":{"type":"string","description":"Sender's tax ID number, if required."},"stt_goods_estimate_price":{"type":"integer","description":"Estimated value of the goods, in IDR."},"stt_goods_status":{"type":"string","description":"Goods status, e.g. \"ecommerce\"."},"stt_origin":{"type":"string","description":"Origin area, in \"SUBDISTRICT, CITY\" format."},"stt_destination":{"type":"string","description":"Destination area, in \"SUBDISTRICT, CITY\" format."},"stt_sender_name":{"type":"string","description":"Sender's full name."},"stt_sender_phone":{"type":"string","description":"Sender's phone number, including the leading 0."},"stt_sender_address":{"type":"string","description":"Sender's full address."},"stt_recipient_name":{"type":"string","description":"Recipient's full name."},"stt_recipient_address":{"type":"string","description":"Recipient's full address."},"stt_recipient_phone":{"type":"string","description":"Recipient's phone number, including the leading 0."},"stt_insurance_type":{"type":"string","description":"Insurance option for this shipment.","enum":["free","basic"]},"stt_product_type":{"type":"string","description":"Shipping product code."},"stt_commodity_code":{"type":"string","description":"Commodity code for the goods being shipped."},"stt_is_cod":{"type":"boolean","description":"Whether this is a Cash on Delivery order."},"stt_is_dfod":{"type":"boolean","description":"Whether this is a Delivery Fee on Delivery order."},"stt_is_woodpacking":{"type":"boolean","description":"Whether the package requires wood packing."},"stt_pieces":{"type":"array","description":"List of package pieces. Maximum 15 pieces, maximum total weight 400 kg.","items":{"$ref":"#/components/schemas/Piece"}},"stt_piece_per_pack":{"type":"integer","description":"Number of pieces per pack, if applicable."},"stt_next_commodity":{"type":"string","description":"Secondary commodity code, if applicable."},"stt_cod_amount":{"type":"integer","description":"COD amount to collect. Required if stt_is_cod is true."},"products":{"type":"array","description":"Products to show on the printed shipping label.","items":{"$ref":"#/components/schemas/Product"}},"interpack_document":{"$ref":"#/components/schemas/InterpackDocument"}}},"Piece":{"type":"object","description":"Dimensions and weight of a single package piece.","required":["stt_piece_length","stt_piece_width","stt_piece_height","stt_piece_gross_weight"],"properties":{"stt_piece_length":{"type":"integer","description":"Length, in cm."},"stt_piece_width":{"type":"integer","description":"Width, in cm."},"stt_piece_height":{"type":"integer","description":"Height, in cm."},"stt_piece_gross_weight":{"type":"integer","description":"Actual weight, in kg."}}},"Product":{"type":"object","description":"Product line shown on the printed shipping label.","properties":{"name":{"type":"string","description":"Product name.","maxLength":50},"variant":{"type":"string","description":"Product variant, e.g. color or size.","maxLength":50},"qty":{"type":"integer","description":"Quantity.","minimum":1}}},"InterpackDocument":{"type":"object","description":"Required only when the service code is \"INTERPACK\" (international shipments).","required":["cipls","recipient_email","recipient_identity_number","recipient_tax_number","identity_card_file","tax_number_file","package_before_packing_file","package_after_packing_file"],"properties":{"cipls":{"type":"array","description":"Itemized customs invoice/packing list (CIPL). Maximum 15 items.","maxItems":15,"items":{"type":"object","required":["commodity_name","item_detail","quantity","item_price"],"properties":{"commodity_name":{"type":"string","description":"Commodity name (free text)."},"item_detail":{"type":"string","description":"Item description (free text)."},"quantity":{"type":"integer","description":"Number of units.","minimum":1},"item_price":{"type":"number","description":"Price per item."}}}},"recipient_email":{"type":"string","description":"Recipient's email address, required for customs documentation."},"recipient_identity_number":{"type":"string","description":"Recipient's national ID number."},"recipient_tax_number":{"type":"string","description":"Recipient's tax ID number (NPWP or equivalent)."},"identity_card_file":{"type":"string","format":"uri","description":"URL of the recipient's scanned ID card."},"tax_number_file":{"type":"string","format":"uri","description":"URL of the recipient's scanned tax document."},"package_before_packing_file":{"type":"string","format":"uri","description":"Photo of the package before it was packed."},"package_after_packing_file":{"type":"string","format":"uri","description":"Photo of the package after it was packed."}}},"SttBookingResponseSuccess":{"type":"object","properties":{"success":{"type":"boolean","description":"Whether the request succeeded."},"code":{"type":"integer","description":"HTTP status code."},"message":{"$ref":"#/components/schemas/ErrorMessage"},"data":{"type":"object","properties":{"stt":{"type":"array","description":"Details of the created STT(s).","items":{"type":"object","properties":{"stt_no":{"type":"string","description":"Generated STT (tracking) number."},"stt_id":{"type":"integer","description":"Internal STT ID."},"origin":{"type":"string","description":"Resolved origin area."},"destination":{"type":"string","description":"Resolved destination area."},"origin_code":{"type":"string","description":"Origin branch code."},"destination_code":{"type":"string","description":"Destination branch code."},"ursa_code_destination":{"type":"string","description":"Destination routing (URSA) code."}}}}}}}},"ErrorMessage":{"type":"object","description":"Bilingual error message returned by the API.","properties":{"en":{"type":"string","description":"Error message in English."},"id":{"type":"string","description":"Error message in Indonesian."}}}}}}
```

### Request Example

```json
{
  "stt": {
    "stt_no": "",
    "stt_no_ref_external": "aalkmsmklsml",
    "stt_tax_number": "",
    "stt_goods_estimate_price": 10000,
    "stt_goods_status": "",
    "stt_origin": "KEBON JERUK, WEST JAKARTA",
    "stt_destination": "ANDIR, BANDUNG",
    "stt_sender_name": "LIO LIO",
    "stt_sender_phone": "+628965327632",
    "stt_sender_address": " jl. Kedoya testing manchester city",
    "stt_recipient_name": "LIONA",
    "stt_recipient_address": "jl. santiago bernabeu 123",
    "stt_recipient_phone": "089589309432",
    "stt_insurance_type": "free", // free or basic
    "stt_product_type": "REGPACK",
    "stt_commodity_code": "ABR036",
    "stt_is_cod": false, // true or false
    "stt_is_dfod": false, // true or false
    "stt_is_woodpacking": false, // true or false
    "stt_pieces": [
      {
        "stt_piece_length": 10,
        "stt_piece_width": 10,
        "stt_piece_height": 10,
        "stt_piece_gross_weight": 1
      }
    ],
    "stt_cod_amount": 0,
    "interpack_document": {
      "cipls": [
        {
          "commodity_name": "ABR036",
          "item_detail": "Electronics",
          "quantity": 1,
          "item_price": 100000
        }
      ],
      "recipient_email": "tester@gmail.com",
      "recipient_identity_number": "321321313213213",
      "recipient_tax_number": "3213131321321321",
      "identity_card_file": "https://dummyimage.com/300x300/000000/000000.jpg",
      "tax_number_file": "https://dummyimage.com/300x300/000000/000000.jpg",
      "package_before_packing_file": "https://dummyimage.com/300x300/000000/000000.jpg",
      "package_after_packing_file": "https://dummyimage.com/300x300/000000/000000.jpg"
    },
    "products": [
      {
        "name": "Case HP Iphone",
        "Variant": "Red",
        "qty": 1
      }
    ]
  }
}
```

### **Response**

{% tabs %}
{% tab title="200" %}

```json
{
  "success": true,
  "code": 201,
  "message": {
    "en": "",
    "id": ""
  },
  "data": {
    "stt": [
      {
        "stt_no": "99LP1643967341740",
        "stt_id": 31579,
        "origin": "KEBON JERUK, WEST JAKARTA",
        "destination": "KEBON JERUK, WEST JAKARTA",
        "origin_code": "CGK",
        "destination_code": "CGK",
        "ursa_code_destination": "1KDY"
      }
    ]
  }
}
```

{% endtab %}

{% tab title="400" %}

```json
{
  "code": 400,
  "message": {
    "en": "External Number is already used",
    "id": "External number already used"
  }
}

{
  "code": 100,
  "message": {
    "en": "Failed to get district",
    "id": "Failed to get district"
  }
}

{
    "success": false,
    "code": 400,
    "message": {
        "en": "Identity card file cannot be empty",
        "id": "Identity card file cannot be empty"
    }
}

{
    "success": false,
    "code": 400,
    "message": {
        "en": "Tax file cannot be empty",
        "id": "Tax file cannot be empty"
    }
}

{
    "success": false,
    "code": 400,
    "message": {
        "en": "Package Before Packing File cannot be empty",
        "id": "Package Before Packing File cannot be empty"
    }
}

{
    "success": false,
    "code": 400,
    "message": {
        "en": "Recipient Identity Number cannot be empty",
        "id": "Recipient Identity Number cannot be empty"
    }
}
```

{% endtab %}
{% endtabs %}


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.lionparcel.com/api/api-reference-en/api-reference/stt-booking-for-client.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
