---
title: "Creates a new shipment from the submitted data."
method: POST
path: "/rest/api/shipping/shipment/"
tags: ["Shipment"]
---

# Creates a new shipment from the submitted data.

`POST /rest/api/shipping/shipment/`

## Request body

- NewShipmentDTO
  - `carrierAccountId` integer, nullable — Carrier account ID
  - `addressReceiver` union
    - object
      - `type` 'house' | 'company' | 'parcel', nullable — Address type ('house')
      - `name` string, nullable — Recipient's name
      - `streetName` string, nullable — Street name
      - `streetNumber` string, nullable — Street number
      - `zipCode` string, nullable — Zip code
      - `city` string, nullable — City
      - `country` string, nullable — Country
      - `phone` string, nullable — Phone
      - `email` string, nullable — Email
    - object
      - `type` 'house' | 'company' | 'parcel', nullable — Address type ('company')
      - `name2` string, nullable — Continuation of company name (optional).
      - `taxNumber` string, nullable — Tax Identification Number (NIP in Poland).
      - `name` string, nullable — Recipient's name
      - `streetName` string, nullable — Street name
      - `streetNumber` string, nullable — Street number
      - `zipCode` string, nullable — Zip code
      - `city` string, nullable — City
      - `country` string, nullable — Country
      - `phone` string, nullable — Phone
      - `email` string, nullable — Email
    - object
      - `type` 'house' | 'company' | 'parcel', nullable — Address type ('parcel')
      - `parcelName` string, nullable — Helpful description of parcel point.
      - `parcelIdExternal` string, nullable — Unique parcel ID.
      - `name` string, nullable — Recipient's name
      - `streetName` string, nullable — Street name
      - `streetNumber` string, nullable — Street number
      - `zipCode` string, nullable — Zip code
      - `city` string, nullable — City
      - `country` string, nullable — Country
      - `phone` string, nullable — Phone
      - `email` string, nullable — Email
  - `orderId` string, nullable — Order ID
  - `postDate` string, date-time, nullable — Post date
  - `method` string, nullable — Shipment methods can be downloaded from <a href='#tag/Shipment/operation/get_rest_shipment_carrier_sending_methods'>Get Carrier sending methods</a>.
  - `options` union[] — Options can be downloaded from <a href='#tag/Shipment/operation/get_rest_shipment_options'>Get list of shipment option need to create new shipment</a>.
    - union
      - RestShipmentOptionMoneyDTO
        - `id` string — Id of option
        - `type` string — Type
        - `value` RestShipmentOptionMoneyValueDTO
          - `amount` string — Amount
          - `currency` string — Currency
      - RestShipmentOptionBooleanDTO
        - `id` string — Id of option
        - `type` string — Type
        - `value` boolean — Value
      - RestShipmentOptionStringDTO
        - `id` string — Id of option
        - `type` string — Type
        - `value` string, nullable
      - RestShipmentOptionChoiceDTO
        - `id` string — Id of option
        - `type` string — Type
        - `value` RestShipmentOptionChoiceValueDTO[] — Value
          - `label` string — Label
          - `value` string — Value
      - RestShipmentOptionDimensionsDTO
        - `id` string — Id of option
        - `type` string — Type
        - `value` RestShipmentOptionsDimensionsValueDTO
          - `length` integer — Length
          - `width` integer — Width
      - RestShipmentOptionIntegerDTO
        - `id` string — Id of option
        - `type` string — Type
        - `value` integer, nullable
  - `parcels` RestShipmentParcelDTO[] — Options can be downloaded from <a href='#tag/Shipment/operation/get_rest_shipment_options'>Get list of shipment option need to create new shipment</a>.
    - `options` union[]
      - union
        - RestShipmentOptionMoneyDTO
          - `id` string — Id of option
          - `type` string — Type
          - `value` RestShipmentOptionMoneyValueDTO
            - `amount` string — Amount
            - `currency` string — Currency
        - RestShipmentOptionBooleanDTO
          - `id` string — Id of option
          - `type` string — Type
          - `value` boolean — Value
        - RestShipmentOptionStringDTO
          - `id` string — Id of option
          - `type` string — Type
          - `value` string, nullable
        - RestShipmentOptionChoiceDTO
          - `id` string — Id of option
          - `type` string — Type
          - `value` RestShipmentOptionChoiceValueDTO[] — Value
            - `label` string — Label
            - `value` string — Value
        - RestShipmentOptionDimensionsDTO
          - `id` string — Id of option
          - `type` string — Type
          - `value` RestShipmentOptionsDimensionsValueDTO
            - `length` integer — Length
            - `width` integer — Width
        - RestShipmentOptionIntegerDTO
          - `id` string — Id of option
          - `type` string — Type
          - `value` integer, nullable

## Response `200`

Returns list of identifiers for created shipments.

- NewShipmentsCreatedResponse
  - `shipments` NewShipmentCreatedDTO[] — List of newly created shipments Ids
    - `shipmentId` integer, required — Internal shipment ID

## Other responses

- `401` — Authorization failed
- `422` — Unprocessable Entity

---

[API](https://skmtc.dev/apilo/apis/apilo-rest-api.md) · [All operations](https://skmtc.dev/apilo/apis/apilo-rest-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/apilo/apilo-rest-api/revisions/a0f9dcdba6cc/schema)
