SmakeSmake API Docs
EndpointsVariants

Show Variant

GET
/variants/{id}

Returns the product variant with the given id.

Expanding relationships

You can expand some resources to show more details — see Expanding Objects:

  • /variants/1?expand=product — show the content of the product instead of the id
  • /variants/1?expand=views.customizations.resource — show the content of the customizations' resource
AuthorizationBearer
AuthorizationBearer <token>

In: header

Path Parameters

id*integer

The ID of the variant.

Query Parameters

expand?string

You can expand some resources to show more details — see Expanding Objects. Several relations can be expanded as a comma-separated list. Allowed values:

  • product — You can show the content of the product instead of the id.
  • views.customizations.resource — You can show the content of the customizations' resource. The type is described by the resource_type attribute of the customization.
  • views.customizations.production_method — Show the production method of each customization.
  • views.customizations.resource.production_method — Show the production method of each customization resource.

Header Parameters

X-Api-Version?string

Response Body

application/json

application/json

application/json

Request example
curl -X GET "https://example.com/variants/1?expand=product%2Cviews.customizations.resource" \  -H "X-Api-Version: 2022-02-01"
{  "id": 1,  "state": "completed",  "collection_name": "catalogue",  "total": 215.86,  "price": 181.39,  "tax": 34.47,  "tax_rate": 19,  "option_values": [    {      "handle": "green",      "name": "green",      "option_type": {        "handle": "color",        "name": "Color"      }    },    {      "handle": "XS",      "name": "XS",      "option_type": {        "handle": "size",        "name": "Size"      }    }  ],  "origin": {    "sku": "production-variant-1",    "external_identifier": "master-product-1-green-XS"  },  "product": 1,  "views": [    {      "handle": "front",      "name": "Front View",      "media": [        {          "id": 348,          "is_test": 0,          "collection_name": "view-image",          "file_name": "view-image-front-green.png",          "size": 60652,          "mime_type": "image/png",          "download_url": "https://api.smake.io/storage/files/0a5257a02fa64b98ac4cccf1f784fdf6/view-image-front-green.png?expires=1775821218&signature=REDACTED",          "state": "pending",          "requested": null,          "failure_message": null,          "created_at": "2026-04-08T05:58:20+00:00",          "updated_at": "2026-04-08T05:58:20+00:00"        }      ],      "customizations": []    },    {      "handle": "back",      "name": "Rear View",      "media": [        {          "id": 349,          "is_test": 0,          "collection_name": "view-image",          "file_name": "view-image-back-green.png",          "size": 45669,          "mime_type": "image/png",          "download_url": "https://api.smake.io/storage/files/afb067e34e8f4efd9ac6e7bb4167ed3a/view-image-back-green.png?expires=1775821218&signature=REDACTED",          "state": "pending",          "requested": null,          "failure_message": null,          "created_at": "2026-04-08T05:58:20+00:00",          "updated_at": "2026-04-08T05:58:20+00:00"        }      ],      "customizations": []    },    {      "handle": "left",      "name": "Left View",      "media": [        {          "id": 350,          "is_test": 0,          "collection_name": "view-image",          "file_name": "view-image-left-green.png",          "size": 34119,          "mime_type": "image/png",          "download_url": "https://api.smake.io/storage/files/8f45899d654d41dc826f255fa7cfbd5f/view-image-left-green.png?expires=1775821218&signature=REDACTED",          "state": "pending",          "requested": null,          "failure_message": null,          "created_at": "2026-04-08T05:58:20+00:00",          "updated_at": "2026-04-08T05:58:20+00:00"        }      ],      "customizations": []    },    {      "handle": "right",      "name": "Right View",      "media": [        {          "id": 351,          "is_test": 0,          "collection_name": "view-image",          "file_name": "view-image-right-green.png",          "size": 34352,          "mime_type": "image/png",          "download_url": "https://api.smake.io/storage/files/e33393eff0c942bcb77b45b5408dae08/view-image-right-green.png?expires=1775821218&signature=REDACTED",          "state": "pending",          "requested": null,          "failure_message": null,          "created_at": "2026-04-08T05:58:20+00:00",          "updated_at": "2026-04-08T05:58:20+00:00"        }      ],      "customizations": []    }  ],  "failure_message": null,  "created_at": "2026-04-08T05:58:24+00:00",  "updated_at": "2026-04-08T05:58:24+00:00",  "designer": {    "designable_type": "app-variant",    "designable_id": 1,    "designable_identifier": "merchant-product-1-green-XS",    "type": "none",    "is_available": true,    "modes": {      "free": false,      "positioning": false,      "production": false    },    "only_customized_orderable": false  }}