Shipment Line

The shipment line resource.

Basehttps://rest.carbon.ms/shipmentLine
GET/shipmentLine

List shipment lines

Retrieve a paginated list of shipment lines. Filter, order, and select columns with PostgREST query parameters.

Query parameters

selectstring

Comma-separated columns to return. Defaults to all.

orderstring

Column to sort by, e.g. `createdAt.desc`.

limitinteger

Maximum rows to return.

offsetinteger

Rows to skip, for pagination.

GEThttps://rest.carbon.ms/shipmentLine
curl --request GET \
  --url 'https://rest.carbon.ms/shipmentLine?select=*&limit=10' \
  --header 'Authorization: Bearer <api-key>'
Response
[
  {
    "id": "abc123def456",
    "shipmentId": "xyz789",
    "itemId": "xyz789",
    "orderQuantity": 10,
    "outstandingQuantity": 10,
    "shippedQuantity": 10,
    "unitOfMeasure": "string",
    "unitPrice": 0
  }
]
GET/shipmentLine

Retrieve a shipment line

Fetch a single shipment line by filtering on `id`.

Query parameters

idstring

Match on the shipment line's `id`, e.g. `eq.{id}`.

GEThttps://rest.carbon.ms/shipmentLine
curl --request GET \
  --url 'https://rest.carbon.ms/shipmentLine?id=eq.%7Bid%7D' \
  --header 'Authorization: Bearer <api-key>'
Response
{
  "id": "abc123def456",
  "shipmentId": "xyz789",
  "itemId": "xyz789",
  "orderQuantity": 10,
  "outstandingQuantity": 10,
  "shippedQuantity": 10,
  "unitOfMeasure": "string",
  "unitPrice": 0
}
POST/shipmentLine

Create a shipment line

Create a new shipment line.

Body parameters

shipmentIdstringrequired

References shipment.id

lineIdstring
itemIdstringrequired

References item.id

orderQuantitynumberrequired
outstandingQuantitynumberrequired
shippedQuantitynumberrequired
locationIdstring

References location.id

storageUnitIdstring

References storageUnit.id

unitOfMeasurestringrequired
unitPricenumberrequired
requiresSerialTrackingbooleanrequired
requiresBatchTrackingbooleanrequired
companyIdstringrequired
fulfillmentIdstring

References fulfillment.id

POSThttps://rest.carbon.ms/shipmentLine
curl --request POST \
  --url https://rest.carbon.ms/shipmentLine \
  --header 'Authorization: Bearer <api-key>' \
  --header 'Content-Type: application/json' \
  --header 'Prefer: return=representation' \
  --data '{"shipmentId":"xyz789","itemId":"xyz789","orderQuantity":10,"outstandingQuantity":10,"shippedQuantity":10,"unitOfMeasure":"string","unitPrice":0,"requiresSerialTracking":true,"requiresBatchTracking":true,"companyId":"xyz789"}'
Response
{
  "id": "abc123def456",
  "shipmentId": "xyz789",
  "itemId": "xyz789",
  "orderQuantity": 10,
  "outstandingQuantity": 10,
  "shippedQuantity": 10,
  "unitOfMeasure": "string",
  "unitPrice": 0
}
PATCH/shipmentLine

Update a shipment line

Update an existing shipment line, matched on `id`.

Body parameters

shipmentIdstringrequired

References shipment.id

lineIdstring
itemIdstringrequired

References item.id

orderQuantitynumberrequired
outstandingQuantitynumberrequired
shippedQuantitynumberrequired
locationIdstring

References location.id

storageUnitIdstring

References storageUnit.id

unitOfMeasurestringrequired
unitPricenumberrequired
requiresSerialTrackingbooleanrequired
requiresBatchTrackingbooleanrequired
companyIdstringrequired
fulfillmentIdstring

References fulfillment.id

PATCHhttps://rest.carbon.ms/shipmentLine
curl --request PATCH \
  --url 'https://rest.carbon.ms/shipmentLine?id=eq.%7Bid%7D' \
  --header 'Authorization: Bearer <api-key>' \
  --header 'Content-Type: application/json' \
  --header 'Prefer: return=representation' \
  --data '{"shipmentId":"xyz789"}'
Response
{
  "id": "abc123def456",
  "shipmentId": "xyz789",
  "itemId": "xyz789",
  "orderQuantity": 10,
  "outstandingQuantity": 10,
  "shippedQuantity": 10,
  "unitOfMeasure": "string",
  "unitPrice": 0
}
DELETE/shipmentLine

Delete a shipment line

Delete a shipment line, matched on `id`. Returns 204 No Content.

Query parameters

idstring

The `id` of the shipment line to delete, e.g. `eq.{id}`.

DELETEhttps://rest.carbon.ms/shipmentLine
curl --request DELETE \
  --url 'https://rest.carbon.ms/shipmentLine?id=eq.%7Bid%7D' \
  --header 'Authorization: Bearer <api-key>'
204 No Content