Skip to main content

Create Your First Delivery

Order Types & Codes

Bosta provides four primary order types. Use the numeric Code in your API request to specify the service you need.

TypeCodeDescription
Deliver10Standard order where your customer buys your product and you deliver it to them.
Cash Collection15Used when you need to collect cash from a customer.
Exchange30Bosta picks up a new order from you, delivers it to the customer, and returns the exchanged package to you.
CRP (Customer Return Pickup)25Used when your customer asks to return an order.

Order specifications

With every order you can add the order specifications which are:

  • Package type: This should be one of out types as the following ("SMALL" - "MEDIUM" - "LARGE" - "Light Bulky" - "Heavy Bulky" )
  • package Details: This one includes the description of the order and the items count

Example of the parameters

{
"specs": {
"packageDetails": {
"description": "your package description",
"itemsCount": 5
},
"packageType": "Small"
}
}

Create Your First Order

To create your first order you need to use the following api:

POST
https://app.bosta.co/api/v2
/deliveries?apiVersion=1
More Info

To create bulk orders you can use the following api:

POST
https://app.bosta.co/api/v2
/deliveries/bulk?apiVersion=1
More Info
Important Note - More Info

The request payload has 2 types of address.

  • pickupAddress: The address from which the order will be picked up. Must be specified when the order type is Cash Collection or CRP, since we will pick up the cash or the order from your customer. For the other types providing the pickupAddress is optional.
  • dropOffAddress: The address to which the order will be delivered. Must be specified when the order type is Deliver and Exchange For the other types, providing the address is optional.

Examples:

  • When you create CRP Order. The payload needs to be as follow:
{
pickupAddress: (required) // the customer address,
businessLocationId: your location id to which the order will be returned (If not added we will return it to your default location)
}
  • When you create Deliver Order the payload needs to be as follow:
{
dropOffAddress: (required) // the customer address,
businessLocationId: your location id from which the order will be pickup up (If not added we will pick it from your default location)
}
  • goodsInfo must be added correctly, because if it is ommited the insurance will not be calculated. :::
Important Note
  • If you choose to use FlexShip, Bosta will charge a fee only when the End User refuses to receive the order at the door. This feature helps protect Partners from refusal-related losses. In such cases, the End User will also be charged a variable service fee. FlexShip can be enabled by default or per delivery from the settings and is only available for orders with the "Allow Open Package" option.

Error Codes

CodeMessage
1061Some deliveries failed, please fix them and upload again.
1073You should have a business location before creating an order
3001City Not Found
3002Zone Not Found
3003District Not Found
3004Street Code Not Found
3005CRP orders accept only refund COD values
3006COD is required for Cash Collection Orders
3007The COD amount should be less than or equal 30000 EGP
3008The Refund COD amount should be less than or equal 30000 EGP
3009city, zoneId, or districtId is required