Class ByProjectKeyOrdersPostString

All Implemented Interfaces:
ConflictingTrait<ByProjectKeyOrdersPostString>, Deprecatable201Trait<ByProjectKeyOrdersPostString>, ErrorableTrait<ByProjectKeyOrdersPostString>, ExpandableTrait<ByProjectKeyOrdersPostString>, ClientRequestCommand<Order>, CreateHttpRequestCommand, HttpRequestCommand<Order>, RequestCommand<Order>

Before you create an Order, the Cart must have a shipping address set. The shipping address is used for tax calculation for a Cart with Platform TaxMode.

Creating an Order produces the OrderCreated Message.

Specific Error Codes:

  • OutOfStock
  • PriceChanged
  • DiscountCodeNonApplicable
  • ShippingMethodDoesNotMatchCart
  • InvalidItemShippingDetails
  • MatchingPriceNotFound
  • MissingTaxRateForCountry


   CompletableFuture<ApiHttpResponse<com.commercetools.api.models.order.Order>> result = apiRoot
            .withProjectKey("{projectKey}")
            .orders()
            .post("")
            .execute()