Create cart
query Parameters
storefront_token | string Example: storefront_token=ptkn_xxxxxxxxxxxxxxxxxx |
currency | string Enum: "USD" "EUR" "CAD" "GBP" "AUD" "NZD" "SEK" "NOK" "DKK" "PLN" "INR" "JPY" "MYR" "SGD" "MXN" |
Request Body schema: application/jsonrequired
required | Array of objects (com.fourthwall.app.headless.HeadlessCart.RequestItem) | ||||
Array
|
Responses
Response Schema: application/json
id required | string | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
required | Array of objects (com.fourthwall.app.headless.model.CartV1.CartItemV1) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Array
|
Response Schema: */*
Request samples
- Payload
{- "items": [
- {
- "variantId": "000009c2-0c75-0024-0000-09c20c750024",
- "quantity": 1
}
]
}
Response samples
- 200
{- "id": "string",
- "items": [
- {
- "variant": {
- "id": "string",
- "name": "string",
- "sku": "string",
- "unitPrice": {
- "value": 10,
- "currency": "USD"
}, - "compareAtPrice": {
- "value": 10,
- "currency": "USD"
}, - "attributes": {
- "description": "Black, L",
- "color": {
- "name": "Black",
- "swatch": "#000000"
}, - "size": {
- "name": "L"
}
}, - "stock": {
- "type": "string",
- "inStock": 5
}, - "weight": {
- "value": 1,
- "unit": "kg"
}, - "dimensions": {
- "length": 1,
- "width": 2,
- "height": 3,
- "unit": "cm"
}, - "images": [
- {
- "id": "00aa4abd-5778-4199-8161-0b49b2f212e5",
- "width": 800,
- "height": 600,
}
], - "product": {
- "id": "string",
- "name": "string",
- "slug": "string"
}
}, - "quantity": 0
}
]
}
Remove from cart
path Parameters
cartId required | string |
query Parameters
storefront_token | string Example: storefront_token=ptkn_xxxxxxxxxxxxxxxxxx |
currency | string Enum: "USD" "EUR" "CAD" "GBP" "AUD" "NZD" "SEK" "NOK" "DKK" "PLN" "INR" "JPY" "MYR" "SGD" "MXN" |
Request Body schema: application/jsonrequired
required | Array of objects (com.fourthwall.cart.usecase.CartRemoveFromCart.RequestItem) non-empty | ||
Array (non-empty)
|
Responses
Response Schema: application/json
id required | string | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
required | Array of objects (com.fourthwall.app.headless.model.CartV1.CartItemV1) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Array
|
Response Schema: */*
Request samples
- Payload
{- "items": [
- {
- "variantId": "000009c2-0c75-0024-0000-09c20c750024"
}
]
}
Response samples
- 200
{- "id": "string",
- "items": [
- {
- "variant": {
- "id": "string",
- "name": "string",
- "sku": "string",
- "unitPrice": {
- "value": 10,
- "currency": "USD"
}, - "compareAtPrice": {
- "value": 10,
- "currency": "USD"
}, - "attributes": {
- "description": "Black, L",
- "color": {
- "name": "Black",
- "swatch": "#000000"
}, - "size": {
- "name": "L"
}
}, - "stock": {
- "type": "string",
- "inStock": 5
}, - "weight": {
- "value": 1,
- "unit": "kg"
}, - "dimensions": {
- "length": 1,
- "width": 2,
- "height": 3,
- "unit": "cm"
}, - "images": [
- {
- "id": "00aa4abd-5778-4199-8161-0b49b2f212e5",
- "width": 800,
- "height": 600,
}
], - "product": {
- "id": "string",
- "name": "string",
- "slug": "string"
}
}, - "quantity": 0
}
]
}
Change cart items quantity
path Parameters
cartId required | string |
query Parameters
storefront_token | string Example: storefront_token=ptkn_xxxxxxxxxxxxxxxxxx |
currency | string Enum: "USD" "EUR" "CAD" "GBP" "AUD" "NZD" "SEK" "NOK" "DKK" "PLN" "INR" "JPY" "MYR" "SGD" "MXN" |
Request Body schema: application/jsonrequired
required | Array of objects (com.fourthwall.cart.usecase.CartUpdateItemsQuantity.RequestItem) non-empty | ||||
Array (non-empty)
|
Responses
Response Schema: application/json
id required | string | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
required | Array of objects (com.fourthwall.app.headless.model.CartV1.CartItemV1) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Array
|
Response Schema: */*
Request samples
- Payload
{- "items": [
- {
- "variantId": "000009c2-0c75-0024-0000-09c20c750024",
- "quantity": 0
}
]
}
Response samples
- 200
{- "id": "string",
- "items": [
- {
- "variant": {
- "id": "string",
- "name": "string",
- "sku": "string",
- "unitPrice": {
- "value": 10,
- "currency": "USD"
}, - "compareAtPrice": {
- "value": 10,
- "currency": "USD"
}, - "attributes": {
- "description": "Black, L",
- "color": {
- "name": "Black",
- "swatch": "#000000"
}, - "size": {
- "name": "L"
}
}, - "stock": {
- "type": "string",
- "inStock": 5
}, - "weight": {
- "value": 1,
- "unit": "kg"
}, - "dimensions": {
- "length": 1,
- "width": 2,
- "height": 3,
- "unit": "cm"
}, - "images": [
- {
- "id": "00aa4abd-5778-4199-8161-0b49b2f212e5",
- "width": 800,
- "height": 600,
}
], - "product": {
- "id": "string",
- "name": "string",
- "slug": "string"
}
}, - "quantity": 0
}
]
}
Add to cart
path Parameters
cartId required | string |
query Parameters
storefront_token | string Example: storefront_token=ptkn_xxxxxxxxxxxxxxxxxx |
currency | string Enum: "USD" "EUR" "CAD" "GBP" "AUD" "NZD" "SEK" "NOK" "DKK" "PLN" "INR" "JPY" "MYR" "SGD" "MXN" |
Request Body schema: application/jsonrequired
required | Array of objects (com.fourthwall.cart.usecase.CartAdd.RequestItem) | ||||||
Array
|
Responses
Response Schema: application/json
id required | string | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
required | Array of objects (com.fourthwall.app.headless.model.CartV1.CartItemV1) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Array
|
Response Schema: */*
Request samples
- Payload
{- "items": [
- {
- "variantId": "000009c2-0c75-0024-0000-09c20c750024",
- "quantity": 1,
- "recStrategy": "string"
}
]
}
Response samples
- 200
{- "id": "string",
- "items": [
- {
- "variant": {
- "id": "string",
- "name": "string",
- "sku": "string",
- "unitPrice": {
- "value": 10,
- "currency": "USD"
}, - "compareAtPrice": {
- "value": 10,
- "currency": "USD"
}, - "attributes": {
- "description": "Black, L",
- "color": {
- "name": "Black",
- "swatch": "#000000"
}, - "size": {
- "name": "L"
}
}, - "stock": {
- "type": "string",
- "inStock": 5
}, - "weight": {
- "value": 1,
- "unit": "kg"
}, - "dimensions": {
- "length": 1,
- "width": 2,
- "height": 3,
- "unit": "cm"
}, - "images": [
- {
- "id": "00aa4abd-5778-4199-8161-0b49b2f212e5",
- "width": 800,
- "height": 600,
}
], - "product": {
- "id": "string",
- "name": "string",
- "slug": "string"
}
}, - "quantity": 0
}
]
}
Get cart by id
path Parameters
cartId required | string |
query Parameters
storefront_token | string Example: storefront_token=ptkn_xxxxxxxxxxxxxxxxxx |
currency | string Enum: "USD" "EUR" "CAD" "GBP" "AUD" "NZD" "SEK" "NOK" "DKK" "PLN" "INR" "JPY" "MYR" "SGD" "MXN" |
Responses
Response Schema: application/json
id required | string | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
required | Array of objects (com.fourthwall.app.headless.model.CartV1.CartItemV1) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Array
|
Response Schema: */*
Response samples
- 200
{- "id": "string",
- "items": [
- {
- "variant": {
- "id": "string",
- "name": "string",
- "sku": "string",
- "unitPrice": {
- "value": 10,
- "currency": "USD"
}, - "compareAtPrice": {
- "value": 10,
- "currency": "USD"
}, - "attributes": {
- "description": "Black, L",
- "color": {
- "name": "Black",
- "swatch": "#000000"
}, - "size": {
- "name": "L"
}
}, - "stock": {
- "type": "string",
- "inStock": 5
}, - "weight": {
- "value": 1,
- "unit": "kg"
}, - "dimensions": {
- "length": 1,
- "width": 2,
- "height": 3,
- "unit": "cm"
}, - "images": [
- {
- "id": "00aa4abd-5778-4199-8161-0b49b2f212e5",
- "width": 800,
- "height": 600,
}
], - "product": {
- "id": "string",
- "name": "string",
- "slug": "string"
}
}, - "quantity": 0
}
]
}
Get all collections
Returns all collections
query Parameters
storefront_token | string Example: storefront_token=ptkn_xxxxxxxxxxxxxxxxxx |
page | integer <int32> |
size | integer <int32> |
Responses
Response Schema: application/json
required | Array of objects (com.fourthwall.app.headless.model.CollectionPublicV1) | ||||||||||||
Array
| |||||||||||||
object (com.fourthwall.support.paging.PageResult) | |||||||||||||
|
Response Schema: */*
Response samples
- 200
{- "results": [
- {
- "id": "col_b1EVARkUTcCTSfspQaXr1Q",
- "name": "My collection",
- "slug": "my-collection",
- "description": "My collection description"
}
], - "paging": {
- "pageNumber": 0,
- "pageSize": 0,
- "elementsSize": 0,
- "elementsTotal": 0,
- "totalPages": 0,
- "hasNextPage": true
}
}
Get a collection
Returns a collection
path Parameters
slug required | string |
query Parameters
storefront_token | string Example: storefront_token=ptkn_xxxxxxxxxxxxxxxxxx |
Responses
Response Schema: application/json
id required | string |
name required | string |
slug required | string |
description required | string |
Response Schema: */*
Response samples
- 200
{- "id": "col_b1EVARkUTcCTSfspQaXr1Q",
- "name": "My collection",
- "slug": "my-collection",
- "description": "My collection description"
}
Get products (offers) in a collection
Returns all products in the collection
path Parameters
slug required | string |
query Parameters
storefront_token | string Example: storefront_token=ptkn_xxxxxxxxxxxxxxxxxx |
currency | string Enum: "USD" "EUR" "CAD" "GBP" "AUD" "NZD" "SEK" "NOK" "DKK" "PLN" "INR" "JPY" "MYR" "SGD" "MXN" |
page | integer <int32> |
size | integer <int32> |
Responses
Response Schema: application/json
required | Array of objects (com.fourthwall.app.headless.model.ProductV1) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Array
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
object (com.fourthwall.support.paging.PageResult) | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Response Schema: */*
Response samples
- 200
{- "results": [
- {
- "id": "string",
- "name": "string",
- "slug": "string",
- "description": "string",
- "state": {
- "type": "string"
}, - "access": {
- "type": "string"
}, - "images": [
- {
- "id": "00aa4abd-5778-4199-8161-0b49b2f212e5",
- "width": 800,
- "height": 600,
}
], - "variants": [
- {
- "id": "string",
- "name": "string",
- "sku": "string",
- "unitPrice": {
- "value": 10,
- "currency": "USD"
}, - "compareAtPrice": {
- "value": 10,
- "currency": "USD"
}, - "attributes": {
- "description": "Black, L",
- "color": {
- "name": "Black",
- "swatch": "#000000"
}, - "size": {
- "name": "L"
}
}, - "stock": {
- "type": "string",
- "inStock": 5
}, - "weight": {
- "value": 1,
- "unit": "kg"
}, - "dimensions": {
- "length": 1,
- "width": 2,
- "height": 3,
- "unit": "cm"
}, - "images": [
- {
- "id": "00aa4abd-5778-4199-8161-0b49b2f212e5",
- "width": 800,
- "height": 600,
}
]
}
], - "createdAt": "2020-08-13T09:05:36.939Z",
- "updatedAt": "2020-08-13T09:05:36.939Z"
}
], - "paging": {
- "pageNumber": 0,
- "pageSize": 0,
- "elementsSize": 0,
- "elementsTotal": 0,
- "totalPages": 0,
- "hasNextPage": true
}
}
Get a product by slug
path Parameters
slug required | string |
query Parameters
storefront_token | string Example: storefront_token=ptkn_xxxxxxxxxxxxxxxxxx |
currency | string Enum: "USD" "EUR" "CAD" "GBP" "AUD" "NZD" "SEK" "NOK" "DKK" "PLN" "INR" "JPY" "MYR" "SGD" "MXN" |
Responses
Response Schema: application/json
id required | string | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
name required | string | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
slug required | string | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
description required | string | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
required | com.fourthwall.openapi.model.OfferAbstractV1.OfferStateV1.Available (object) or com.fourthwall.openapi.model.OfferAbstractV1.OfferStateV1.SoldOut (object) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
One of
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
required | com.fourthwall.openapi.model.OfferAbstractV1.OfferAccessV1.Archived (object) or com.fourthwall.openapi.model.OfferAbstractV1.OfferAccessV1.Hidden (object) or com.fourthwall.openapi.model.OfferAbstractV1.OfferAccessV1.Public (object) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
One of
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
required | Array of objects (com.fourthwall.openapi.model.Image) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Array
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
required | Array of objects (com.fourthwall.app.headless.model.ProductVariantV1) | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Array
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
createdAt required | string <date-time> | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
updatedAt required | string <date-time> |
Response Schema: */*
Response samples
- 200
{- "id": "string",
- "name": "string",
- "slug": "string",
- "description": "string",
- "state": {
- "type": "string"
}, - "access": {
- "type": "string"
}, - "images": [
- {
- "id": "00aa4abd-5778-4199-8161-0b49b2f212e5",
- "width": 800,
- "height": 600,
}
], - "variants": [
- {
- "id": "string",
- "name": "string",
- "sku": "string",
- "unitPrice": {
- "value": 10,
- "currency": "USD"
}, - "compareAtPrice": {
- "value": 10,
- "currency": "USD"
}, - "attributes": {
- "description": "Black, L",
- "color": {
- "name": "Black",
- "swatch": "#000000"
}, - "size": {
- "name": "L"
}
}, - "stock": {
- "type": "string",
- "inStock": 5
}, - "weight": {
- "value": 1,
- "unit": "kg"
}, - "dimensions": {
- "length": 1,
- "width": 2,
- "height": 3,
- "unit": "cm"
}, - "images": [
- {
- "id": "00aa4abd-5778-4199-8161-0b49b2f212e5",
- "width": 800,
- "height": 600,
}
]
}
], - "createdAt": "2020-08-13T09:05:36.939Z",
- "updatedAt": "2020-08-13T09:05:36.939Z"
}