younifyd
Menu

Create Variation Option

Create a variation option

POST/pcm/variations/{variationID}/options

Use it in a workflow

  1. Add a step and choose the Elastic Path connector.
  2. Pick the Create Variation Option action (under PIM).
  3. Fill in the fields below, then reference the result from later steps as {{createVariationOption.response.data}}.

Request

Path parameters

variationIDstringrequired

A unique identifier for the variation.

Request body

Enter the body as JSON in the step's Body field.

dataobjectrequired
typestringrequired

This represents the type of resource object being returned. Always `product-variation-option`.

One ofproduct-variation-option

attributesobjectrequired3 fields
json
{
  "data": {
    "type": "product-variation-option",
    "attributes": {
      "name": "string",
      "description": "string",
      "sort_order": 0
    }
  }
}

Response

Returns 201 with an object. Read it in later steps with {{createVariationOption.response.data.<field>}}.

dataobject
idstring

A unique identifier that is generated when an option is created.

typestringrequired

This represents the type of resource object being returned. Always `product-variation-option`.

One ofproduct-variation-option

attributesobjectrequired3 fields
metaobject3 fields
json
{
  "data": {
    "type": "product-variation-option",
    "attributes": {
      "name": "string",
      "description": "string",
      "sort_order": 0
    },
    "id": "string",
    "meta": {
      "owner": "organization",
      "created_at": "2020-09-22T09:00:00.000Z",
      "updated_at": "2020-09-22T09:00:00.000Z"
    }
  }
}

Need more? See the Elastic Path guide for connection setup and behaviour shared by every action.