younifyd
Menu

Create Product Main Image Relationships

Create main image relationships

POST/pcm/products/{productID}/relationships/main_image

Use it in a workflow

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

Request

Path parameters

productIDstringrequired

A unique identifier for the product.

Request body

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

dataobject
idstring

The ID of the image file.

typestring

This represents the type of resource being returned. Always `file`.

One offile

json
{
  "data": {
    "id": "00000000-0000-0000-0000-000000000000",
    "type": "file"
  }
}

Response

Returns 204 with a any. Read it in later steps with {{createProductMainImageRelationships.response.data.<field>}}.

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