Next Commerce

products

Query for products

Arguments

pks·[ID]listscalar
ids·[ID]listscalar
offset·Intscalar
before·Stringscalar
after·Stringscalar
first·Intscalar
last·Intscalar
pk·Intscalar

PK

title·Stringscalar

Title

Returns

ProductNodeConnectionobject
pageInfo·PageInfo!non-nullobject

Pagination data for this connection.

edges·[ProductNodeEdge]!non-nulllistobject

Contains the nodes in this connection.

Query Reference
query Products($pks: [ID], $ids: [ID], $offset: Int, $before: String, $after: String, $first: Int, $last: Int, $pk: Int, $title: String) {
  products(pks: $pks, ids: $ids, offset: $offset, before: $before, after: $after, first: $first, last: $last, pk: $pk, title: $title)
}
Variables
{
  "pks": [
    "<id>"
  ],
  "ids": [
    "<id>"
  ],
  "offset": 1,
  "before": "<your-value>",
  "after": "<your-value>",
  "first": 1,
  "last": 1,
  "pk": 1,
  "title": "<your-value>"
}
JSON Response
{
  "data": {
    "products": {
      "pageInfo": {
        "hasNextPage": true,
        "hasPreviousPage": true,
        "startCursor": "<your-value>",
        "endCursor": "<your-value>"
      },
      "edges": [
        {
          "node": {
            "isPublic": true,
            "parent": null,
            "slug": "<your-value>",
            "description": "<your-value>",
            "metaTitle": "<your-value>",
            "metaDescription": "<your-value>",
            "recommendedProducts": null,
            "rating": 1,
            "dateCreated": "2026-01-01T00:00:00Z",
            "dateUpdated": "2026-01-01T00:00:00Z",
            "isDiscountable": true,
            "title": "<your-value>",
            "excerpt": "<your-value>",
            "upc": "<your-value>",
            "structure": "<your-value>",
            "ranking": 1,
            "attributes": [
              {
                "name": "...",
                "code": "...",
                "pk": "...",
                "type": "...",
                "values": "..."
              }
            ],
            "variantAttributes": [
              {
                "name": "...",
                "code": "...",
                "values": "..."
              }
            ],
            "images": [
              {
                "id": "...",
                "url": "..."
              }
            ],
            "children": [
              {
                "isPublic": "...",
                "parent": "...",
                "slug": "...",
                "description": "...",
                "metaTitle": "...",
                "metaDescription": "...",
                "recommendedProducts": "...",
                "rating": "...",
                "dateCreated": "...",
                "dateUpdated": "...",
                "isDiscountable": "...",
                "title": "...",
                "excerpt": "...",
                "upc": "...",
                "structure": "...",
                "ranking": "...",
                "id": "...",
                "pk": "...",
                "requiresShipping": "...",
                "purchaseInfo": "...",
                "images": "...",
                "primaryImage": "...",
                "subscriptionInfo": "...",
                "url": "...",
                "metadata": "...",
                "variantAttributeValues": "..."
              }
            ],
            "id": "<id>",
            "pk": 1,
            "requiresShipping": true,
            "purchaseInfo": {
              "availableForSale": "...",
              "availability": "...",
              "price": "...",
              "priceRetail": "...",
              "priceSubscription": "...",
              "sku": "..."
            },
            "primaryImage": {
              "id": "...",
              "url": "..."
            },
            "subscriptionInfo": {
              "interval": "...",
              "intervalCount": "..."
            },
            "url": "<your-value>",
            "metadata": {}
          },
          "cursor": "<your-value>"
        }
      ]
    }
  }
}