Submit a shipment to carrier
curl --request POST \
--url https://clarus-api.com/api/shipments/{id}/submit \
--header 'Authorization: Bearer <token>' \
--header 'X-Clarus-Subdomain: <api-key>'import requests
url = "https://clarus-api.com/api/shipments/{id}/submit"
headers = {
"Authorization": "Bearer <token>",
"X-Clarus-Subdomain": "<api-key>"
}
response = requests.post(url, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'X-Clarus-Subdomain': '<api-key>'}
};
fetch('https://clarus-api.com/api/shipments/{id}/submit', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"data": {
"id": 123,
"type": "<string>",
"attributes": {}
}
}{
"error": "<string>"
}{
"errors": [
{
"code": 123,
"symbol": "<string>",
"details": "<string>",
"source": "<string>",
"context": {}
}
]
}{
"errors": [
{
"code": 123,
"symbol": "<string>",
"details": "<string>",
"source": "<string>",
"context": {}
}
]
}Shipments
Submit a shipment to carrier
Submit a shipment to the carrier integration for label generation and tracking number assignment.
POST
/
api
/
shipments
/
{id}
/
submit
Submit a shipment to carrier
curl --request POST \
--url https://clarus-api.com/api/shipments/{id}/submit \
--header 'Authorization: Bearer <token>' \
--header 'X-Clarus-Subdomain: <api-key>'import requests
url = "https://clarus-api.com/api/shipments/{id}/submit"
headers = {
"Authorization": "Bearer <token>",
"X-Clarus-Subdomain": "<api-key>"
}
response = requests.post(url, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'X-Clarus-Subdomain': '<api-key>'}
};
fetch('https://clarus-api.com/api/shipments/{id}/submit', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"data": {
"id": 123,
"type": "<string>",
"attributes": {}
}
}{
"error": "<string>"
}{
"errors": [
{
"code": 123,
"symbol": "<string>",
"details": "<string>",
"source": "<string>",
"context": {}
}
]
}{
"errors": [
{
"code": 123,
"symbol": "<string>",
"details": "<string>",
"source": "<string>",
"context": {}
}
]
}Behavior
- Submits shipment to configured carrier API
- Generates shipping label and tracking number
- Returns updated shipment with carrier response
Prerequisites
- Shipment must have carrier_id assigned
- Carrier integration must be configured
- Packages must have valid dimensions
Authorizations
OAuth 2.0 authentication. Use the client credentials or authorization code flow to obtain an access token.
FlowAuthorization Code
- Authorization URL
- https://clarus-api.com/oauth/authorize
- Token URL
- https://clarus-api.com/oauth/token
FlowClient Credentials
- Token URL
- https://clarus-api.com/oauth/token
The subdomain/tenant name identifying which tenant's data to access. Required for all API requests.
Path Parameters
The unique identifier of the shipment to submit
Response
Shipment submitted successfully
Standard successful response wrapper following JSON:API format
The response payload
Show child attributes
Show child attributes

