Shopping

Get Shopping Lists

GET /shoppinglists

Request

Get all shopping lists. Equivalent Storefront GraphQL API Query: shoppingLists. For more information, see the GraphQL Playground.

Authentication

  • Authorization in header in the format of Bearer {{token}}

Parameters

  • offset in query with default of 0 - string
    Pagination offset
  • limit in query with default of 20 - string
    Pagination limit
  • isShowAll in query with default of 1 - string
    If show all
  • orderBy in query with default of -created_at - string
    Order by

example

Response

OK

Body

object | application/json
  • code
    number
    required

  • message
    string
    required

    >= 1 characters
  • data
    object
    required

example-1

Create Shopping List

POST /shoppinglists

Request

Create a shopping list. Equivalent Storefront GraphQL API Mutation: shoppingListsCreate. For more information, see the GraphQL Playground.

Authentication

  • Authorization in header in the format of Bearer {{token}}

Body

object | application/json
  • name
    string
    required

    >= 1 characters
  • description
    string
    required

    >= 1 characters
  • status
    string
    required

    0: Approved 20: Deleted 30: Draft 40: Ready for approval

    Allowed: 0 | 20 | 30 | 40

    >= 1 characters

Response

OK

Body

object | application/json
  • code
    number
    required

  • message
    string
    required

    >= 1 characters
  • data
    object
    required

example-1

Update Shopping List

PUT /shoppinglists

Request

Update a shopping list. Equivalent Storefront GraphQL API Mutation: shoppingListsUpdate. For more information, see the GraphQL Playground.

Authentication

  • Authorization in header in the format of Bearer {{token}}

Body

object | application/json
  • name
    string
    required

    Shopping list name
    >= 1 characters
  • description
    string
    required

    Description of this shopping list
    >= 1 characters
  • status
    number
    required

    0: Approved 20: Deleted 30: Draft 40: Ready for approval

  • id
    string
    required

    Shopping list’s ID
    >= 1 characters

example

Response

OK

Body

object | application/json
  • code
    number
    required

  • message
    string
    required

    >= 1 characters
  • data
    object
    required

example-1

Get Shopping List ID and Name

GET /shoppinglists/lists

Request

This endpoint is deprecated.

Get all the shopping lists that contains both ID and name.

Authentication

  • Authorization in header in the format of Bearer {{token}}

Parameters

  • status in query - string
    0:Approved 20:Deleted 30:Draft 40:Ready for approval

example

Response

OK

Body

object | application/json
  • code
    number
    required

  • message
    string
    required

    >= 1 characters
  • data
    object
    required

example-1

Add shopping List Items

POST /shoppinglists/items

Request

Add items to an existed shopping list. Equivalent Storefront GraphQL API Mutation: shoppingListsItemsCreate. For more information, see the GraphQL Playground.

Authentication

  • Authorization in header in the format of Bearer {{token}}

Body

object | application/json
  • id
    string
    required

    Shopping list ID
    >= 1 characters
  • items
    array[object]
    required

example-1

Response

OK

Body

object | application/json
  • code
    number
    required

  • message
    string
    required

    >= 1 characters
  • data
    object
    required

example-1

Update Shopping List Items

PUT /shoppinglists/items

Request

Update shopping lists items. Equivalent Storefront GraphQL API Mutation: shoppingListsItemsUpdate. For more information, see the GraphQL Playground.

Authentication

  • Authorization in header in the format of Bearer {{token}}

Body

object | application/json
  • shoppinglistId
    string
    required

    Shopping list ID field
    >= 1 characters
  • itemId
    string
    required

    Shopping list item ID field
    >= 1 characters
  • qty
    string
    required

    Quantity of product in shopping list
    >= 1 characters
  • optionList
    array[object]
    required

    Product option of shopping list item
  • variantId
    string
    required

    Product SKU ID
    >= 1 characters
  • sortOrder
    integer

    The sort order for item

example

Response

OK

Body

object | application/json
  • code
    number
    required

  • message
    string
    required

    >= 1 characters
  • data
    object
    required

example-1

Get Shopping List Items Extension

GET /shoppinglists/items-extension

Request

Get a shopping list detail information. Equivalent Storefront GraphQL API Query: shoppingList. For more information, see the GraphQL Playground.

Authentication

  • Authorization in header in the format of Bearer {{token}}

Parameters

  • id in query - string
    Shopping list ID
  • offset in query with default of 0 - string
    Pagination offset
  • limit in query with default of 100 - string
    Pagination limit
  • sortBy in query - string
    the field to sort by
    Example: sort_order

    Allowed: product_name | quantity | product_sku | updated_at | created_at | sort_order

example

Response

OK

Body

object | application/json
  • code
    number
    required

  • message
    string
    required

    >= 1 characters
  • data
    object
    required

example-1

Delete Shopping List Item

DELETE /shoppinglists/{shoppingListId}/items/{itemId}

Request

Delete shopping list item using shoppingListId and itemId. Equivalent Storefront GraphQL API Mutation: shoppingListsItemsDelete. For more information, see the GraphQL Playground.

Authentication

  • Authorization in header in the format of Bearer {{token}}

Parameters

  • shoppingListId in path - string
    required
    Shopping list ID
  • itemId in path - string
    required
    Item id

example

Response

OK

Body

object | application/json
  • code
    number
    required

  • message
    string
    required

    >= 1 characters
  • data
    object
    required

example-1

Delete Shopping List

DELETE /shoppinglists/{shoppingListId}

Request

Delete a shopping list. Equivalent Storefront GraphQL API Mutation: shoppingListsDelete. For more information, see the GraphQL Playground.

Authentication

  • Authorization in header in the format of Bearer {{token}}

Parameters

  • shoppingListId in path - string
    required
    Shopping list ID

example

Response

OK

Body

object | application/json
  • code
    number
    required

  • message
    string
    required

    >= 1 characters
  • data
    object
    required

example-1

Duplicate a Shopping List

POST /shoppinglists/duplicate

Request

Duplicate a shopping list. Equivalent Storefront GraphQL API Mutation: shoppingListsDuplicate. For more information, see the GraphQL Playground.

Authentication

  • Authorization in header in the format of Bearer {{token}}

Body

object | application/json
  • sampleShoppingListId
    number
    required

  • name
    string
    required

    >= 1 characters
  • description
    string
    required

    >= 1 characters

Response

OK

Body

object | application/json
  • code
    number
    required

  • message
    string
    required

    >= 1 characters
  • data
    object
    required

example-1

Did you find what you were looking for?