OrganizationId is read automatically from your JWT claims.
Create a cart
Create a new shopping cart for a customer. Nymble Commerce also adds the first item to the cart in this call, so you supply the initial SKU and quantity alongside theCustomerNumber.
Path parameters
The customer account number to create the cart for.
Body parameters
The customer account number (must match the path parameter).
SKU of the first product to add to the cart.
Quantity of the first product to add.
The type of order this cart represents, e.g.
Standard, Quote.Response
Returns the newly created cart object including the first line item.If an active cart already exists for this customer, the API returns a
400 error. Nymble Commerce enforces one active cart per customer. Retrieve the existing cart using Get carts for a customer and add items to it instead.Example
Get a cart by ID
Retrieve a specific cart by its ID, including all line items and computed totals.Path parameters
The unique identifier of the cart to retrieve.
Response
Returns a single cart object.Example
Get carts for a customer
Retrieve all active carts belonging to a specific customer.Path parameters
The customer account number to look up carts for.
Response
Returns an array of cart objects for the customer.Example
List all carts
Retrieve a paginated list of all carts in your organization. This is an admin-only endpoint useful for monitoring order activity across all customers.Query parameters
The page of results to return.
Number of carts per page.
Field to sort on. Common values:
CompanyName, CustomerNumber, Status.Sort direction. Accepts
asc or desc.Optional filter objects. Can filter on
CustomerNumber, CompanyName, or Status. Supported operators: startswith, contains, notcontains, endswith, equals, notequals.Response
Returns a paginated result containing an array of cart objects.Example
Update a cart
Update metadata on an existing cart, such as the order type or special instructions.Path parameters
The customer account number.
The cart ID to update.
Body parameters
The updated cart object. Include only the fields you want to change.
Example
Add an item to a cart
Add a product to an existing cart by SKU. If the SKU is already in the cart, Nymble Commerce increases that line item’s quantity rather than adding a duplicate line.Path parameters
The customer account number.
The cart to add the item to.
Body parameters
The SKU of the product to add.
The number of units to add.
The customer account number (must match the path parameter).
Response
Returns the updated cart object with the new item included.Example
Adding an item whose SKU is already in the cart increases the existing line item’s quantity. It does not create a second line for the same SKU.
Update an item in a cart
Change the quantity of an existing line item in the cart. The SKU is specified as a path parameter.Path parameters
The customer account number.
The cart containing the item.
The SKU of the line item to update.
Body parameters
The new quantity for this line item. Set to
0 to remove the item from the cart.The customer account number.
Response
Returns the updated cart object.Example
Remove an item from a cart
Delete a line item from the cart by SKU.Path parameters
The customer account number.
The cart to remove the item from.
The SKU of the line item to remove.
Response
Returns the updated cart object without the removed item.Example
Set shipping details
Attach or replace the shipping address for a cart.Path parameters
The customer account number.
The cart to update shipping on.
Body parameters
The shipping address to apply to this cart.
The customer account number.
Example
Set a PO number
Attach a customer purchase order number to the cart. This value is passed through to the order and invoice.Path parameters
The customer account number.
The cart to apply the PO number to.
Body parameters
The purchase order number from the customer, e.g.
PO-2024-88412.The customer account number.
Example
Complete checkout
Submit the cart for processing. Nymble Commerce validates the cart, creates an order, and returns an order number and confirmation ID. After a successful checkout the cart status is set toCLOSED and can no longer be modified.
Path parameters
The customer account number.
The cart ID to check out.
Body parameters
The customer account number (must match the path parameter).
The sales channel for this order, e.g.
Web, Storefront, EDI.The ID of a saved payment profile to charge for this order.
Payment details for this order. Required if
paymentProfileId is not provided.Response
The assigned order number for the completed order, e.g.
MOM-00001.A unique confirmation identifier for this checkout. Use this to reference the order when contacting support.
Example
The cart object
Nymble Commerce’s unique identifier for this cart.
The organization this cart belongs to.
The customer account number.
The customer’s company name.
Current cart status.
PENDING while the cart is open; CLOSED after checkout.The type of order this cart represents, e.g.
Standard, Quote.The price tier applied to this cart, inherited from the customer’s account.
ISO 4217 currency code for this cart.
The customer purchase order number, if set.
Any special delivery or handling instructions.
Array of line item objects.
Sum of all line totals before shipping and taxes.
The shipping address set on this cart.
The billing address set on this cart.
ISO 8601 timestamp of when the cart was created.
ISO 8601 timestamp of the most recent update.