---
title: "Create order"
method: POST
path: "/orders"
tags: ["orders"]
---

# Create order

`POST /orders`

Submits a new order for processing, including essential details like delivery address, order identifier, and item positions.

## Request body

- OrderPost
  - `sellerId` integer, required — The seller id to which this order belongs.
  - `warehouseId` integer — The id of the warehouse where the order gets processed. A list of warehouse identifiers and names can be obtained by executing GET /warehouses
  - `orderIdentifier` string, required — A unique identifier to prevent duplicates of the same order in the system. It can be the id of the order in the shop system or another unique number
  - `orderReference` string, required — The orderReference is set from the customer to identify the order easily. Example: #DE38678
  - `hasInvoiceAddress` boolean — Optional value indicating whether the invoice address is provided. <br>By default the delivery address is used as invoice address.
  - `hasInvoiceData` boolean — Optional value indicating whether the invoice data is provided. <br>The invoice data includes currency and sales prices.
  - `deliveryAddress` OrderPostDeliveryAddress, required
    - `name` string — The first and lastname of the recipient. <br>Either name or company is required.
    - `company` string — Name of the company. <br>Either name or company is required.
    - `phone` string — Phone number.
    - `email` string — E-Mail address.
    - `street` string, required — Street (or Address Line 1). <br>This field should always be specified.
    - `street2` string — Street (or Address Line 2). <br>This field is optional.
    - `zip` string — ZIP Code. <br>The ZIP code is optional for some countries, but required for most.
    - `city` string, required — City.
    - `state` string — State. <br>This is not required for most countries, but required in some (eg: United States).
    - `countryIso2` string, required — Country Code.
    - `addressIdentifier` string — Optional identifier for a delivery address.
    - `additionalIdentifiers` OrderAddressAdditionalIdentifier[] — Optional additional identifiers for a delivery address.
      - `identifier` string — The specific identifier string (e.g., a GLN or store ID).
      - `type` string — The type of the identifier (e.g., 'GLN', 'SHOP_SPECIFIC').
    - `latitude` number, double — Latitude coordinate for the delivery address. Optional, used for location-based services.
    - `longitude` number, double — Longitude coordinate for the delivery address. Optional, Used for location-based services.
  - `invoiceAddress` OrderPostAddress
    - `name` string — The first and lastname of the recipient. <br>Either name or company is required.
    - `company` string — Name of the company. <br>Either name or company is required.
    - `phone` string — Phone number.
    - `email` string — E-Mail address.
    - `street` string, required — Street (or Address Line 1). <br>This field should always be specified.
    - `street2` string — Street (or Address Line 2). <br>This field is optional.
    - `zip` string — ZIP Code. <br>The ZIP code is optional for some countries, but required for most.
    - `city` string, required — City.
    - `state` string — State. <br>This is not required for most countries, but required in some (eg: United States).
    - `countryIso2` string, required — Country Code.
  - `orderDate` string, date-time — The date when the order was placed.
  - `currencyCode` string — The currency in which the order was placed.
  - `invoiceIds` string[]
  - `comment` string — Optional text which contains instructions for the fulfillment and is sent to the warehouse.
  - `positions` OrderPostPosition[], required — The content of the order.
    - `sku` string, required — The unique identifier of the article that was ordered.
    - `name` string, required — A descriptive name of the article that was ordered.
    - `quantity` integer, required — The quantity that was ordered.
    - `price` number — The price per piece including taxes. <br>Required if hasInvoiceData is set to true.
    - `lot` string — Optional value that means a batch, or a specific identified portion of a batch, having uniform character and quality within specified limits.
    - `expirationDate` string, date — Optional expiration date.
    - `location` string — Optional storage location.
    - `positionIdentifier` string — Optional position identifier which is set from the customer to this position
    - `productIdentifier` string — Optional product identifier which is set from the customer to this position
    - `customAttributes` object — Optional custom attributes for a position.
  - `earliestDeliveryDate` string, date — Optional date which indicates the earliest allowed date of delivery in ISO 8601 format. Example: 2021-01-10
  - `latestDeliveryDate` string, date — Optional date which indicates the latest allowed date of delivery in ISO 8601 format. Example: 2021-01-12
  - `transportInsuranceAmount` number — Optional amount which should get insured when booking the transport for this order in EUR.
  - `cashOnDeliveryAmount` number — Optional COD total amount parameter. If the amount is greater than 0, it will be processed as a COD shipment
  - `cashOnDeliveryCurrency` string — Optional COD currency.
  - `shippingMethodIdentifier` string — Optional identifier which indicates how the parcels should be transported. Example: UPSS
  - `shippingMethodName` string — Optional name which indicates how the parcels should be transported. Example: UPS Saver
  - `tags` string[] — Optional tags of this order
  - `trackingEnabled` boolean — Optional value setting whether to turn on/off tracking functionality for an order. Additional charges will apply when set to true.
  - `orderPriority` integer — Optional value to prioritize order.
  - `orderReference2` string — Optional value for additional orderReference Example: #DE38678
  - `customerPurchaseOrderNumber` string — Optional value which specifies reference code that is assigned to a purchase Example: PO-89225
  - `ssccLabel` boolean — Optional value setting whether to create ssccLabel or not based on customerPurchaseOrderNumber value.
  - `channelId` string — Optional value which specifies the channel ID of the master client of this order.
  - `channelName` string — Optional value which specifies the channel name of the master client of this order. Example: Obi E-Commerce
  - `attachments` OrderAttachmentPost[] — Optional attachments parameter
    - `filename` string — Name for the attachment. This name will be displayed in the attachments section for the given order
    - `printerType` 'LABEL_PRINTER' | 'DOCUMENT_PRINTER' | 'DOCUMENT_PRINTER_2_A6' | 'DOCUMENT_PRINTER_2_FOLIO', required — Printer type, which should be used for printing the document in the warehouse
    - `attachmentPlacement` 'INSIDE_PACKAGE' | 'OUTSIDE_PACKAGE', required — Where the attached document should be placed in regard to the parcel
    - `copyCount` integer, required — Number of times the attachment should be printed per shipment
    - `printingType` 'ORDER' | 'SHIPMENT' — If the attached document should be printed per order or per shipment
    - `fileKey` string — Identifier of the file to be attached.
    - `mimeType` string — Mime type of the file
  - `customAttributes` object — Optional value for custom attributes of order.

## Response `200`

Returns the result of the order creation attempt, including the newly assigned 'orderId' if successful, or status and error details if validation fails.

- OrderPostResult — Represents the outcome of an order creation request, indicating whether the operation was successful (status) and, if successful, providing the new orderId. It includes fields for error messages if the operation failed.
  - `status` string — Indicates the overall status of the order creation attempt. Typically "OK" on success, or an error status on failure.
  - `field` string — On failure, this field indicates the specific request field that caused the error (e.g., "deliveryAddress.countryIso2"). This field is null on success.
  - `message` string — A detailed, human-readable message describing the outcome of the operation. This may contain success confirmation or a specific error explanation.
  - `orderId` integer — The unique internal ID assigned to the new order upon successful creation. This field is null on failure.

---

[API](https://skmtc.net/writechoiceorg/apis/connector.md) · [All operations](https://skmtc.net/writechoiceorg/apis/connector/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/writechoiceorg/connector/versions/7ce09a4b2a4e/schema)
