Our API provides the checkOTODeliveryFee endpoint, allowing users to retrieve available delivery options, pricing, and estimated costs based on shipment details. This guide explains how to check delivery fees before creating a shipment.
Instructions
Step 1: API Endpoint
- To check OTO delivery fees, use the following POST endpoint:
https://api.tryoto.com/rest/v2/checkOTODeliveryFee
Step 2: Authorization
- A valid Bearer Token must be included in the request headers for authentication
Step 3: Request Body Parameters
- The request body should be in JSON format. The price is based on the greater of the actual weight and the volumetric weight of the package, so send the larger of the two.
| Name | Required | Type | Description |
|---|---|---|---|
| originCity | yes | string | pickup city |
| destinationCity | yes | string | destination city |
| originLat | no | number | Origin latitude, required for bullet type |
| originLon | no | number | Origin longitude, required for bullet type |
| destinationLat | no | number | Destination latitude, required for bullet type |
| destinationLon | no | number | Destination longitude, required for bullet type |
| weight* | yes | number | approximate weight of package(kg) |
| forReverseShipment | no | boolean | When true, lists the delivery companies you can create reverse shipments with. |
| currency | no | string | ISO 4217 code, "SAR","KWD", etc. |
| packageCount | no | number | 1 |
| totalDue | no | number | cash on delivery amount |
| length | no | number | length of the package(cm) |
| width | no | number | width of the package(cm) |
| height | no | number | height of the package(cm) |
| serviceType | no | string | express,sameDay, fastDelivery, coldDelivery,heavyAndBulky, electronicAndHeavy |
| deliveryType | no | enum | toCustomerDoorstep, pickupByCustomer, toCustomerDoorstepOrPickupByCustomer |
| includeEstimatedDates | no | boolean | When true, the response includes estimated pickup and delivery dates from OTO's AI prediction model. |
Step 4: Example Request
Using cURL:
curl --location 'https://api.tryoto.com/rest/v2/checkOTODeliveryFee' \ --header 'Authorization: Bearer {{token}}' \ --data '{ "weight":"3", "originCity":"Riyadh", "destinationCity":"Jeddah", "height":30, "width":30, "length":30 }'
Step 5: Example Response
- A successful response will return the available delivery options, pricing, and estimated costs:
{ "traceId": "2e648363-2e85-49b3-9eea-75c9d10c09d0", "success": true, "deliveryCompany": [ { "serviceType": "express", "deliveryOptionName": "Kwick Box", "trackingType": "excellent", "codCharge": 10, "pickupCutOffTime": "17:00", "maxOrderValue": 3750, "insurancePolicy": "Up To 3500 SAR", "maxCODValue": 3750, "deliveryOptionId": 345, "extraWeightPerKg": 1, "deliveryCompanyName": "kwickbox", "returnFee": 13, "maxFreeWeight": 25, "avgDeliveryTime": "1 to 2 Working Days", "price": 13, "logo": "https://storage.googleapis.com/tryoto-public/delivery-logo/kwickbox.png", "pickupDropoff": "freePickup" }, { "serviceType": "pudo", "deliveryOptionName": "SPL - PUDO", "trackingType": "excellent", "codCharge": 8, "pickupCutOffTime": "12:00", "maxOrderValue": 10000, "insurancePolicy": "Up To 5000.00 SAR", "maxCODValue": 5000, "deliveryOptionId": 2748, "extraWeightPerKg": 1, "deliveryCompanyName": "saudiPost", "returnFee": 14, "maxFreeWeight": 15, "avgDeliveryTime": "1 to 5 Working Days", "price": 14, "logo": "https://storage.googleapis.com/tryoto-public/delivery-logo/spl.jpg", "pickupDropoff": "dropoffOnly" }, { "serviceType": "express", "deliveryOptionName": "Thabit Logistics", "trackingType": "excellent", "codCharge": 6, "pickupCutOffTime": "17:00", "maxOrderValue": 3750, "insurancePolicy": "Up To 5000 SAR", "maxCODValue": 3750, "deliveryOptionId": 645, "extraWeightPerKg": 1, "deliveryCompanyName": "thabit", "returnFee": 19, "maxFreeWeight": 10, "avgDeliveryTime": "1 to 2 Working Days", "price": 19, "logo": "https://storage.googleapis.com/tryoto-public/delivery-logo/thabit.png", "pickupDropoff": "freePickup" }, { "serviceType": "express", "deliveryOptionName": "Safe Arrival", "trackingType": "excellent", "codCharge": 3, "pickupCutOffTime": "16:00", "maxOrderValue": 3000, "insurancePolicy": "Up To 500 SAR", "maxCODValue": 3000, "deliveryOptionId": 3213, "extraWeightPerKg": 1, "deliveryCompanyName": "safearrival", "returnFee": 19, "maxFreeWeight": 10, "avgDeliveryTime": "1 to 2 Working Days", "price": 19, "logo": "https://storage.googleapis.com/tryoto-public/delivery-logo/safearrival.png", "pickupDropoff": "freePickup" }, { "serviceType": "express", "deliveryOptionName": "Aymakan", "trackingType": "excellent", "codCharge": 6, "pickupCutOffTime": "15:00", "maxOrderValue": 5000, "insurancePolicy": "Up To 375 SAR", "maxCODValue": 3000, "deliveryOptionId": 994, "extraWeightPerKg": 2, "deliveryCompanyName": "aymakan", "returnFee": 19, "maxFreeWeight": 10, "avgDeliveryTime": "1 to 3 Working Days", "price": 19, "logo": "https://storage.googleapis.com/tryoto-public/delivery-logo/aymakan.png", "pickupDropoff": "freePickup" }, { "serviceType": "express", "deliveryOptionName": "DELIVERIST ", "trackingType": "excellent", "codCharge": 3, "pickupCutOffTime": "13:00", "maxOrderValue": 3500, "insurancePolicy": "Up To 500 SAR", "maxCODValue": 3500, "deliveryOptionId": 4175, "extraWeightPerKg": 1, "deliveryCompanyName": "deliveristLogestechs", "returnFee": 19, "maxFreeWeight": 10, "avgDeliveryTime": "1 to 3 Working Days", "price": 19, "logo": "https://storage.googleapis.com/tryoto-public/delivery-logo/deliverist.png", "pickupDropoff": "freePickup" }, { "serviceType": "express", "deliveryOptionName": "Shipa Delivery", "trackingType": "excellent", "codCharge": 3, "pickupCutOffTime": "14:00", "maxOrderValue": 3750, "insurancePolicy": "Up To 100 SAR", "maxCODValue": 3750, "deliveryOptionId": 346, "extraWeightPerKg": 1, "deliveryCompanyName": "shipaV2", "returnFee": 20, "maxFreeWeight": 10, "avgDeliveryTime": "1 to 3 Working Days", "price": 20, "logo": "https://storage.googleapis.com/tryoto-public/delivery-logo/shipa.png", "pickupDropoff": "freePickup" }, { "serviceType": "express", "deliveryOptionName": "Aramex", "trackingType": "excellent", "codCharge": 6, "pickupCutOffTime": "18:00", "maxOrderValue": 10000, "insurancePolicy": "Up To 1000 SAR", "maxCODValue": 5000, "deliveryOptionId": 332, "extraWeightPerKg": 1, "deliveryCompanyName": "aramex", "returnFee": 21, "maxFreeWeight": 10, "avgDeliveryTime": "1 to 2 Working Days", "price": 21, "logo": "https://storage.googleapis.com/tryoto-public/delivery-logo/aramex.png", "pickupDropoff": "freePickupDropoff" }, { "serviceType": "express", "deliveryOptionName": "J&T Express", "trackingType": "excellent", "codCharge": 8, "pickupCutOffTime": "12:00", "maxOrderValue": 6000, "insurancePolicy": "Up To 400 SAR", "maxCODValue": 3000, "deliveryOptionId": 711, "extraWeightPerKg": 1, "deliveryCompanyName": "jtexpress", "returnFee": 21, "maxFreeWeight": 5, "avgDeliveryTime": "1 to 2 Working Days", "price": 21, "logo": "https://storage.googleapis.com/tryoto-public/delivery-logo/jandt.png", "pickupDropoff": "freePickupDropoff" }, { "serviceType": "express", "deliveryOptionName": "UPS", "trackingType": "excellent", "codCharge": 8, "pickupCutOffTime": "15:00", "maxOrderValue": 5000, "insurancePolicy": "Up To 375 SAR", "maxCODValue": 2000, "deliveryOptionId": 1305, "extraWeightPerKg": 1, "deliveryCompanyName": "ups", "returnFee": 22, "maxFreeWeight": 15, "avgDeliveryTime": "1 to 5 Working Days", "price": 22, "logo": "https://storage.googleapis.com/tryoto-public/delivery-logo/ups.png", "pickupDropoff": "freePickup" }, { "serviceType": "express", "deliveryOptionName": "SMSA", "trackingType": "excellent", "codCharge": 8, "pickupCutOffTime": "12:00", "maxOrderValue": 6000, "insurancePolicy": "Up To 100 SAR", "maxCODValue": 3750, "deliveryOptionId": 979, "extraWeightPerKg": 1, "deliveryCompanyName": "secom", "returnFee": 24, "maxFreeWeight": 15, "avgDeliveryTime": "1 to 5 Working Days", "price": 24, "logo": "https://storage.googleapis.com/tryoto-public/delivery-logo/smsav2.png", "pickupDropoff": "dropoffOnly" }, { "serviceType": "heavyAndBulky", "deliveryOptionName": "Flow PL", "trackingType": "excellent", "codCharge": 0, "pickupCutOffTime": "09:00", "maxOrderValue": 20000, "insurancePolicy": "Up To 500 SAR", "maxCODValue": 0, "deliveryOptionId": 2567, "extraWeightPerKg": 1, "deliveryCompanyName": "flowpl", "returnFee": 44, "maxFreeWeight": 30, "avgDeliveryTime": "1 to 5 Working Days", "price": 44, "logo": "https://storage.googleapis.com/tryoto-public/delivery-logo/flow.png", "pickupDropoff": "freePickup" }, { "serviceType": "express", "deliveryOptionName": "DHL Express MyDHL", "trackingType": "excellent", "codCharge": 8, "pickupCutOffTime": "17:00", "maxOrderValue": 3750, "insurancePolicy": "Up To 100 SAR", "maxCODValue": 1, "deliveryOptionId": 1593, "extraWeightPerKg": 10, "deliveryCompanyName": "mydhl", "returnFee": 69, "maxFreeWeight": 5, "avgDeliveryTime": "1 to 5 Working Days", "price": 69, "logo": "https://storage.googleapis.com/tryoto-public/delivery-logo/dhl-express.png", "pickupDropoff": "freePickupDropoff" } ] }
