Skip to content
Docs
API 1.0.0 · 22 Nov 2026

Search the docs

    Română

    Shipments

    The pack station: scan the picked units into the shipment, weigh it, choose the carrier service, print the label and hand it to the carrier.

    On this page

    List shipments

    GET /warehouse/v1/shipments

    Returns shipments in pages, by order number.

    Parameters

    NameInTypeRequiredMeaning
    status query string Nooptional Only shipments in this status. One of waiting, packing, ready, printed, dispatched
    limit query integer Nooptional Records per page. Default 100 Range 1 – 500
    cursor query string Nooptional The nextCursor of the previous page.

    Responses

    StatusMeaningBody
    200 A page of records. ShipmentPage
    400 The request cannot be read or breaks the contract: malformed JSON, a missing or unknown field, a wrong type. fields names each one. Error
    401 The token is missing, not valid or has ended. Error
    403 The token does not give access to this company or operation. Error
    429 The request was refused. The code is rate_limited. Error
    503 The request was refused. The code is unavailable. Error

    Request

    curl

    curl "$RDC_BASE_URL/warehouse/v1/shipments?limit=20" \
      -H "Authorization: Bearer $RDC_TOKEN"

    JavaScript

    const response = await fetch(`${process.env.RDC_BASE_URL}/warehouse/v1/shipments?limit=20`, {
      method: 'GET',
      headers: {
        Authorization: `Bearer ${process.env.RDC_TOKEN}`,
      },
    });
    const result = await response.json();

    Python

    import os
    import requests
    
    response = requests.request(
        'GET',
        f'{os.environ["RDC_BASE_URL"]}/warehouse/v1/shipments?limit=20',
        headers={
            'Authorization': f'Bearer {os.environ["RDC_TOKEN"]}',
        },
    )
    result = response.json()

    PHP

    <?php
    
    $curl = curl_init(getenv('RDC_BASE_URL') . '/warehouse/v1/shipments?limit=20');
    curl_setopt_array($curl, [
        CURLOPT_CUSTOMREQUEST => 'GET',
        CURLOPT_RETURNTRANSFER => true,
        CURLOPT_HTTPHEADER => [
            'Authorization: Bearer ' . getenv('RDC_TOKEN'),
        ],
    ]);
    $result = json_decode(curl_exec($curl), true);
    curl_close($curl);

    C#

    using System.Net.Http.Headers;
    
    var client = new HttpClient();
    var request = new HttpRequestMessage(HttpMethod.Get, $"{Environment.GetEnvironmentVariable("RDC_BASE_URL")}/warehouse/v1/shipments?limit=20");
    request.Headers.Authorization = new AuthenticationHeaderValue("Bearer", Environment.GetEnvironmentVariable("RDC_TOKEN"));
    var response = await client.SendAsync(request);
    var result = await response.Content.ReadAsStringAsync();

    Response 200

    JSON

    {
      "items": [
        {
          "id": "a4000000-0000-4000-8000-000000001043",
          "number": "EXP-1043",
          "orderNumber": "CV-1043",
          "status": "packing",
          "lines": [
            {
              "sku": "FA-0010",
              "picked": "10",
              "packed": "10"
            },
            {
              "sku": "ZA-0201",
              "picked": "20",
              "packed": "20"
            },
            {
              "sku": "LA-0307",
              "picked": "6",
              "packed": "0"
            }
          ],
          "expectedWeightKg": "120.400",
          "weightKg": null,
          "service": null,
          "label": null,
          "dispatchedAt": null,
          "revision": 3
        },
        {
          "id": "a4000000-0000-4000-8000-000000001042",
          "number": "EXP-1042",
          "orderNumber": "CV-1042",
          "status": "waiting",
          "lines": [
            {
              "sku": "FA-0010",
              "picked": "24",
              "packed": "0"
            },
            {
              "sku": "UL-0101",
              "picked": "48",
              "packed": "0"
            },
            {
              "sku": "ZA-0201",
              "picked": "80",
              "packed": "0"
            },
            {
              "sku": "LA-0307",
              "picked": "30",
              "packed": "0"
            },
            {
              "sku": "DT-0412",
              "picked": "0",
              "packed": "0"
            },
            {
              "sku": "AM-0518",
              "picked": "0",
              "packed": "0"
            }
          ],
          "expectedWeightKg": "0.400",
          "weightKg": null,
          "service": null,
          "label": null,
          "dispatchedAt": null,
          "revision": 1
        }
      ],
      "nextCursor": null
    }

    Get a shipment

    GET /warehouse/v1/shipments/{shipmentId}

    Parameters

    NameInTypeRequiredMeaning
    shipmentId path string (uuid) Yesrequired The shipment.

    Responses

    StatusMeaningBody
    200 The record at its current revision. Shipment
    401 The token is missing, not valid or has ended. Error
    403 The token does not give access to this company or operation. Error
    404 The request was refused. The code is shipment_not_found. Error
    429 The request was refused. The code is rate_limited. Error
    503 The request was refused. The code is unavailable. Error

    Request

    curl

    curl "$RDC_BASE_URL/warehouse/v1/shipments/a4000000-0000-4000-8000-000000001043" \
      -H "Authorization: Bearer $RDC_TOKEN"

    JavaScript

    const response = await fetch(`${process.env.RDC_BASE_URL}/warehouse/v1/shipments/a4000000-0000-4000-8000-000000001043`, {
      method: 'GET',
      headers: {
        Authorization: `Bearer ${process.env.RDC_TOKEN}`,
      },
    });
    const result = await response.json();

    Python

    import os
    import requests
    
    response = requests.request(
        'GET',
        f'{os.environ["RDC_BASE_URL"]}/warehouse/v1/shipments/a4000000-0000-4000-8000-000000001043',
        headers={
            'Authorization': f'Bearer {os.environ["RDC_TOKEN"]}',
        },
    )
    result = response.json()

    PHP

    <?php
    
    $curl = curl_init(getenv('RDC_BASE_URL') . '/warehouse/v1/shipments/a4000000-0000-4000-8000-000000001043');
    curl_setopt_array($curl, [
        CURLOPT_CUSTOMREQUEST => 'GET',
        CURLOPT_RETURNTRANSFER => true,
        CURLOPT_HTTPHEADER => [
            'Authorization: Bearer ' . getenv('RDC_TOKEN'),
        ],
    ]);
    $result = json_decode(curl_exec($curl), true);
    curl_close($curl);

    C#

    using System.Net.Http.Headers;
    
    var client = new HttpClient();
    var request = new HttpRequestMessage(HttpMethod.Get, $"{Environment.GetEnvironmentVariable("RDC_BASE_URL")}/warehouse/v1/shipments/a4000000-0000-4000-8000-000000001043");
    request.Headers.Authorization = new AuthenticationHeaderValue("Bearer", Environment.GetEnvironmentVariable("RDC_TOKEN"));
    var response = await client.SendAsync(request);
    var result = await response.Content.ReadAsStringAsync();

    Response 200

    JSON

    {
      "id": "a4000000-0000-4000-8000-000000001043",
      "number": "EXP-1043",
      "orderNumber": "CV-1043",
      "status": "packing",
      "lines": [
        {
          "sku": "FA-0010",
          "picked": "10",
          "packed": "10"
        },
        {
          "sku": "ZA-0201",
          "picked": "20",
          "packed": "20"
        },
        {
          "sku": "LA-0307",
          "picked": "6",
          "packed": "0"
        }
      ],
      "expectedWeightKg": "120.400",
      "weightKg": null,
      "service": null,
      "label": null,
      "dispatchedAt": null,
      "revision": 3
    }

    Scan an item into the shipment

    POST /warehouse/v1/shipments/{shipmentId}/scan-item

    Moves picked units from the tote of the order into the shipment. Only an item of the order, and no more than was picked, is accepted; a unit added after the weighing takes the weighing back.

    Parameters

    NameInTypeRequiredMeaning
    shipmentId path string (uuid) Yesrequired The shipment.

    Request body

    FieldTypeRequiredMeaning
    operationId string (uuid) Yesrequired A UUID you choose for this change. Send it again to repeat the request.
    expectedRevision integer Yesrequired The revision of the shipment you read.
    code string Yesrequired The scanned barcode of the item.
    quantity string Nooptional Units this scan moves, at least 1. 1 by default.

    Responses

    StatusMeaningBody
    202 The change was accepted. The body is the operation result. OperationResult
    400 The request cannot be read or breaks the contract: malformed JSON, a missing or unknown field, a wrong type. fields names each one. Error
    401 The token is missing, not valid or has ended. Error
    403 The token does not give access to this company or operation. Error
    404 The request was refused. The code is shipment_not_found. Error
    409 The request was refused. The code is revision_conflict or operation_reused. Error
    422 The request was refused. The code is label_printed, code_not_recognized, wrong_item, quantity_not_valid, nothing_picked or too_many. Error
    429 The request was refused. The code is rate_limited. Error
    503 The request was refused. The code is unavailable. Error

    Request

    curl

    curl -X POST "$RDC_BASE_URL/warehouse/v1/shipments/a4000000-0000-4000-8000-000000001043/scan-item" \
      -H "Authorization: Bearer $RDC_TOKEN" \
      -H "Content-Type: application/json" \
      -d '{
      "operationId": "7a7461df-9c5d-4dc7-8417-da01623dda37",
      "expectedRevision": 3,
      "code": "2900000003071",
      "quantity": "6"
    }'

    JavaScript

    const response = await fetch(`${process.env.RDC_BASE_URL}/warehouse/v1/shipments/a4000000-0000-4000-8000-000000001043/scan-item`, {
      method: 'POST',
      headers: {
        Authorization: `Bearer ${process.env.RDC_TOKEN}`,
        'Content-Type': 'application/json',
      },
      body: JSON.stringify({
        "operationId": "7a7461df-9c5d-4dc7-8417-da01623dda37",
        "expectedRevision": 3,
        "code": "2900000003071",
        "quantity": "6"
      }),
    });
    const result = await response.json();

    Python

    import os
    import requests
    
    response = requests.request(
        'POST',
        f'{os.environ["RDC_BASE_URL"]}/warehouse/v1/shipments/a4000000-0000-4000-8000-000000001043/scan-item',
        headers={
            'Authorization': f'Bearer {os.environ["RDC_TOKEN"]}',
        },
        json={
            'operationId': '7a7461df-9c5d-4dc7-8417-da01623dda37',
            'expectedRevision': 3,
            'code': '2900000003071',
            'quantity': '6',
        },
    )
    result = response.json()

    PHP

    <?php
    
    $body = <<<'JSON'
    {
      "operationId": "7a7461df-9c5d-4dc7-8417-da01623dda37",
      "expectedRevision": 3,
      "code": "2900000003071",
      "quantity": "6"
    }
    JSON;
    
    $curl = curl_init(getenv('RDC_BASE_URL') . '/warehouse/v1/shipments/a4000000-0000-4000-8000-000000001043/scan-item');
    curl_setopt_array($curl, [
        CURLOPT_CUSTOMREQUEST => 'POST',
        CURLOPT_RETURNTRANSFER => true,
        CURLOPT_HTTPHEADER => [
            'Authorization: Bearer ' . getenv('RDC_TOKEN'),
            'Content-Type: application/json',
        ],
        CURLOPT_POSTFIELDS => $body,
    ]);
    $result = json_decode(curl_exec($curl), true);
    curl_close($curl);

    C#

    using System.Net.Http.Headers;
    
    var client = new HttpClient();
    var request = new HttpRequestMessage(HttpMethod.Post, $"{Environment.GetEnvironmentVariable("RDC_BASE_URL")}/warehouse/v1/shipments/a4000000-0000-4000-8000-000000001043/scan-item");
    request.Headers.Authorization = new AuthenticationHeaderValue("Bearer", Environment.GetEnvironmentVariable("RDC_TOKEN"));
    request.Content = new StringContent("""
    {
      "operationId": "7a7461df-9c5d-4dc7-8417-da01623dda37",
      "expectedRevision": 3,
      "code": "2900000003071",
      "quantity": "6"
    }
    """, System.Text.Encoding.UTF8, "application/json");
    var response = await client.SendAsync(request);
    var result = await response.Content.ReadAsStringAsync();

    Response 202

    JSON

    {
      "operationId": "7a7461df-9c5d-4dc7-8417-da01623dda37",
      "status": "accepted",
      "aggregateRevision": 4
    }

    Record the weight

    POST /warehouse/v1/shipments/{shipmentId}/weight

    Records the weight read at the pack station. It is accepted when it is within the tolerance of the weight to expect, which is the weight of the packed units and of the carton; otherwise it is refused and the shipment is checked again.

    Parameters

    NameInTypeRequiredMeaning
    shipmentId path string (uuid) Yesrequired The shipment.

    Request body

    FieldTypeRequiredMeaning
    operationId string (uuid) Yesrequired A UUID you choose for this change. Send it again to repeat the request.
    expectedRevision integer Yesrequired The revision of the shipment you read.
    weightKg string Yesrequired The weight read, in kilograms, up to three decimals.

    Responses

    StatusMeaningBody
    202 The change was accepted. The body is the operation result. OperationResult
    400 The request cannot be read or breaks the contract: malformed JSON, a missing or unknown field, a wrong type. fields names each one. Error
    401 The token is missing, not valid or has ended. Error
    403 The token does not give access to this company or operation. Error
    404 The request was refused. The code is shipment_not_found. Error
    409 The request was refused. The code is revision_conflict or operation_reused. Error
    422 The request was refused. The code is label_printed, picking_open, not_all_packed, weight_not_valid or weight_mismatch. Error
    429 The request was refused. The code is rate_limited. Error
    503 The request was refused. The code is unavailable. Error

    Request

    curl

    curl -X POST "$RDC_BASE_URL/warehouse/v1/shipments/a4000000-0000-4000-8000-000000001043/weight" \
      -H "Authorization: Bearer $RDC_TOKEN" \
      -H "Content-Type: application/json" \
      -d '{
      "operationId": "50ef2e5b-1db3-425d-8cf6-9d05f8e9882d",
      "expectedRevision": 4,
      "weightKg": "122.000"
    }'

    JavaScript

    const response = await fetch(`${process.env.RDC_BASE_URL}/warehouse/v1/shipments/a4000000-0000-4000-8000-000000001043/weight`, {
      method: 'POST',
      headers: {
        Authorization: `Bearer ${process.env.RDC_TOKEN}`,
        'Content-Type': 'application/json',
      },
      body: JSON.stringify({
        "operationId": "50ef2e5b-1db3-425d-8cf6-9d05f8e9882d",
        "expectedRevision": 4,
        "weightKg": "122.000"
      }),
    });
    const result = await response.json();

    Python

    import os
    import requests
    
    response = requests.request(
        'POST',
        f'{os.environ["RDC_BASE_URL"]}/warehouse/v1/shipments/a4000000-0000-4000-8000-000000001043/weight',
        headers={
            'Authorization': f'Bearer {os.environ["RDC_TOKEN"]}',
        },
        json={
            'operationId': '50ef2e5b-1db3-425d-8cf6-9d05f8e9882d',
            'expectedRevision': 4,
            'weightKg': '122.000',
        },
    )
    result = response.json()

    PHP

    <?php
    
    $body = <<<'JSON'
    {
      "operationId": "50ef2e5b-1db3-425d-8cf6-9d05f8e9882d",
      "expectedRevision": 4,
      "weightKg": "122.000"
    }
    JSON;
    
    $curl = curl_init(getenv('RDC_BASE_URL') . '/warehouse/v1/shipments/a4000000-0000-4000-8000-000000001043/weight');
    curl_setopt_array($curl, [
        CURLOPT_CUSTOMREQUEST => 'POST',
        CURLOPT_RETURNTRANSFER => true,
        CURLOPT_HTTPHEADER => [
            'Authorization: Bearer ' . getenv('RDC_TOKEN'),
            'Content-Type: application/json',
        ],
        CURLOPT_POSTFIELDS => $body,
    ]);
    $result = json_decode(curl_exec($curl), true);
    curl_close($curl);

    C#

    using System.Net.Http.Headers;
    
    var client = new HttpClient();
    var request = new HttpRequestMessage(HttpMethod.Post, $"{Environment.GetEnvironmentVariable("RDC_BASE_URL")}/warehouse/v1/shipments/a4000000-0000-4000-8000-000000001043/weight");
    request.Headers.Authorization = new AuthenticationHeaderValue("Bearer", Environment.GetEnvironmentVariable("RDC_TOKEN"));
    request.Content = new StringContent("""
    {
      "operationId": "50ef2e5b-1db3-425d-8cf6-9d05f8e9882d",
      "expectedRevision": 4,
      "weightKg": "122.000"
    }
    """, System.Text.Encoding.UTF8, "application/json");
    var response = await client.SendAsync(request);
    var result = await response.Content.ReadAsStringAsync();

    Response 202

    JSON

    {
      "operationId": "50ef2e5b-1db3-425d-8cf6-9d05f8e9882d",
      "status": "accepted",
      "aggregateRevision": 5
    }

    Choose the carrier service

    POST /warehouse/v1/shipments/{shipmentId}/service

    Chooses standard, delivered in two working days, or next-day, delivered in one.

    Parameters

    NameInTypeRequiredMeaning
    shipmentId path string (uuid) Yesrequired The shipment.

    Request body

    FieldTypeRequiredMeaning
    operationId string (uuid) Yesrequired A UUID you choose for this change. Send it again to repeat the request.
    expectedRevision integer Yesrequired The revision of the shipment you read.
    service string Yesrequired The service: standard or next-day. One of standard, next-day

    Responses

    StatusMeaningBody
    202 The change was accepted. The body is the operation result. OperationResult
    400 The request cannot be read or breaks the contract: malformed JSON, a missing or unknown field, a wrong type. fields names each one. Error
    401 The token is missing, not valid or has ended. Error
    403 The token does not give access to this company or operation. Error
    404 The request was refused. The code is shipment_not_found. Error
    409 The request was refused. The code is revision_conflict or operation_reused. Error
    422 The request was refused. The code is label_printed or service_not_valid. Error
    429 The request was refused. The code is rate_limited. Error
    503 The request was refused. The code is unavailable. Error

    Request

    curl

    curl -X POST "$RDC_BASE_URL/warehouse/v1/shipments/a4000000-0000-4000-8000-000000001043/service" \
      -H "Authorization: Bearer $RDC_TOKEN" \
      -H "Content-Type: application/json" \
      -d '{
      "operationId": "2918a9f7-d7e0-481f-89fc-94e955e7fa0f",
      "expectedRevision": 3,
      "service": "next-day"
    }'

    JavaScript

    const response = await fetch(`${process.env.RDC_BASE_URL}/warehouse/v1/shipments/a4000000-0000-4000-8000-000000001043/service`, {
      method: 'POST',
      headers: {
        Authorization: `Bearer ${process.env.RDC_TOKEN}`,
        'Content-Type': 'application/json',
      },
      body: JSON.stringify({
        "operationId": "2918a9f7-d7e0-481f-89fc-94e955e7fa0f",
        "expectedRevision": 3,
        "service": "next-day"
      }),
    });
    const result = await response.json();

    Python

    import os
    import requests
    
    response = requests.request(
        'POST',
        f'{os.environ["RDC_BASE_URL"]}/warehouse/v1/shipments/a4000000-0000-4000-8000-000000001043/service',
        headers={
            'Authorization': f'Bearer {os.environ["RDC_TOKEN"]}',
        },
        json={
            'operationId': '2918a9f7-d7e0-481f-89fc-94e955e7fa0f',
            'expectedRevision': 3,
            'service': 'next-day',
        },
    )
    result = response.json()

    PHP

    <?php
    
    $body = <<<'JSON'
    {
      "operationId": "2918a9f7-d7e0-481f-89fc-94e955e7fa0f",
      "expectedRevision": 3,
      "service": "next-day"
    }
    JSON;
    
    $curl = curl_init(getenv('RDC_BASE_URL') . '/warehouse/v1/shipments/a4000000-0000-4000-8000-000000001043/service');
    curl_setopt_array($curl, [
        CURLOPT_CUSTOMREQUEST => 'POST',
        CURLOPT_RETURNTRANSFER => true,
        CURLOPT_HTTPHEADER => [
            'Authorization: Bearer ' . getenv('RDC_TOKEN'),
            'Content-Type: application/json',
        ],
        CURLOPT_POSTFIELDS => $body,
    ]);
    $result = json_decode(curl_exec($curl), true);
    curl_close($curl);

    C#

    using System.Net.Http.Headers;
    
    var client = new HttpClient();
    var request = new HttpRequestMessage(HttpMethod.Post, $"{Environment.GetEnvironmentVariable("RDC_BASE_URL")}/warehouse/v1/shipments/a4000000-0000-4000-8000-000000001043/service");
    request.Headers.Authorization = new AuthenticationHeaderValue("Bearer", Environment.GetEnvironmentVariable("RDC_TOKEN"));
    request.Content = new StringContent("""
    {
      "operationId": "2918a9f7-d7e0-481f-89fc-94e955e7fa0f",
      "expectedRevision": 3,
      "service": "next-day"
    }
    """, System.Text.Encoding.UTF8, "application/json");
    var response = await client.SendAsync(request);
    var result = await response.Content.ReadAsStringAsync();

    Response 202

    JSON

    {
      "operationId": "2918a9f7-d7e0-481f-89fc-94e955e7fa0f",
      "status": "accepted",
      "aggregateRevision": 4
    }

    POST /warehouse/v1/shipments/{shipmentId}/label

    Prints the label of a shipment that is packed, weighed and has a service. The label carries the tracking number, the day the shipment leaves and the day it is delivered; a shipment packed after the cut-off leaves on the next working day. The shipment is closed.

    Parameters

    NameInTypeRequiredMeaning
    shipmentId path string (uuid) Yesrequired The shipment.

    Request body

    FieldTypeRequiredMeaning
    operationId string (uuid) Yesrequired A UUID you choose for this change. Send it again to repeat the request.
    expectedRevision integer Yesrequired The revision of the shipment you read.

    Responses

    StatusMeaningBody
    202 The change was accepted. The body is the operation result. OperationResult
    400 The request cannot be read or breaks the contract: malformed JSON, a missing or unknown field, a wrong type. fields names each one. Error
    401 The token is missing, not valid or has ended. Error
    403 The token does not give access to this company or operation. Error
    404 The request was refused. The code is shipment_not_found. Error
    409 The request was refused. The code is revision_conflict or operation_reused. Error
    422 The request was refused. The code is label_printed, picking_open, nothing_to_ship, not_all_packed, weight_missing or service_missing. Error
    429 The request was refused. The code is rate_limited. Error
    503 The request was refused. The code is unavailable. Error

    Request

    curl

    curl -X POST "$RDC_BASE_URL/warehouse/v1/shipments/a4000000-0000-4000-8000-000000001043/label" \
      -H "Authorization: Bearer $RDC_TOKEN" \
      -H "Content-Type: application/json" \
      -d '{
      "operationId": "e68f5fae-0cec-430c-8b5c-9612dbb6d3cc",
      "expectedRevision": 6
    }'

    JavaScript

    const response = await fetch(`${process.env.RDC_BASE_URL}/warehouse/v1/shipments/a4000000-0000-4000-8000-000000001043/label`, {
      method: 'POST',
      headers: {
        Authorization: `Bearer ${process.env.RDC_TOKEN}`,
        'Content-Type': 'application/json',
      },
      body: JSON.stringify({
        "operationId": "e68f5fae-0cec-430c-8b5c-9612dbb6d3cc",
        "expectedRevision": 6
      }),
    });
    const result = await response.json();

    Python

    import os
    import requests
    
    response = requests.request(
        'POST',
        f'{os.environ["RDC_BASE_URL"]}/warehouse/v1/shipments/a4000000-0000-4000-8000-000000001043/label',
        headers={
            'Authorization': f'Bearer {os.environ["RDC_TOKEN"]}',
        },
        json={
            'operationId': 'e68f5fae-0cec-430c-8b5c-9612dbb6d3cc',
            'expectedRevision': 6,
        },
    )
    result = response.json()

    PHP

    <?php
    
    $body = <<<'JSON'
    {
      "operationId": "e68f5fae-0cec-430c-8b5c-9612dbb6d3cc",
      "expectedRevision": 6
    }
    JSON;
    
    $curl = curl_init(getenv('RDC_BASE_URL') . '/warehouse/v1/shipments/a4000000-0000-4000-8000-000000001043/label');
    curl_setopt_array($curl, [
        CURLOPT_CUSTOMREQUEST => 'POST',
        CURLOPT_RETURNTRANSFER => true,
        CURLOPT_HTTPHEADER => [
            'Authorization: Bearer ' . getenv('RDC_TOKEN'),
            'Content-Type: application/json',
        ],
        CURLOPT_POSTFIELDS => $body,
    ]);
    $result = json_decode(curl_exec($curl), true);
    curl_close($curl);

    C#

    using System.Net.Http.Headers;
    
    var client = new HttpClient();
    var request = new HttpRequestMessage(HttpMethod.Post, $"{Environment.GetEnvironmentVariable("RDC_BASE_URL")}/warehouse/v1/shipments/a4000000-0000-4000-8000-000000001043/label");
    request.Headers.Authorization = new AuthenticationHeaderValue("Bearer", Environment.GetEnvironmentVariable("RDC_TOKEN"));
    request.Content = new StringContent("""
    {
      "operationId": "e68f5fae-0cec-430c-8b5c-9612dbb6d3cc",
      "expectedRevision": 6
    }
    """, System.Text.Encoding.UTF8, "application/json");
    var response = await client.SendAsync(request);
    var result = await response.Content.ReadAsStringAsync();

    Response 202

    JSON

    {
      "operationId": "e68f5fae-0cec-430c-8b5c-9612dbb6d3cc",
      "status": "accepted",
      "aggregateRevision": 7
    }

    Hand over to the carrier

    POST /warehouse/v1/shipments/{shipmentId}/dispatch

    Records that the carrier took the shipment: its units leave the stock of the warehouse.

    Parameters

    NameInTypeRequiredMeaning
    shipmentId path string (uuid) Yesrequired The shipment.

    Request body

    FieldTypeRequiredMeaning
    operationId string (uuid) Yesrequired A UUID you choose for this change. Send it again to repeat the request.
    expectedRevision integer Yesrequired The revision of the shipment you read.

    Responses

    StatusMeaningBody
    202 The change was accepted. The body is the operation result. OperationResult
    400 The request cannot be read or breaks the contract: malformed JSON, a missing or unknown field, a wrong type. fields names each one. Error
    401 The token is missing, not valid or has ended. Error
    403 The token does not give access to this company or operation. Error
    404 The request was refused. The code is shipment_not_found. Error
    409 The request was refused. The code is revision_conflict or operation_reused. Error
    422 The request was refused. The code is label_missing or already_dispatched. Error
    429 The request was refused. The code is rate_limited. Error
    503 The request was refused. The code is unavailable. Error

    Request

    curl

    curl -X POST "$RDC_BASE_URL/warehouse/v1/shipments/a4000000-0000-4000-8000-000000001043/dispatch" \
      -H "Authorization: Bearer $RDC_TOKEN" \
      -H "Content-Type: application/json" \
      -d '{
      "operationId": "49300b83-cd9d-4491-8cd1-64dda778fda1",
      "expectedRevision": 7
    }'

    JavaScript

    const response = await fetch(`${process.env.RDC_BASE_URL}/warehouse/v1/shipments/a4000000-0000-4000-8000-000000001043/dispatch`, {
      method: 'POST',
      headers: {
        Authorization: `Bearer ${process.env.RDC_TOKEN}`,
        'Content-Type': 'application/json',
      },
      body: JSON.stringify({
        "operationId": "49300b83-cd9d-4491-8cd1-64dda778fda1",
        "expectedRevision": 7
      }),
    });
    const result = await response.json();

    Python

    import os
    import requests
    
    response = requests.request(
        'POST',
        f'{os.environ["RDC_BASE_URL"]}/warehouse/v1/shipments/a4000000-0000-4000-8000-000000001043/dispatch',
        headers={
            'Authorization': f'Bearer {os.environ["RDC_TOKEN"]}',
        },
        json={
            'operationId': '49300b83-cd9d-4491-8cd1-64dda778fda1',
            'expectedRevision': 7,
        },
    )
    result = response.json()

    PHP

    <?php
    
    $body = <<<'JSON'
    {
      "operationId": "49300b83-cd9d-4491-8cd1-64dda778fda1",
      "expectedRevision": 7
    }
    JSON;
    
    $curl = curl_init(getenv('RDC_BASE_URL') . '/warehouse/v1/shipments/a4000000-0000-4000-8000-000000001043/dispatch');
    curl_setopt_array($curl, [
        CURLOPT_CUSTOMREQUEST => 'POST',
        CURLOPT_RETURNTRANSFER => true,
        CURLOPT_HTTPHEADER => [
            'Authorization: Bearer ' . getenv('RDC_TOKEN'),
            'Content-Type: application/json',
        ],
        CURLOPT_POSTFIELDS => $body,
    ]);
    $result = json_decode(curl_exec($curl), true);
    curl_close($curl);

    C#

    using System.Net.Http.Headers;
    
    var client = new HttpClient();
    var request = new HttpRequestMessage(HttpMethod.Post, $"{Environment.GetEnvironmentVariable("RDC_BASE_URL")}/warehouse/v1/shipments/a4000000-0000-4000-8000-000000001043/dispatch");
    request.Headers.Authorization = new AuthenticationHeaderValue("Bearer", Environment.GetEnvironmentVariable("RDC_TOKEN"));
    request.Content = new StringContent("""
    {
      "operationId": "49300b83-cd9d-4491-8cd1-64dda778fda1",
      "expectedRevision": 7
    }
    """, System.Text.Encoding.UTF8, "application/json");
    var response = await client.SendAsync(request);
    var result = await response.Content.ReadAsStringAsync();

    Response 202

    JSON

    {
      "operationId": "49300b83-cd9d-4491-8cd1-64dda778fda1",
      "status": "accepted",
      "aggregateRevision": 8
    }