Docly Child

Add Shipments via API

Create a shipment tracker for Cloud

URL

https://api.trackship.com/v1/shipment/create/

Header Parameter:

trackship-api-key : <your api key here>
app-name          : <your app name here>

CURL POST request:

curl --location 'https://api.trackship.com/v1/shipment/create/' \
--header 'trackship-api-key: <your api key here>' \
--header 'app-name: <your app name here>' \
--header 'Content-Type: application/json' \
--data-raw '{
    "tracking_number": "D84555920",
    "tracking_provider": "dtdc",
    "order_id": "025",
    "postal_code": 123456
    "destination_country": "US",
    "customer_name": "John",
    "customer_email": "[email protected],[email protected]",
    "customer_phone": "5522552255",
    "shipping_address_1": "13 Main Street",
    "shipping_address_2": "Apt 101",
    "shipping_city": "Anytown",
    "shipping_state": "Example State",
    "shipment_items": [
        {
            "name": "Men T-shirt"
            "qty": "1",
            "image_url": "https://placeholder.com/images/product-1.jpg",
            "product_url": "https://placeholder.com/product/product-1/"
        },
        {
            "name": "Men Pents"
            "qty": "2",
            "image_url": "https://placeholder.com/images/product-2.jpg",
            "product_url": "https://placeholder.com/product/product-2/"
        }
    ]
}'

Request Parameters:

ParameterTypeDescription
tracking_number(required)StringTracking number for the package
tracking_provider(required)StringUnique code of tracking provider for that tracking
order_id(required)StringRespective order ID
shipping_postcodeStringThe postal code of the receiver’s address. It is required for some couriers, like postnl-3s
destination_countryStringDestination country for receiver’s address. It is required for some couriers, like postnl-3s(ex: NL)
customer_nameStringThe name of the customer.
customer_emailStringThe email address of the customer and you can now add another email address as a CC (carbon copy) in this field by comma separate.
customer_phoneStringThe phone number of the customer.
shipping_address_1StringThe first line of the shipping address.
shipping_address_2StringThe second line of the shipping address.
shipping_cityStringThe city of the shipping address.
shipping_stateStringThe state or region of the shipping address.
shipping_countryStringThe country code of the shipping address.
shipment_itemsarray of objectsAn array of objects representing the items in the shipment. Each object should contain a name attribute specifying the name of the item.

Response Body:

{
    "status": "ok",
    "status_msg": "pending_trackship",
    "trackers_balance": "98",
    "user_plan": "Mini"
}

Response Parameters:

ParameterTypeDescription
statusStringresponse status(ex: ok/error)
status_msgStringstatus msg which explains the status of shipment(pending_trackship/ssl_error/Order id not found)
trackers_balanceStringThe available balance of the TrackShip account
user_planStringActive Subscription plan of TrackShip Account(ex: Free 50/Mini/Small)
CONTENTS