Skip to main content
POST
/
v1
/
attributes
Create Attributes
curl --request POST \
  --url https://api.wizcommerce.com/v1/attributes \
  --header 'Content-Type: application/json' \
  --header 'X-API-Key: <api-key>' \
  --data '{
  "entity": "customer",
  "name": "Customer Type",
  "data_type": "text",
  "configuration": {
    "default_value": "<any>",
    "options": [
      {
        "label": "Cotton",
        "value": "cotton"
      }
    ],
    "show_label": true
  },
  "priority": 1,
  "is_mandatory": true
}'
{
  "data": {
    "id": "01f5d171-d3e3-4b2b-bd57-0727194b5bed",
    "name": "Color",
    "entity": "customer",
    "data_type": "select",
    "options": [
      "Red",
      "Blue",
      "Green"
    ],
    "created_at": "2021-01-01T00:00:00Z",
    "updated_at": "2021-01-01T00:00:00Z"
  }
}

Authorizations

X-API-Key
string
header
required

API Key for authentication

Body

application/json

request

entity
enum<string>
required
Available options:
customer,
product,
address,
contact,
order
name
string
required
Example:

"Customer Type"

data_type
enum<string>
required
Available options:
text,
number,
percentage,
long_text,
date_only,
email,
checkbox,
file,
phone_e164,
select,
multi_select,
url,
html
Example:

"text"

configuration
object
priority
integer
Example:

1

is_mandatory
boolean
Example:

true

Response

Created

data
object