Skip to main content
POST
/
orders
/
{id}
/
shipping
/
calculate
Calculate Shipping
curl --request POST \
  --url https://api.bitbybit.studio/customer/api/open/v1/orders/{id}/shipping/calculate \
  --header 'Content-Type: application/json' \
  --header 'x-api-key: <api-key>' \
  --data '
{
  "packageWeight": 123,
  "packageLength": 123,
  "packageWidth": 123,
  "packageHeight": 123,
  "itemValue": 1,
  "senderLatitude": 123,
  "senderLongitude": 123
}
'
{
  "data": {
    "fee": 123
  }
}

Authorizations

x-api-key
string
header
required

API key for authentication. Create one in Settings > Developer.

Path Parameters

id
string
required

Order ID — the unique identifier of the order.

Body

application/json
courier
enum<string>
required

Courier to calculate shipping for. The corresponding integration must be connected for the company.

Available options:
ride_blitz,
gosend,
kirimin_aja
packageWeight
number
required

Package weight in kilograms.

packageLength
number
packageWidth
number
packageHeight
number
itemValue
number
Required range: x >= 0
serviceType
enum<string>

Service tier. Required by some couriers (e.g. KiriminAja).

Available options:
INSTANT,
EXPRESS
senderLatitude
number

Pickup latitude. Required for RideBlitz and GoSend.

senderLongitude
number

Pickup longitude. Required for RideBlitz and GoSend.

Response

Calculation result

data
object

Shape varies by courier; the courier field identifies the source and fee (when present) is the final shipping fee in the order currency.