For AI agents: a documentation index is available at the root level at /llms.txt and /llms-full.txt. Append /llms.txt to any URL for a page-level index, or .md for the markdown version of any page.
Dev Portal
DocsAPI ReferenceLearnCommunityChangelog
DocsAPI ReferenceLearnCommunityChangelog
    • About Our APIs
  • REST
    • Overview
      • Overview
        • Brands
        • Categories
        • Category Trees
        • Products
        • Product Modifiers
            • GETList Product Modifiers
            • POSTCreate Product Modifier
            • GETGet Product Modifier
            • PUTUpdate Product Modifier
            • DELDelete Product Modifier
        • Product Variants
        • Product Variant Options
      • Payments
  • GraphQL
    • Overview
  • MCP
    • Overview
Dev Portal
LogoLogo
RESTAdminCatalogProduct Modifiers

Create Product Modifier

POST
https://api.bigcommerce.com/stores/:store_hash/v3/catalog/products/:product_id/modifiers
POST
/stores/:store_hash/v3/catalog/products/:product_id/modifiers
$curl -X POST https://api.bigcommerce.com/stores/store_hash/v3/catalog/products/1/modifiers \
> -H "Accept: application/json" \
> -H "X-Auth-Token: <apiKey>" \
> -H "Content-Type: application/json" \
> -d '{
> "type": "radio_buttons",
> "required": true,
> "display_name": "Donation",
> "sort_order": 0,
> "option_values": [
> {
> "adjusters": {
> "price": {
> "adjuster": "relative",
> "adjuster_value": 5
> },
> "weight": {
> "adjuster": "relative",
> "adjuster_value": 5
> },
> "purchasing_disabled": {
> "status": true,
> "message": "string"
> }
> },
> "is_default": false,
> "label": "+5",
> "sort_order": 0,
> "value_data": {}
> },
> {
> "adjusters": {
> "price": {
> "adjuster": "relative",
> "adjuster_value": 10
> },
> "weight": {
> "adjuster": "relative",
> "adjuster_value": 10
> },
> "purchasing_disabled": {
> "status": true,
> "message": "string"
> }
> },
> "is_default": false,
> "label": "+10",
> "sort_order": 0,
> "value_data": {}
> }
> ]
>}'
1{
2 "data": {
3 "required": true,
4 "type": "radio_buttons",
5 "config": {},
6 "display_name": "Test name",
7 "id": 164,
8 "name": "Test-name1716906851-161",
9 "option_values": [
10 {
11 "adjusters": {
12 "price": {
13 "adjuster": "relative",
14 "adjuster_value": 5
15 },
16 "weight": {
17 "adjuster": "relative",
18 "adjuster_value": 5
19 },
20 "image_url": "",
21 "purchasing_disabled": {
22 "status": true,
23 "message": "string"
24 }
25 },
26 "id": 199,
27 "is_default": false,
28 "label": "+5",
29 "option_id": 164,
30 "sort_order": 0,
31 "value_data": null
32 },
33 {
34 "adjusters": {
35 "price": {
36 "adjuster": "relative",
37 "adjuster_value": 10
38 },
39 "weight": {
40 "adjuster": "relative",
41 "adjuster_value": 10
42 },
43 "image_url": "",
44 "purchasing_disabled": {
45 "status": true,
46 "message": "string"
47 }
48 },
49 "id": 200,
50 "is_default": false,
51 "label": "+10",
52 "option_id": 164,
53 "sort_order": 0,
54 "value_data": null
55 }
56 ],
57 "product_id": 161,
58 "sort_order": 0
59 },
60 "meta": {}
61}
Creates a product modifier. **Notes** It takes two separate requests to create a new checkbox modifier with option values. Perform a request to create a modifier, then perform a second request to update option values. Date modifiers are required to be provided in [ISO-8601 ATOM](https://www.php.net/manual/en/class.datetimeinterface.php#datetimeinterface.constants.atom) format. Excluding them in a request will throw a server error. **Setting an option value image** `adjusters.image_url` is read-only on this endpoint. To attach or replace the image shown on the storefront for an option value, upload it via [Create Product Modifier Image](/developer/api-reference/rest/admin/catalog/product-modifiers/images/create-product-modifier-image). The upload binds the image to the value automatically; no follow-up call is needed.
Was this page helpful?
Previous

List Product Modifiers

Next

Get Product Modifier

Built with

Creates a product modifier.

Notes It takes two separate requests to create a new checkbox modifier with option values. Perform a request to create a modifier, then perform a second request to update option values.

Date modifiers are required to be provided in ISO-8601 ATOM format. Excluding them in a request will throw a server error.

Setting an option value image adjusters.image_url is read-only on this endpoint. To attach or replace the image shown on the storefront for an option value, upload it via Create Product Modifier Image. The upload binds the image to the value automatically; no follow-up call is needed.

Authentication

X-Auth-Tokenstring
### OAuth scopes | UI Name | Permission | Parameter | |:--------|:-----------|:----------| | Products | modify | `store_v2_products` | | Products | read-only | `store_v2_products_read_only` | ### Authentication header | Header | Argument | Description | |:-------|:---------|:------------| | `X-Auth-Token` | `access_token` | For more about API accounts that generate `access_token`s, see our [Guide to API Accounts](/developer/docs/overview/api-fundamentals/api-accounts#api-accounts). | ### Further reading For example requests and more information about authenticating BigCommerce APIs, see [Authentication and Example Requests](/developer/docs/overview/api-fundamentals/api-accounts#x-auth-token-header-example-requests). For more about BigCommerce OAuth scopes, see our [Guide to API Accounts](/developer/docs/overview/api-fundamentals/api-accounts#oauth-scopes). For a list of API status codes, see [API Status Codes](/developer/api-reference/rest/overview#rest-http-status-codes).

Path parameters

product_idintegerRequired
The ID of the product to which the resource belongs.
store_hashstringRequired
Permanent ID of the BigCommerce store.

Headers

AcceptstringRequiredDefaults to application/json
The [MIME type](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/MIME_types) of the response body.

Request

This endpoint expects an object.
typeenumRequired

BigCommerce API, which determines how it will display on the storefront. Acceptable values: date, checkbox, file, text, multi_line_text, numbers_only_text, radio_buttons, rectangles, dropdown, product_list, product_list_with_images, swatch. Required in a /POST.

requiredbooleanRequired

Whether or not this modifier is required at checkout. Required in a /POST.

display_namestringRequired
The name of the option shown on the storefront.
sort_orderintegerOptional
The order the modifiers display on the product detail page.
configobjectOptional

The values for option config can vary based on the Modifier created. See Configs to learn more about the type-specific config fields.

option_valueslist of objectsOptional

Contains information about the values for modifier types with options. Certain fields are not used for specific modifier types. See Option Values for more details.

Response

dataobject
Product modifier
metaobject
Response metadata.

Errors

409
Conflict Error
422
Unprocessable Entity Error

OAuth scopes

UI NamePermissionParameter
Productsmodifystore_v2_products
Productsread-onlystore_v2_products_read_only

Authentication header

HeaderArgumentDescription
X-Auth-Tokenaccess_tokenFor more about API accounts that generate access_tokens, see our Guide to API Accounts.

Further reading

For example requests and more information about authenticating BigCommerce APIs, see Authentication and Example Requests.

For more about BigCommerce OAuth scopes, see our Guide to API Accounts.

For a list of API status codes, see API Status Codes.

The MIME type of the response body.