Switch the current order

post

/ccstore/v1/orders/current/switch/

Provides the ability to switch the current order context to another incomplete order from the list of saved orders for the current profile. The new order to switch to is specified in the request payload.

It also supports switching the current order context to a new empty cart order when no order ID is supplied.

Request

Supported Media Types
Body ()
The Json input containing the ID of the order to switch the context to.
Root Schema : switchCurrentOrder_request
Type: object
Show Source
Example:
{
    "orderId":"o60411"
}
Back to Top

Response

Supported Media Types

200 Response

Following model is returned when the switch order operation succeeds.
Body ()
Root Schema : switchCurrentOrder_response
Type: object
Show Source
Example Response (application/json)
{
    "orderId":"o14441"
}

Default Response

The following are the internal error codes thrown by this API when the request processing fails in Oracle Commerce Cloud:
Error CodeDescriptionPossible Fix
28107Order not found.Specify a valid order ID.
38432Unable to switch the order.Ensure that the order being switched to is pre-submitted.

The error response:
Body ()
Root Schema : errorModel
Type: object
Show Source
Nested Schema : errors
Type: array
An optional list of errors if multiple errors were encountered
Show Source
Nested Schema : items
Type: object
Show Source
Back to Top