ecommerce

Add order

Add a new order to a store.

post/3.0/ecommerce/stores/{store_id}/orders

Request

Path parameters

store_idstring required

The store id.

Request body

campaign_idstring

A string that uniquely identifies the campaign for an order.

cancelled_at_foreignstring

The date and time the order was cancelled in ISO 8601 format. Note: passing a value for this parameter will cancel the order being created.

currency_codestring required

The three-letter ISO 4217 code for the currency that the store accepts.

financial_statusstring

The order status. Use this parameter to trigger Order Notifications.

fulfillment_statusstring

The fulfillment status for the order. Use this parameter to trigger Order Notifications.

landing_sitestring

The URL for the page where the buyer landed when entering the shop.

order_urlstring

The URL for the order.

processed_at_foreignstring

The date and time the order was processed in ISO 8601 format.

tracking_carrierstring

The tracking carrier associated with the order.

tracking_code'prec'

The Mailchimp tracking code for the order. Uses the 'mc_tc' parameter in E-Commerce tracking URLs.

tracking_numberstring

The tracking number associated with the order.

tracking_urlstring

The tracking URL associated with the order.

updated_at_foreignstring

The date and time the order was updated in ISO 8601 format.

Example request

{
  "billing_address": {
    "address1": "675 Ponce de Leon Ave NE",
    "address2": "Suite 5000",
    "city": "Atlanta",
    "country": "United States",
    "country_code": "US",
    "name": "Freddie Chimpenheimer",
    "phone": "8675309",
    "postal_code": "30308",
    "province": "Georgia",
    "province_code": "GA"
  },
  "campaign_id": "839488a60b",
  "cancelled_at_foreign": "2015-07-15T19:28:00+00:00",
  "customer": {
    "address": {
      "address1": "675 Ponce de Leon Ave NE",
      "address2": "Suite 5000",
      "city": "Atlanta",
      "country": "United States",
      "country_code": "US",
      "postal_code": "30308",
      "province": "Georgia",
      "province_code": "GA"
    }
  },
  "landing_site": "http://www.example.com?source=abc",
  "lines": [
    {
      "product": {
        "description": "This is a cat hat.",
        "handle": "cat-hat",
        "published_at_foreign": "2015-07-15T19:28:00+00:00",
        "title": "Cat Hat",
        "type": "Accessories",
        "variants": [
          {
            "title": "Cat Hat"
          }
        ]
      }
    }
  ],
  "outreach": {
    "id": "839488a60b"
  },
  "processed_at_foreign": "2015-07-15T19:28:00+00:00",
  "shipping_address": {
    "address1": "675 Ponce de Leon Ave NE",
    "address2": "Suite 5000",
    "city": "Atlanta",
    "country": "United States",
    "country_code": "US",
    "name": "Freddie Chimpenheimer",
    "phone": "8675309",
    "postal_code": "30308",
    "province": "Georgia",
    "province_code": "GA"
  },
  "updated_at_foreign": "2015-07-15T19:28:00+00:00"
}

Response

campaign_idstring

A string that uniquely identifies the campaign associated with an order.

cart_idstring

A cart id that the order was placed for.

cancelled_at_foreignstring date-time

The date and time the order was cancelled in ISO 8601 format.

currency_codestring

The three-letter ISO 4217 code for the currency that the store accepts.

discount_totalnumber

The total amount of the discounts to be applied to the price of the order.

financial_statusstring

The order status. Use this parameter to trigger Order Notifications.

fulfillment_statusstring

The fulfillment status for the order. Use this parameter to trigger Order Notifications.

idstring

A unique identifier for the order.

landing_sitestring

The URL for the page where the buyer landed when entering the shop.

order_urlstring

The URL for the order.

processed_at_foreignstring date-time

The date and time the order was processed in ISO 8601 format.

store_idstring

The unique identifier for the store.

tracking_carrierstring

The tracking carrier associated with the order.

tracking_code'prec'

The Mailchimp tracking code for the order. Uses the 'mc_tc' parameter in E-Commerce tracking URLs.

tracking_numberstring

The tracking number associated with the order.

tracking_urlstring

The tracking URL associated with the order.

updated_at_foreignstring date-time

The date and time the order was updated in ISO 8601 format.

Example response

{
  "billing_address": {
    "address1": "675 Ponce de Leon Ave NE",
    "address2": "Suite 5000",
    "city": "Atlanta",
    "country": "United States",
    "country_code": "US",
    "latitude": 45.427408,
    "longitude": -75.68903,
    "name": "Freddie Chimpenheimer",
    "phone": "8675309",
    "postal_code": "30308",
    "province": "Georgia",
    "province_code": "GA"
  },
  "campaign_id": "839488a60b",
  "cart_id": "cart-123",
  "cancelled_at_foreign": "2015-07-15T19:28:00+00:00",
  "customer": {
    "address": {
      "address1": "675 Ponce de Leon Ave NE",
      "address2": "Suite 5000",
      "city": "Atlanta",
      "country": "United States",
      "country_code": "US",
      "postal_code": "30308",
      "province": "Georgia",
      "province_code": "GA"
    },
    "created_at": "2015-07-15T19:28:00+00:00",
    "orders_count": 4,
    "updated_at": "2015-07-15T19:28:00+00:00"
  },
  "landing_site": "http://www.example.com?source=abc",
  "outreach": {
    "id": "839488a60b",
    "name": "Freddie's Jokes",
    "published_time": "2017-06-06T13:56:12+00:00",
    "type": "regular"
  },
  "processed_at_foreign": "2015-07-15T19:28:00+00:00",
  "shipping_address": {
    "address1": "675 Ponce de Leon Ave NE",
    "address2": "Suite 5000",
    "city": "Atlanta",
    "country": "United States",
    "country_code": "US",
    "latitude": 45.427408,
    "longitude": -75.68903,
    "name": "Freddie Chimpenheimer",
    "phone": "8675309",
    "postal_code": "30308",
    "province": "Georgia",
    "province_code": "GA"
  },
  "updated_at_foreign": "2015-07-15T19:28:00+00:00"
}

Changes

No recorded changes to this operation across all 1 revision of this API.