eComm Carts

Native Store Only

Cart Object

{
  "id": "e40b1abb-af80-4a4e-b6f0-4746c0e8a90a",
  "mode": "LIVE",
  "status": "IN_PROGRESS",
  "language": "en",
  "email": "john.doe@example.org",
  "currency": "USD",
  "items": [
    {
      "id": "e40b1abb-af80-4a4e-b6f0-4746c0e8a90a",
      "added": "2023-02-01T18:24:26.700Z",
      "product_id": "string",
      "variation_id": "string",
      "external_product_id": "string",
      "external_variation_id": "string"
      "name": "My product name",
      "image": "https://example.org/image.jpg",
      "options": [
        {
          "name": "Color",
          "value": "Red"
        }
      ],
      "shippable": true,
      "quantity": 3,
      "unit_price": "25.35",
      "unit_weight": "20.16",
      "unit_dimensions": {
        "height": "20",
        "width": "30",
        "length": "30"
      },
      "discounts": [
        {
          "id": "e40b1abb-af80-4a4e-b6f0-4746c0e8a90a",
          "name": "My discount",
          "savings": "10.25",
          "type": "RATE"
        }
      ],
      "taxes": [
        {
          "name": "Federal tax",
          "rate": "0.15",
          "amount": "10.25"
        }
      ],
      "total": "75.96",
      "combined_weight": "60.48",
      "metadata": {}
    }
  ],
  "billing_address": {
    "first_name": "string",
    "last_name": "string",
    "full_name": "string",
    "address_1": "string",
    "address_2": "string",
    "street_number": "string",
    "street_name": "string",
    "city": "string",
    "sub_locality": "string",
    "region": "string",
    "country": "string",
    "postal_code": "string",
    "phone": "string"
  },
  "shipping_address": {
    "first_name": "string",
    "last_name": "string",
    "full_name": "string",
    "address_1": "string",
    "address_2": "string",
    "street_number": "string",
    "street_name": "string",
    "city": "string",
    "sub_locality": "string",
    "region": "string",
    "country": "string",
    "postal_code": "string",
    "phone": "string"
  },
  "shipping_method": {
    "name": "Express shipping",
    "cost": "12.45"
  },
  "shipping_instructions": "string",
  "discounts": [
    {
      "id": "e40b1abb-af80-4a4e-b6f0-4746c0e8a90a",
      "savings": "42.36",
      "name": "15OFF",
      "type": "RATE"
    }
  ],
  "taxes": [
    {
      "name": "Federal tax",
      "amount": "10.23",
      "rate": "0.15"
    }
  ],
  "subtotal": "10.54",
  "total": "10.54",
  "created": "2023-02-01T18:24:26.700Z",
  "updated": "2023-02-01T18:24:26.700Z",
  "user_agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (HTML, like Gecko) Chrome/105.0.0.0 Safari/537.36",
  "ip_address": "1.1.1.1",
  "metadata": "string"
}

Cart Items

Property
Type
Description

id

string

The unique identifier for this cart item. note: this is different from the product identifier

added

string

Datetime stamp of when this item was added to the cart.

product_id

string

The unique identifier for the product backing this cart item.

variation_id

string

The unique identifier for the product variation backing this cart item.

external_product_id

string

The external id of the product backing this cart item.

external_variation_id

string

The external id of the product variation backing this cart item.

name

string

The name of the product backing this cart item.

image

string

URL to an image of the product backing this cart item.

options

array

An array of options chosen by the cart owner for the product backing this cart item.

shippable

bool

Indicates if this item requires shipping.

quantity

integer

The number of this item, variation and option combination in the cart.

unit_price

string

The price per unit of this cart item.

unit_weight

float

The weight (in grams) per unit of this cart item.

unit_dimensions

object

The per unit height, weight and length (in cm) of this cart item.

discounts

array

An array of discounts for this cart item. This value applies across the entire quantity of the item.

taxes

array

An array of taxes for this cart item. This value applies across the entire quantity of the item.

total

string

The total amount for all units in this cart item.

combined_weight

string

The combined weight (in grams) of all the items in the cart.

metadata

object

Address

Property
Type
Description

first_name

string

First Name attached to the address.

last_name

string

Last Name attached to the address.

full_name

string

Full Name attached to the address.

address_1

string

The first line of the address.

address_2

string

The second line of the address.

street_number

string

The street number note: this may be part of the address_1 or address_2 values, but is available here as a separate value.

street_name

string

The street name note: this may be part of the address_1 or address_2 values, but is available here as a separate value.

city

string

Name of city attached to the address.

sub_locality

string

Sub-locality attached to the address (ex: county or district name).

region

string

Region attached to the address (ex. the state or province name).

country

string

Country attached to the address.

postal_code

string

Postal code attached to the address.

phone

string

Phone number of contact located at this address.

Shipping Method

Property
Type
Description

name

string

Name of the shipping method.

cost

string

Total cost for this shipping method.

Discounts

Property
Type
Description

id

string

The unique identifier for this discount.

name

string

Descriptive name of the discount.

savings

string

Total amount saved by this discount.

type

string

The type of discount. Will be one of RATE (percentage off of the initial price) or AMOUNT (fixed discount amount off the initial price)

Taxes

Property
Type
Description

name

string

Descriptive name of the tax.

amount

string

The total amount of this tax.

rate

float

The rate applied for this tax in decimal format (ex: .15 or .05).

Options

Property
Type
Description

name

string

Descriptive name of the option.

value

string

Value of the specified option.

List Carts

List Carts

GET https://api.duda.co/api/sites/multiscreen/{site_name}/ecommerce/carts

Path Parameters

Name
Type
Description

site_name*

string

The unique identifier of the target site.

Query Parameters

Name
Type
Description

status

string

One of IN_PROGRESS or ABANDONED

mode

string

One of LIVE or TEST

cursor

string

Valid cart id. This value will be used for cursor pagination to return all items in the sort order after this id.

limit

int32

Number of results to be returned

curl --request GET \
     --url https://api.duda.co/api/sites/multiscreen/site_name/ecommerce/carts \
     --header 'accept: application/json'

Get Cart

Get Cart

GET https://api.duda.co/api/sites/multiscreen/{site_name}/ecommerce/carts/{cart_id}

Path Parameters

Name
Type
Description

site_name*

string

The unique identifier for the target site

cart_id*

string

The unique identifier for the target site.

curl --request GET \
     --url https://api.duda.co/api/sites/multiscreen/site_name/ecommerce/carts/cart_id \
     --header 'accept: application/json'

Last updated

Was this helpful?