curl --request POST \
--url https://app.smartsend.io/api/v2/team/{team}/booking-batches/{batch}/shipments \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"data": [
{
"currency": "EUR",
"weight_unit": "g",
"dimension_unit": "cm",
"invoice_number": "INV-1001121",
"reference": "Order-5521",
"identifier": "<string>",
"uri": "<string>",
"delivery": {
"addons": [
{
"code": "SIGNATURE"
}
],
"carrier": "postnord",
"service": "postnord_agent",
"incoterm": "DAP"
},
"parties": {
"receiver": {
"reference": "<string>",
"identifier": "<string>",
"uri": "<string>",
"address": {
"address_lines": [
"3200 Whitehaven St. NW",
"Building A, Floor 2"
],
"postal_code": "20008",
"city": "Washington",
"country": "US",
"administrative_area": "DC"
},
"contact": {
"name_lines": [
"John Doe",
"Att. Finance department"
],
"company": "Acme Corp",
"email": "john@example.com",
"phone": "+4512345678"
},
"identifiers": {
"vat": "DK12345678",
"eori": "DK1234567890123",
"gb_eori": "GB123456789000",
"tax_id": "DK1234567890",
"voec": "2000123"
}
},
"pickup": {
"service_point_code": "12345",
"reference": "<string>",
"identifier": "<string>",
"uri": "<string>"
}
},
"parcels": [
{
"reference": "<string>",
"identifier": "<string>",
"tracking_url": "https://track.smartsend.io/00340434161094015749",
"freetext": "Gift wrapped as per requested",
"gross_weight": 1500,
"length": 30,
"width": 20,
"height": 15,
"total_net_amount": 15920,
"tax_amount": 3980,
"duty_amount": 5572,
"items": [
{
"reference": "<string>",
"identifier": "<string>",
"uri": "<string>",
"image_url": "https://www.example.com/products/1234-image1.jpeg",
"sku": "PROD-001",
"location": "AA-01-B45-C",
"name": "Widget",
"description": "<string>",
"tariff_code": "8471300000",
"country_of_origin": "CN",
"quantity": 2,
"total_net_amount": 15920,
"tax_amount": 3980,
"duty_amount": 5572,
"net_weight": 550,
"cost_amount": 5300
}
]
}
],
"total_net_amount": 15920,
"tax_amount": 3980,
"duty_amount": 5572,
"shipping_net_amount": 3920,
"shipping_tax_amount": 980
}
]
}
'import requests
url = "https://app.smartsend.io/api/v2/team/{team}/booking-batches/{batch}/shipments"
payload = { "data": [
{
"currency": "EUR",
"weight_unit": "g",
"dimension_unit": "cm",
"invoice_number": "INV-1001121",
"reference": "Order-5521",
"identifier": "<string>",
"uri": "<string>",
"delivery": {
"addons": [{ "code": "SIGNATURE" }],
"carrier": "postnord",
"service": "postnord_agent",
"incoterm": "DAP"
},
"parties": {
"receiver": {
"reference": "<string>",
"identifier": "<string>",
"uri": "<string>",
"address": {
"address_lines": ["3200 Whitehaven St. NW", "Building A, Floor 2"],
"postal_code": "20008",
"city": "Washington",
"country": "US",
"administrative_area": "DC"
},
"contact": {
"name_lines": ["John Doe", "Att. Finance department"],
"company": "Acme Corp",
"email": "john@example.com",
"phone": "+4512345678"
},
"identifiers": {
"vat": "DK12345678",
"eori": "DK1234567890123",
"gb_eori": "GB123456789000",
"tax_id": "DK1234567890",
"voec": "2000123"
}
},
"pickup": {
"service_point_code": "12345",
"reference": "<string>",
"identifier": "<string>",
"uri": "<string>"
}
},
"parcels": [
{
"reference": "<string>",
"identifier": "<string>",
"tracking_url": "https://track.smartsend.io/00340434161094015749",
"freetext": "Gift wrapped as per requested",
"gross_weight": 1500,
"length": 30,
"width": 20,
"height": 15,
"total_net_amount": 15920,
"tax_amount": 3980,
"duty_amount": 5572,
"items": [
{
"reference": "<string>",
"identifier": "<string>",
"uri": "<string>",
"image_url": "https://www.example.com/products/1234-image1.jpeg",
"sku": "PROD-001",
"location": "AA-01-B45-C",
"name": "Widget",
"description": "<string>",
"tariff_code": "8471300000",
"country_of_origin": "CN",
"quantity": 2,
"total_net_amount": 15920,
"tax_amount": 3980,
"duty_amount": 5572,
"net_weight": 550,
"cost_amount": 5300
}
]
}
],
"total_net_amount": 15920,
"tax_amount": 3980,
"duty_amount": 5572,
"shipping_net_amount": 3920,
"shipping_tax_amount": 980
}
] }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
data: [
{
currency: 'EUR',
weight_unit: 'g',
dimension_unit: 'cm',
invoice_number: 'INV-1001121',
reference: 'Order-5521',
identifier: '<string>',
uri: '<string>',
delivery: {
addons: [{code: 'SIGNATURE'}],
carrier: 'postnord',
service: 'postnord_agent',
incoterm: 'DAP'
},
parties: {
receiver: {
reference: '<string>',
identifier: '<string>',
uri: '<string>',
address: {
address_lines: ['3200 Whitehaven St. NW', 'Building A, Floor 2'],
postal_code: '20008',
city: 'Washington',
country: 'US',
administrative_area: 'DC'
},
contact: {
name_lines: ['John Doe', 'Att. Finance department'],
company: 'Acme Corp',
email: 'john@example.com',
phone: '+4512345678'
},
identifiers: {
vat: 'DK12345678',
eori: 'DK1234567890123',
gb_eori: 'GB123456789000',
tax_id: 'DK1234567890',
voec: '2000123'
}
},
pickup: {
service_point_code: '12345',
reference: '<string>',
identifier: '<string>',
uri: '<string>'
}
},
parcels: [
{
reference: '<string>',
identifier: '<string>',
tracking_url: 'https://track.smartsend.io/00340434161094015749',
freetext: 'Gift wrapped as per requested',
gross_weight: 1500,
length: 30,
width: 20,
height: 15,
total_net_amount: 15920,
tax_amount: 3980,
duty_amount: 5572,
items: [
{
reference: '<string>',
identifier: '<string>',
uri: '<string>',
image_url: 'https://www.example.com/products/1234-image1.jpeg',
sku: 'PROD-001',
location: 'AA-01-B45-C',
name: 'Widget',
description: '<string>',
tariff_code: '8471300000',
country_of_origin: 'CN',
quantity: 2,
total_net_amount: 15920,
tax_amount: 3980,
duty_amount: 5572,
net_weight: 550,
cost_amount: 5300
}
]
}
],
total_net_amount: 15920,
tax_amount: 3980,
duty_amount: 5572,
shipping_net_amount: 3920,
shipping_tax_amount: 980
}
]
})
};
fetch('https://app.smartsend.io/api/v2/team/{team}/booking-batches/{batch}/shipments', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://app.smartsend.io/api/v2/team/{team}/booking-batches/{batch}/shipments",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'data' => [
[
'currency' => 'EUR',
'weight_unit' => 'g',
'dimension_unit' => 'cm',
'invoice_number' => 'INV-1001121',
'reference' => 'Order-5521',
'identifier' => '<string>',
'uri' => '<string>',
'delivery' => [
'addons' => [
[
'code' => 'SIGNATURE'
]
],
'carrier' => 'postnord',
'service' => 'postnord_agent',
'incoterm' => 'DAP'
],
'parties' => [
'receiver' => [
'reference' => '<string>',
'identifier' => '<string>',
'uri' => '<string>',
'address' => [
'address_lines' => [
'3200 Whitehaven St. NW',
'Building A, Floor 2'
],
'postal_code' => '20008',
'city' => 'Washington',
'country' => 'US',
'administrative_area' => 'DC'
],
'contact' => [
'name_lines' => [
'John Doe',
'Att. Finance department'
],
'company' => 'Acme Corp',
'email' => 'john@example.com',
'phone' => '+4512345678'
],
'identifiers' => [
'vat' => 'DK12345678',
'eori' => 'DK1234567890123',
'gb_eori' => 'GB123456789000',
'tax_id' => 'DK1234567890',
'voec' => '2000123'
]
],
'pickup' => [
'service_point_code' => '12345',
'reference' => '<string>',
'identifier' => '<string>',
'uri' => '<string>'
]
],
'parcels' => [
[
'reference' => '<string>',
'identifier' => '<string>',
'tracking_url' => 'https://track.smartsend.io/00340434161094015749',
'freetext' => 'Gift wrapped as per requested',
'gross_weight' => 1500,
'length' => 30,
'width' => 20,
'height' => 15,
'total_net_amount' => 15920,
'tax_amount' => 3980,
'duty_amount' => 5572,
'items' => [
[
'reference' => '<string>',
'identifier' => '<string>',
'uri' => '<string>',
'image_url' => 'https://www.example.com/products/1234-image1.jpeg',
'sku' => 'PROD-001',
'location' => 'AA-01-B45-C',
'name' => 'Widget',
'description' => '<string>',
'tariff_code' => '8471300000',
'country_of_origin' => 'CN',
'quantity' => 2,
'total_net_amount' => 15920,
'tax_amount' => 3980,
'duty_amount' => 5572,
'net_weight' => 550,
'cost_amount' => 5300
]
]
]
],
'total_net_amount' => 15920,
'tax_amount' => 3980,
'duty_amount' => 5572,
'shipping_net_amount' => 3920,
'shipping_tax_amount' => 980
]
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://app.smartsend.io/api/v2/team/{team}/booking-batches/{batch}/shipments"
payload := strings.NewReader("{\n \"data\": [\n {\n \"currency\": \"EUR\",\n \"weight_unit\": \"g\",\n \"dimension_unit\": \"cm\",\n \"invoice_number\": \"INV-1001121\",\n \"reference\": \"Order-5521\",\n \"identifier\": \"<string>\",\n \"uri\": \"<string>\",\n \"delivery\": {\n \"addons\": [\n {\n \"code\": \"SIGNATURE\"\n }\n ],\n \"carrier\": \"postnord\",\n \"service\": \"postnord_agent\",\n \"incoterm\": \"DAP\"\n },\n \"parties\": {\n \"receiver\": {\n \"reference\": \"<string>\",\n \"identifier\": \"<string>\",\n \"uri\": \"<string>\",\n \"address\": {\n \"address_lines\": [\n \"3200 Whitehaven St. NW\",\n \"Building A, Floor 2\"\n ],\n \"postal_code\": \"20008\",\n \"city\": \"Washington\",\n \"country\": \"US\",\n \"administrative_area\": \"DC\"\n },\n \"contact\": {\n \"name_lines\": [\n \"John Doe\",\n \"Att. Finance department\"\n ],\n \"company\": \"Acme Corp\",\n \"email\": \"john@example.com\",\n \"phone\": \"+4512345678\"\n },\n \"identifiers\": {\n \"vat\": \"DK12345678\",\n \"eori\": \"DK1234567890123\",\n \"gb_eori\": \"GB123456789000\",\n \"tax_id\": \"DK1234567890\",\n \"voec\": \"2000123\"\n }\n },\n \"pickup\": {\n \"service_point_code\": \"12345\",\n \"reference\": \"<string>\",\n \"identifier\": \"<string>\",\n \"uri\": \"<string>\"\n }\n },\n \"parcels\": [\n {\n \"reference\": \"<string>\",\n \"identifier\": \"<string>\",\n \"tracking_url\": \"https://track.smartsend.io/00340434161094015749\",\n \"freetext\": \"Gift wrapped as per requested\",\n \"gross_weight\": 1500,\n \"length\": 30,\n \"width\": 20,\n \"height\": 15,\n \"total_net_amount\": 15920,\n \"tax_amount\": 3980,\n \"duty_amount\": 5572,\n \"items\": [\n {\n \"reference\": \"<string>\",\n \"identifier\": \"<string>\",\n \"uri\": \"<string>\",\n \"image_url\": \"https://www.example.com/products/1234-image1.jpeg\",\n \"sku\": \"PROD-001\",\n \"location\": \"AA-01-B45-C\",\n \"name\": \"Widget\",\n \"description\": \"<string>\",\n \"tariff_code\": \"8471300000\",\n \"country_of_origin\": \"CN\",\n \"quantity\": 2,\n \"total_net_amount\": 15920,\n \"tax_amount\": 3980,\n \"duty_amount\": 5572,\n \"net_weight\": 550,\n \"cost_amount\": 5300\n }\n ]\n }\n ],\n \"total_net_amount\": 15920,\n \"tax_amount\": 3980,\n \"duty_amount\": 5572,\n \"shipping_net_amount\": 3920,\n \"shipping_tax_amount\": 980\n }\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://app.smartsend.io/api/v2/team/{team}/booking-batches/{batch}/shipments")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"data\": [\n {\n \"currency\": \"EUR\",\n \"weight_unit\": \"g\",\n \"dimension_unit\": \"cm\",\n \"invoice_number\": \"INV-1001121\",\n \"reference\": \"Order-5521\",\n \"identifier\": \"<string>\",\n \"uri\": \"<string>\",\n \"delivery\": {\n \"addons\": [\n {\n \"code\": \"SIGNATURE\"\n }\n ],\n \"carrier\": \"postnord\",\n \"service\": \"postnord_agent\",\n \"incoterm\": \"DAP\"\n },\n \"parties\": {\n \"receiver\": {\n \"reference\": \"<string>\",\n \"identifier\": \"<string>\",\n \"uri\": \"<string>\",\n \"address\": {\n \"address_lines\": [\n \"3200 Whitehaven St. NW\",\n \"Building A, Floor 2\"\n ],\n \"postal_code\": \"20008\",\n \"city\": \"Washington\",\n \"country\": \"US\",\n \"administrative_area\": \"DC\"\n },\n \"contact\": {\n \"name_lines\": [\n \"John Doe\",\n \"Att. Finance department\"\n ],\n \"company\": \"Acme Corp\",\n \"email\": \"john@example.com\",\n \"phone\": \"+4512345678\"\n },\n \"identifiers\": {\n \"vat\": \"DK12345678\",\n \"eori\": \"DK1234567890123\",\n \"gb_eori\": \"GB123456789000\",\n \"tax_id\": \"DK1234567890\",\n \"voec\": \"2000123\"\n }\n },\n \"pickup\": {\n \"service_point_code\": \"12345\",\n \"reference\": \"<string>\",\n \"identifier\": \"<string>\",\n \"uri\": \"<string>\"\n }\n },\n \"parcels\": [\n {\n \"reference\": \"<string>\",\n \"identifier\": \"<string>\",\n \"tracking_url\": \"https://track.smartsend.io/00340434161094015749\",\n \"freetext\": \"Gift wrapped as per requested\",\n \"gross_weight\": 1500,\n \"length\": 30,\n \"width\": 20,\n \"height\": 15,\n \"total_net_amount\": 15920,\n \"tax_amount\": 3980,\n \"duty_amount\": 5572,\n \"items\": [\n {\n \"reference\": \"<string>\",\n \"identifier\": \"<string>\",\n \"uri\": \"<string>\",\n \"image_url\": \"https://www.example.com/products/1234-image1.jpeg\",\n \"sku\": \"PROD-001\",\n \"location\": \"AA-01-B45-C\",\n \"name\": \"Widget\",\n \"description\": \"<string>\",\n \"tariff_code\": \"8471300000\",\n \"country_of_origin\": \"CN\",\n \"quantity\": 2,\n \"total_net_amount\": 15920,\n \"tax_amount\": 3980,\n \"duty_amount\": 5572,\n \"net_weight\": 550,\n \"cost_amount\": 5300\n }\n ]\n }\n ],\n \"total_net_amount\": 15920,\n \"tax_amount\": 3980,\n \"duty_amount\": 5572,\n \"shipping_net_amount\": 3920,\n \"shipping_tax_amount\": 980\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.smartsend.io/api/v2/team/{team}/booking-batches/{batch}/shipments")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"data\": [\n {\n \"currency\": \"EUR\",\n \"weight_unit\": \"g\",\n \"dimension_unit\": \"cm\",\n \"invoice_number\": \"INV-1001121\",\n \"reference\": \"Order-5521\",\n \"identifier\": \"<string>\",\n \"uri\": \"<string>\",\n \"delivery\": {\n \"addons\": [\n {\n \"code\": \"SIGNATURE\"\n }\n ],\n \"carrier\": \"postnord\",\n \"service\": \"postnord_agent\",\n \"incoterm\": \"DAP\"\n },\n \"parties\": {\n \"receiver\": {\n \"reference\": \"<string>\",\n \"identifier\": \"<string>\",\n \"uri\": \"<string>\",\n \"address\": {\n \"address_lines\": [\n \"3200 Whitehaven St. NW\",\n \"Building A, Floor 2\"\n ],\n \"postal_code\": \"20008\",\n \"city\": \"Washington\",\n \"country\": \"US\",\n \"administrative_area\": \"DC\"\n },\n \"contact\": {\n \"name_lines\": [\n \"John Doe\",\n \"Att. Finance department\"\n ],\n \"company\": \"Acme Corp\",\n \"email\": \"john@example.com\",\n \"phone\": \"+4512345678\"\n },\n \"identifiers\": {\n \"vat\": \"DK12345678\",\n \"eori\": \"DK1234567890123\",\n \"gb_eori\": \"GB123456789000\",\n \"tax_id\": \"DK1234567890\",\n \"voec\": \"2000123\"\n }\n },\n \"pickup\": {\n \"service_point_code\": \"12345\",\n \"reference\": \"<string>\",\n \"identifier\": \"<string>\",\n \"uri\": \"<string>\"\n }\n },\n \"parcels\": [\n {\n \"reference\": \"<string>\",\n \"identifier\": \"<string>\",\n \"tracking_url\": \"https://track.smartsend.io/00340434161094015749\",\n \"freetext\": \"Gift wrapped as per requested\",\n \"gross_weight\": 1500,\n \"length\": 30,\n \"width\": 20,\n \"height\": 15,\n \"total_net_amount\": 15920,\n \"tax_amount\": 3980,\n \"duty_amount\": 5572,\n \"items\": [\n {\n \"reference\": \"<string>\",\n \"identifier\": \"<string>\",\n \"uri\": \"<string>\",\n \"image_url\": \"https://www.example.com/products/1234-image1.jpeg\",\n \"sku\": \"PROD-001\",\n \"location\": \"AA-01-B45-C\",\n \"name\": \"Widget\",\n \"description\": \"<string>\",\n \"tariff_code\": \"8471300000\",\n \"country_of_origin\": \"CN\",\n \"quantity\": 2,\n \"total_net_amount\": 15920,\n \"tax_amount\": 3980,\n \"duty_amount\": 5572,\n \"net_weight\": 550,\n \"cost_amount\": 5300\n }\n ]\n }\n ],\n \"total_net_amount\": 15920,\n \"tax_amount\": 3980,\n \"duty_amount\": 5572,\n \"shipping_net_amount\": 3920,\n \"shipping_tax_amount\": 980\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"data": [
{
"uuid": "550e8400-e29b-41d4-a716-446655440000",
"state": "open",
"currency": "EUR",
"weight_unit": "g",
"dimension_unit": "cm",
"invoice_number": "INV-1001121",
"reference": "Order-5521",
"identifier": "<string>",
"uri": "<string>",
"delivery": {
"carrier_code": "postnord",
"carrier_name": "PostNord",
"carrier_logo_url": "<string>",
"carrier_icon_url": "<string>",
"service_code": "postnord_agent",
"service_name": "Pickup Point",
"is_pickup": true,
"is_return": true,
"addons": [
{
"code": "SIGNATURE",
"name": "Signature"
}
],
"incoterm": "DAP"
},
"parties": {
"receiver": {
"reference": "<string>",
"identifier": "<string>",
"uri": "<string>",
"address": {
"address_lines": [
"3200 Whitehaven St. NW",
"Building A, Floor 2"
],
"postal_code": "20008",
"city": "Washington",
"country": "US",
"administrative_area": "DC"
},
"contact": {
"name_lines": [
"John Doe",
"Att. Finance department"
],
"company": "Acme Corp",
"email": "john@example.com",
"phone": "+4512345678"
},
"identifiers": {
"vat": "DK12345678",
"eori": "DK1234567890123",
"gb_eori": "GB123456789000",
"tax_id": "DK1234567890",
"voec": "2000123"
}
},
"pickup": {
"service_point_code": "12345",
"company": "Netto Nørrebrogade",
"address": {
"address_lines": [
"3200 Whitehaven St. NW",
"Building A, Floor 2"
],
"postal_code": "20008",
"city": "Washington",
"country": "US",
"administrative_area": "DC"
},
"reference": "<string>",
"identifier": "<string>",
"uri": "<string>"
}
},
"parcels": [
{
"uuid": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"reference": "<string>",
"identifier": "<string>",
"tracking_code": "00340434161094015749",
"tracking_url": "https://track.smartsend.io/00340434161094015749",
"freetext": "Gift wrapped as per requested",
"gross_weight": 1500,
"length": 30,
"width": 20,
"height": 15,
"total_net_amount": 15920,
"tax_amount": 3980,
"duty_amount": 5572,
"items": [
{
"reference": "<string>",
"identifier": "<string>",
"uri": "<string>",
"image_url": "https://www.example.com/products/1234-image1.jpeg",
"sku": "PROD-001",
"location": "AA-01-B45-C",
"name": "Widget",
"description": "<string>",
"tariff_code": "8471300000",
"country_of_origin": "CN",
"quantity": 2,
"total_net_amount": 15920,
"tax_amount": 3980,
"duty_amount": 5572,
"net_weight": 550,
"cost_amount": 5300
}
],
"documents": [
{
"type": "label",
"format": "pdf",
"url": "<string>"
}
]
}
],
"total_net_amount": 15920,
"tax_amount": 3980,
"duty_amount": 5572,
"shipping_net_amount": 3920,
"shipping_tax_amount": 980,
"created_at": "2023-11-07T05:31:56Z",
"booked_at": "2023-11-07T05:31:56Z"
}
]
}{
"message": "Something unexpected happened."
}{
"message": "Something unexpected happened."
}{
"message": "Something unexpected happened."
}{
"message": "Something unexpected happened."
}{
"message": "The given data was invalid.",
"errors": {
"field_name": [
"The field name is required."
]
}
}{
"message": "<string>"
}{
"message": "Something unexpected happened."
}{
"message": "Something unexpected happened."
}Add shipments to a batch
Adds one or more shipments to an open batch. Shipments are created but NOT booked until the batch is dispatched. Returns 422 if the batch is not in ‘open’ state.
curl --request POST \
--url https://app.smartsend.io/api/v2/team/{team}/booking-batches/{batch}/shipments \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"data": [
{
"currency": "EUR",
"weight_unit": "g",
"dimension_unit": "cm",
"invoice_number": "INV-1001121",
"reference": "Order-5521",
"identifier": "<string>",
"uri": "<string>",
"delivery": {
"addons": [
{
"code": "SIGNATURE"
}
],
"carrier": "postnord",
"service": "postnord_agent",
"incoterm": "DAP"
},
"parties": {
"receiver": {
"reference": "<string>",
"identifier": "<string>",
"uri": "<string>",
"address": {
"address_lines": [
"3200 Whitehaven St. NW",
"Building A, Floor 2"
],
"postal_code": "20008",
"city": "Washington",
"country": "US",
"administrative_area": "DC"
},
"contact": {
"name_lines": [
"John Doe",
"Att. Finance department"
],
"company": "Acme Corp",
"email": "john@example.com",
"phone": "+4512345678"
},
"identifiers": {
"vat": "DK12345678",
"eori": "DK1234567890123",
"gb_eori": "GB123456789000",
"tax_id": "DK1234567890",
"voec": "2000123"
}
},
"pickup": {
"service_point_code": "12345",
"reference": "<string>",
"identifier": "<string>",
"uri": "<string>"
}
},
"parcels": [
{
"reference": "<string>",
"identifier": "<string>",
"tracking_url": "https://track.smartsend.io/00340434161094015749",
"freetext": "Gift wrapped as per requested",
"gross_weight": 1500,
"length": 30,
"width": 20,
"height": 15,
"total_net_amount": 15920,
"tax_amount": 3980,
"duty_amount": 5572,
"items": [
{
"reference": "<string>",
"identifier": "<string>",
"uri": "<string>",
"image_url": "https://www.example.com/products/1234-image1.jpeg",
"sku": "PROD-001",
"location": "AA-01-B45-C",
"name": "Widget",
"description": "<string>",
"tariff_code": "8471300000",
"country_of_origin": "CN",
"quantity": 2,
"total_net_amount": 15920,
"tax_amount": 3980,
"duty_amount": 5572,
"net_weight": 550,
"cost_amount": 5300
}
]
}
],
"total_net_amount": 15920,
"tax_amount": 3980,
"duty_amount": 5572,
"shipping_net_amount": 3920,
"shipping_tax_amount": 980
}
]
}
'import requests
url = "https://app.smartsend.io/api/v2/team/{team}/booking-batches/{batch}/shipments"
payload = { "data": [
{
"currency": "EUR",
"weight_unit": "g",
"dimension_unit": "cm",
"invoice_number": "INV-1001121",
"reference": "Order-5521",
"identifier": "<string>",
"uri": "<string>",
"delivery": {
"addons": [{ "code": "SIGNATURE" }],
"carrier": "postnord",
"service": "postnord_agent",
"incoterm": "DAP"
},
"parties": {
"receiver": {
"reference": "<string>",
"identifier": "<string>",
"uri": "<string>",
"address": {
"address_lines": ["3200 Whitehaven St. NW", "Building A, Floor 2"],
"postal_code": "20008",
"city": "Washington",
"country": "US",
"administrative_area": "DC"
},
"contact": {
"name_lines": ["John Doe", "Att. Finance department"],
"company": "Acme Corp",
"email": "john@example.com",
"phone": "+4512345678"
},
"identifiers": {
"vat": "DK12345678",
"eori": "DK1234567890123",
"gb_eori": "GB123456789000",
"tax_id": "DK1234567890",
"voec": "2000123"
}
},
"pickup": {
"service_point_code": "12345",
"reference": "<string>",
"identifier": "<string>",
"uri": "<string>"
}
},
"parcels": [
{
"reference": "<string>",
"identifier": "<string>",
"tracking_url": "https://track.smartsend.io/00340434161094015749",
"freetext": "Gift wrapped as per requested",
"gross_weight": 1500,
"length": 30,
"width": 20,
"height": 15,
"total_net_amount": 15920,
"tax_amount": 3980,
"duty_amount": 5572,
"items": [
{
"reference": "<string>",
"identifier": "<string>",
"uri": "<string>",
"image_url": "https://www.example.com/products/1234-image1.jpeg",
"sku": "PROD-001",
"location": "AA-01-B45-C",
"name": "Widget",
"description": "<string>",
"tariff_code": "8471300000",
"country_of_origin": "CN",
"quantity": 2,
"total_net_amount": 15920,
"tax_amount": 3980,
"duty_amount": 5572,
"net_weight": 550,
"cost_amount": 5300
}
]
}
],
"total_net_amount": 15920,
"tax_amount": 3980,
"duty_amount": 5572,
"shipping_net_amount": 3920,
"shipping_tax_amount": 980
}
] }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
data: [
{
currency: 'EUR',
weight_unit: 'g',
dimension_unit: 'cm',
invoice_number: 'INV-1001121',
reference: 'Order-5521',
identifier: '<string>',
uri: '<string>',
delivery: {
addons: [{code: 'SIGNATURE'}],
carrier: 'postnord',
service: 'postnord_agent',
incoterm: 'DAP'
},
parties: {
receiver: {
reference: '<string>',
identifier: '<string>',
uri: '<string>',
address: {
address_lines: ['3200 Whitehaven St. NW', 'Building A, Floor 2'],
postal_code: '20008',
city: 'Washington',
country: 'US',
administrative_area: 'DC'
},
contact: {
name_lines: ['John Doe', 'Att. Finance department'],
company: 'Acme Corp',
email: 'john@example.com',
phone: '+4512345678'
},
identifiers: {
vat: 'DK12345678',
eori: 'DK1234567890123',
gb_eori: 'GB123456789000',
tax_id: 'DK1234567890',
voec: '2000123'
}
},
pickup: {
service_point_code: '12345',
reference: '<string>',
identifier: '<string>',
uri: '<string>'
}
},
parcels: [
{
reference: '<string>',
identifier: '<string>',
tracking_url: 'https://track.smartsend.io/00340434161094015749',
freetext: 'Gift wrapped as per requested',
gross_weight: 1500,
length: 30,
width: 20,
height: 15,
total_net_amount: 15920,
tax_amount: 3980,
duty_amount: 5572,
items: [
{
reference: '<string>',
identifier: '<string>',
uri: '<string>',
image_url: 'https://www.example.com/products/1234-image1.jpeg',
sku: 'PROD-001',
location: 'AA-01-B45-C',
name: 'Widget',
description: '<string>',
tariff_code: '8471300000',
country_of_origin: 'CN',
quantity: 2,
total_net_amount: 15920,
tax_amount: 3980,
duty_amount: 5572,
net_weight: 550,
cost_amount: 5300
}
]
}
],
total_net_amount: 15920,
tax_amount: 3980,
duty_amount: 5572,
shipping_net_amount: 3920,
shipping_tax_amount: 980
}
]
})
};
fetch('https://app.smartsend.io/api/v2/team/{team}/booking-batches/{batch}/shipments', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://app.smartsend.io/api/v2/team/{team}/booking-batches/{batch}/shipments",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'data' => [
[
'currency' => 'EUR',
'weight_unit' => 'g',
'dimension_unit' => 'cm',
'invoice_number' => 'INV-1001121',
'reference' => 'Order-5521',
'identifier' => '<string>',
'uri' => '<string>',
'delivery' => [
'addons' => [
[
'code' => 'SIGNATURE'
]
],
'carrier' => 'postnord',
'service' => 'postnord_agent',
'incoterm' => 'DAP'
],
'parties' => [
'receiver' => [
'reference' => '<string>',
'identifier' => '<string>',
'uri' => '<string>',
'address' => [
'address_lines' => [
'3200 Whitehaven St. NW',
'Building A, Floor 2'
],
'postal_code' => '20008',
'city' => 'Washington',
'country' => 'US',
'administrative_area' => 'DC'
],
'contact' => [
'name_lines' => [
'John Doe',
'Att. Finance department'
],
'company' => 'Acme Corp',
'email' => 'john@example.com',
'phone' => '+4512345678'
],
'identifiers' => [
'vat' => 'DK12345678',
'eori' => 'DK1234567890123',
'gb_eori' => 'GB123456789000',
'tax_id' => 'DK1234567890',
'voec' => '2000123'
]
],
'pickup' => [
'service_point_code' => '12345',
'reference' => '<string>',
'identifier' => '<string>',
'uri' => '<string>'
]
],
'parcels' => [
[
'reference' => '<string>',
'identifier' => '<string>',
'tracking_url' => 'https://track.smartsend.io/00340434161094015749',
'freetext' => 'Gift wrapped as per requested',
'gross_weight' => 1500,
'length' => 30,
'width' => 20,
'height' => 15,
'total_net_amount' => 15920,
'tax_amount' => 3980,
'duty_amount' => 5572,
'items' => [
[
'reference' => '<string>',
'identifier' => '<string>',
'uri' => '<string>',
'image_url' => 'https://www.example.com/products/1234-image1.jpeg',
'sku' => 'PROD-001',
'location' => 'AA-01-B45-C',
'name' => 'Widget',
'description' => '<string>',
'tariff_code' => '8471300000',
'country_of_origin' => 'CN',
'quantity' => 2,
'total_net_amount' => 15920,
'tax_amount' => 3980,
'duty_amount' => 5572,
'net_weight' => 550,
'cost_amount' => 5300
]
]
]
],
'total_net_amount' => 15920,
'tax_amount' => 3980,
'duty_amount' => 5572,
'shipping_net_amount' => 3920,
'shipping_tax_amount' => 980
]
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://app.smartsend.io/api/v2/team/{team}/booking-batches/{batch}/shipments"
payload := strings.NewReader("{\n \"data\": [\n {\n \"currency\": \"EUR\",\n \"weight_unit\": \"g\",\n \"dimension_unit\": \"cm\",\n \"invoice_number\": \"INV-1001121\",\n \"reference\": \"Order-5521\",\n \"identifier\": \"<string>\",\n \"uri\": \"<string>\",\n \"delivery\": {\n \"addons\": [\n {\n \"code\": \"SIGNATURE\"\n }\n ],\n \"carrier\": \"postnord\",\n \"service\": \"postnord_agent\",\n \"incoterm\": \"DAP\"\n },\n \"parties\": {\n \"receiver\": {\n \"reference\": \"<string>\",\n \"identifier\": \"<string>\",\n \"uri\": \"<string>\",\n \"address\": {\n \"address_lines\": [\n \"3200 Whitehaven St. NW\",\n \"Building A, Floor 2\"\n ],\n \"postal_code\": \"20008\",\n \"city\": \"Washington\",\n \"country\": \"US\",\n \"administrative_area\": \"DC\"\n },\n \"contact\": {\n \"name_lines\": [\n \"John Doe\",\n \"Att. Finance department\"\n ],\n \"company\": \"Acme Corp\",\n \"email\": \"john@example.com\",\n \"phone\": \"+4512345678\"\n },\n \"identifiers\": {\n \"vat\": \"DK12345678\",\n \"eori\": \"DK1234567890123\",\n \"gb_eori\": \"GB123456789000\",\n \"tax_id\": \"DK1234567890\",\n \"voec\": \"2000123\"\n }\n },\n \"pickup\": {\n \"service_point_code\": \"12345\",\n \"reference\": \"<string>\",\n \"identifier\": \"<string>\",\n \"uri\": \"<string>\"\n }\n },\n \"parcels\": [\n {\n \"reference\": \"<string>\",\n \"identifier\": \"<string>\",\n \"tracking_url\": \"https://track.smartsend.io/00340434161094015749\",\n \"freetext\": \"Gift wrapped as per requested\",\n \"gross_weight\": 1500,\n \"length\": 30,\n \"width\": 20,\n \"height\": 15,\n \"total_net_amount\": 15920,\n \"tax_amount\": 3980,\n \"duty_amount\": 5572,\n \"items\": [\n {\n \"reference\": \"<string>\",\n \"identifier\": \"<string>\",\n \"uri\": \"<string>\",\n \"image_url\": \"https://www.example.com/products/1234-image1.jpeg\",\n \"sku\": \"PROD-001\",\n \"location\": \"AA-01-B45-C\",\n \"name\": \"Widget\",\n \"description\": \"<string>\",\n \"tariff_code\": \"8471300000\",\n \"country_of_origin\": \"CN\",\n \"quantity\": 2,\n \"total_net_amount\": 15920,\n \"tax_amount\": 3980,\n \"duty_amount\": 5572,\n \"net_weight\": 550,\n \"cost_amount\": 5300\n }\n ]\n }\n ],\n \"total_net_amount\": 15920,\n \"tax_amount\": 3980,\n \"duty_amount\": 5572,\n \"shipping_net_amount\": 3920,\n \"shipping_tax_amount\": 980\n }\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://app.smartsend.io/api/v2/team/{team}/booking-batches/{batch}/shipments")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"data\": [\n {\n \"currency\": \"EUR\",\n \"weight_unit\": \"g\",\n \"dimension_unit\": \"cm\",\n \"invoice_number\": \"INV-1001121\",\n \"reference\": \"Order-5521\",\n \"identifier\": \"<string>\",\n \"uri\": \"<string>\",\n \"delivery\": {\n \"addons\": [\n {\n \"code\": \"SIGNATURE\"\n }\n ],\n \"carrier\": \"postnord\",\n \"service\": \"postnord_agent\",\n \"incoterm\": \"DAP\"\n },\n \"parties\": {\n \"receiver\": {\n \"reference\": \"<string>\",\n \"identifier\": \"<string>\",\n \"uri\": \"<string>\",\n \"address\": {\n \"address_lines\": [\n \"3200 Whitehaven St. NW\",\n \"Building A, Floor 2\"\n ],\n \"postal_code\": \"20008\",\n \"city\": \"Washington\",\n \"country\": \"US\",\n \"administrative_area\": \"DC\"\n },\n \"contact\": {\n \"name_lines\": [\n \"John Doe\",\n \"Att. Finance department\"\n ],\n \"company\": \"Acme Corp\",\n \"email\": \"john@example.com\",\n \"phone\": \"+4512345678\"\n },\n \"identifiers\": {\n \"vat\": \"DK12345678\",\n \"eori\": \"DK1234567890123\",\n \"gb_eori\": \"GB123456789000\",\n \"tax_id\": \"DK1234567890\",\n \"voec\": \"2000123\"\n }\n },\n \"pickup\": {\n \"service_point_code\": \"12345\",\n \"reference\": \"<string>\",\n \"identifier\": \"<string>\",\n \"uri\": \"<string>\"\n }\n },\n \"parcels\": [\n {\n \"reference\": \"<string>\",\n \"identifier\": \"<string>\",\n \"tracking_url\": \"https://track.smartsend.io/00340434161094015749\",\n \"freetext\": \"Gift wrapped as per requested\",\n \"gross_weight\": 1500,\n \"length\": 30,\n \"width\": 20,\n \"height\": 15,\n \"total_net_amount\": 15920,\n \"tax_amount\": 3980,\n \"duty_amount\": 5572,\n \"items\": [\n {\n \"reference\": \"<string>\",\n \"identifier\": \"<string>\",\n \"uri\": \"<string>\",\n \"image_url\": \"https://www.example.com/products/1234-image1.jpeg\",\n \"sku\": \"PROD-001\",\n \"location\": \"AA-01-B45-C\",\n \"name\": \"Widget\",\n \"description\": \"<string>\",\n \"tariff_code\": \"8471300000\",\n \"country_of_origin\": \"CN\",\n \"quantity\": 2,\n \"total_net_amount\": 15920,\n \"tax_amount\": 3980,\n \"duty_amount\": 5572,\n \"net_weight\": 550,\n \"cost_amount\": 5300\n }\n ]\n }\n ],\n \"total_net_amount\": 15920,\n \"tax_amount\": 3980,\n \"duty_amount\": 5572,\n \"shipping_net_amount\": 3920,\n \"shipping_tax_amount\": 980\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.smartsend.io/api/v2/team/{team}/booking-batches/{batch}/shipments")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"data\": [\n {\n \"currency\": \"EUR\",\n \"weight_unit\": \"g\",\n \"dimension_unit\": \"cm\",\n \"invoice_number\": \"INV-1001121\",\n \"reference\": \"Order-5521\",\n \"identifier\": \"<string>\",\n \"uri\": \"<string>\",\n \"delivery\": {\n \"addons\": [\n {\n \"code\": \"SIGNATURE\"\n }\n ],\n \"carrier\": \"postnord\",\n \"service\": \"postnord_agent\",\n \"incoterm\": \"DAP\"\n },\n \"parties\": {\n \"receiver\": {\n \"reference\": \"<string>\",\n \"identifier\": \"<string>\",\n \"uri\": \"<string>\",\n \"address\": {\n \"address_lines\": [\n \"3200 Whitehaven St. NW\",\n \"Building A, Floor 2\"\n ],\n \"postal_code\": \"20008\",\n \"city\": \"Washington\",\n \"country\": \"US\",\n \"administrative_area\": \"DC\"\n },\n \"contact\": {\n \"name_lines\": [\n \"John Doe\",\n \"Att. Finance department\"\n ],\n \"company\": \"Acme Corp\",\n \"email\": \"john@example.com\",\n \"phone\": \"+4512345678\"\n },\n \"identifiers\": {\n \"vat\": \"DK12345678\",\n \"eori\": \"DK1234567890123\",\n \"gb_eori\": \"GB123456789000\",\n \"tax_id\": \"DK1234567890\",\n \"voec\": \"2000123\"\n }\n },\n \"pickup\": {\n \"service_point_code\": \"12345\",\n \"reference\": \"<string>\",\n \"identifier\": \"<string>\",\n \"uri\": \"<string>\"\n }\n },\n \"parcels\": [\n {\n \"reference\": \"<string>\",\n \"identifier\": \"<string>\",\n \"tracking_url\": \"https://track.smartsend.io/00340434161094015749\",\n \"freetext\": \"Gift wrapped as per requested\",\n \"gross_weight\": 1500,\n \"length\": 30,\n \"width\": 20,\n \"height\": 15,\n \"total_net_amount\": 15920,\n \"tax_amount\": 3980,\n \"duty_amount\": 5572,\n \"items\": [\n {\n \"reference\": \"<string>\",\n \"identifier\": \"<string>\",\n \"uri\": \"<string>\",\n \"image_url\": \"https://www.example.com/products/1234-image1.jpeg\",\n \"sku\": \"PROD-001\",\n \"location\": \"AA-01-B45-C\",\n \"name\": \"Widget\",\n \"description\": \"<string>\",\n \"tariff_code\": \"8471300000\",\n \"country_of_origin\": \"CN\",\n \"quantity\": 2,\n \"total_net_amount\": 15920,\n \"tax_amount\": 3980,\n \"duty_amount\": 5572,\n \"net_weight\": 550,\n \"cost_amount\": 5300\n }\n ]\n }\n ],\n \"total_net_amount\": 15920,\n \"tax_amount\": 3980,\n \"duty_amount\": 5572,\n \"shipping_net_amount\": 3920,\n \"shipping_tax_amount\": 980\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"data": [
{
"uuid": "550e8400-e29b-41d4-a716-446655440000",
"state": "open",
"currency": "EUR",
"weight_unit": "g",
"dimension_unit": "cm",
"invoice_number": "INV-1001121",
"reference": "Order-5521",
"identifier": "<string>",
"uri": "<string>",
"delivery": {
"carrier_code": "postnord",
"carrier_name": "PostNord",
"carrier_logo_url": "<string>",
"carrier_icon_url": "<string>",
"service_code": "postnord_agent",
"service_name": "Pickup Point",
"is_pickup": true,
"is_return": true,
"addons": [
{
"code": "SIGNATURE",
"name": "Signature"
}
],
"incoterm": "DAP"
},
"parties": {
"receiver": {
"reference": "<string>",
"identifier": "<string>",
"uri": "<string>",
"address": {
"address_lines": [
"3200 Whitehaven St. NW",
"Building A, Floor 2"
],
"postal_code": "20008",
"city": "Washington",
"country": "US",
"administrative_area": "DC"
},
"contact": {
"name_lines": [
"John Doe",
"Att. Finance department"
],
"company": "Acme Corp",
"email": "john@example.com",
"phone": "+4512345678"
},
"identifiers": {
"vat": "DK12345678",
"eori": "DK1234567890123",
"gb_eori": "GB123456789000",
"tax_id": "DK1234567890",
"voec": "2000123"
}
},
"pickup": {
"service_point_code": "12345",
"company": "Netto Nørrebrogade",
"address": {
"address_lines": [
"3200 Whitehaven St. NW",
"Building A, Floor 2"
],
"postal_code": "20008",
"city": "Washington",
"country": "US",
"administrative_area": "DC"
},
"reference": "<string>",
"identifier": "<string>",
"uri": "<string>"
}
},
"parcels": [
{
"uuid": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"reference": "<string>",
"identifier": "<string>",
"tracking_code": "00340434161094015749",
"tracking_url": "https://track.smartsend.io/00340434161094015749",
"freetext": "Gift wrapped as per requested",
"gross_weight": 1500,
"length": 30,
"width": 20,
"height": 15,
"total_net_amount": 15920,
"tax_amount": 3980,
"duty_amount": 5572,
"items": [
{
"reference": "<string>",
"identifier": "<string>",
"uri": "<string>",
"image_url": "https://www.example.com/products/1234-image1.jpeg",
"sku": "PROD-001",
"location": "AA-01-B45-C",
"name": "Widget",
"description": "<string>",
"tariff_code": "8471300000",
"country_of_origin": "CN",
"quantity": 2,
"total_net_amount": 15920,
"tax_amount": 3980,
"duty_amount": 5572,
"net_weight": 550,
"cost_amount": 5300
}
],
"documents": [
{
"type": "label",
"format": "pdf",
"url": "<string>"
}
]
}
],
"total_net_amount": 15920,
"tax_amount": 3980,
"duty_amount": 5572,
"shipping_net_amount": 3920,
"shipping_tax_amount": 980,
"created_at": "2023-11-07T05:31:56Z",
"booked_at": "2023-11-07T05:31:56Z"
}
]
}{
"message": "Something unexpected happened."
}{
"message": "Something unexpected happened."
}{
"message": "Something unexpected happened."
}{
"message": "Something unexpected happened."
}{
"message": "The given data was invalid.",
"errors": {
"field_name": [
"The field name is required."
]
}
}{
"message": "<string>"
}{
"message": "Something unexpected happened."
}{
"message": "Something unexpected happened."
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Headers
Preferred language(s) for translatable content using BCP 47 language tags. Supports quality values (q-factors) for priority ordering. The API negotiates the best available language based on this header, the team's configured language, and available translations. If omitted, the team's default language is used.
"da-DK, da;q=0.9, en;q=0.8"
Any value passed in this request will be returned in the same header. This can be used to correlate requests between client and server.
1 - 128^[A-Za-z0-9._-]{1,128}$Optional key that makes a write request idempotent so it can be safely retried. Reusing the key with an identical payload within 24 hours returns the original response without re-executing the operation (with an Idempotency-Replayed: true response header); reusing it with a different payload returns 422, and retrying while the original is still processing returns 409 with a Retry-After header. Use a client-generated, case-sensitive string of 16–128 characters (letters, digits, ., _, -). Deriving it deterministically from the request — for example the order ID combined with a hash of the payload — lets retries reuse the same key without storing it. See https://docs.smartsend.io/api-reference/idempotency.
16 - 128^[A-Za-z0-9._-]{16,128}$Path Parameters
Team identifier. All resources are scoped to this team.
1"ad9546c1-393e-49a5-9a72-5cc146c9bec5"
Unique identifier of the batch
Body
Array of shipments to add to the batch
1Show child attributes
Show child attributes
Response
Shipments added to batch successfully
Array of created shipments
Show child attributes
Show child attributes
Was this page helpful?