Skip to main content
POST
/
orders
/
add-shipment
Add shipment to order
curl --request POST \
  --url https://store.salesive.com/api/v1/orders/add-shipment \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --header 'x-shop-id: <api-key>' \
  --data '
{
  "orderId": "<string>",
  "shippingAddressId": "<string>",
  "shippingOptionId": "<string>"
}
'
{
  "status": 123,
  "success": true,
  "message": "<string>",
  "data": {
    "_id": "<string>",
    "orderId": 123,
    "user": "<string>",
    "shop": "<string>",
    "items": [
      {
        "product": "<string>",
        "name": "<string>",
        "price": 123,
        "quantity": 2,
        "variant": "<string>",
        "sku": "<string>",
        "variantAttributes": {},
        "imageUrl": "<string>"
      }
    ],
    "status": "pending",
    "subtotal": 123,
    "shippingCost": 123,
    "total": 123,
    "shippingAddress": {
      "fullName": "<string>",
      "addressLine1": "<string>",
      "city": "<string>",
      "state": "<string>",
      "zipCode": "<string>",
      "country": "<string>",
      "phoneNumber": "<string>",
      "addressLine2": "<string>"
    },
    "payment": "<string>",
    "shipment": "<string>",
    "notes": "<string>",
    "createdAt": "2023-11-07T05:31:56Z",
    "updatedAt": "2023-11-07T05:31:56Z"
  }
}

Request

POST /orders/add-shipment
Authorization: Bearer {{token}}
x-shop-id: {{shopId}}
Content-Type: application/json

{
  "orderId": "690ff00acf4de460fd1f6114",
  "shippingAddressId": "68fc5211e908b620db5bfcdc",
  "shippingOptionId": "68fd6e0e27e0b21f55b403ce"
}

Headers

HeaderTypeDescription
AuthorizationstringProvide the customer token as Bearer <jwt>.
x-shop-idstringIdentify the shop that owns the order.
Content-TypestringAlways set to application/json.

Body parameters

FieldTypeRequiredDescription
orderIdstringYesThe order ID to associate with the shipment.
shippingAddressIdstringYesThe shipping address ID to use for delivery.
shippingOptionIdstringYesThe shipping option/carrier to use.

Successful response

{
  "status": 200,
  "success": true,
  "message": "Shipment added to order successfully",
  "data": {
    "_id": "690ff00acf4de460fd1f6114",
    "orderId": 1001,
    "user": "68f976e92bb0b821425fdda6",
    "shop": "68b8f52575da81b332af29f1",
    "items": [
      {
        "product": "68e5bb463a1fc56a8ac150bf",
        "name": "Head phone",
        "price": 10000,
        "quantity": 2
      }
    ],
    "status": "processing",
    "subtotal": 20000,
    "shippingCost": 500,
    "total": 20500,
    "shippingAddress": {
      "fullName": "John Doe",
      "addressLine1": "123 Main St",
      "city": "New York",
      "state": "NY",
      "zipCode": "10001",
      "country": "USA",
      "phoneNumber": "+1234567890"
    },
    "shipment": "68fd6e1027e0b21f55b403cf",
    "createdAt": "2025-11-14T15:30:00.000Z",
    "updatedAt": "2025-11-14T15:35:00.000Z"
  }
}

Error response

{
  "status": 404,
  "success": false,
  "message": "Order not found",
  "data": {}
}

Authorizations

Authorization
string
header
required

JWT issued by the Salesive Store API for authenticated shoppers.

x-shop-id
string
header
required

Optional storefront identifier sent as a header to scope responses to a specific shop. Try It requests remember this value once provided.

Headers

x-shop-id
string

Optional identifier that scopes responses to a specific storefront when the referer cannot be inferred.

Body

application/json
orderId
string
required

The order ID to associate with the shipment.

shippingAddressId
string
required

The shipping address ID to use for delivery.

shippingOptionId
string
required

The shipping option/carrier to use.

Response

Shipment added to order successfully.

status
integer
required
success
boolean
required
message
string
required
data
object
required