latestOpenAPI 3.0.02026-08-1056429755.6 KB

a6efafc1669c

Manage Product (Asynchronous API)

Create a new individual or base product with variations

Create a new product asynchronously. You can create either an individual product or base product with variations.

post/v1/products

Request body

Example request

{
  "deploymentRequiredChanges": {
    "otherFulfillmentIntegration": {
      "fulfillerIds": [
        "digitalRiver"
      ]
    },
    "transferProduct": "2234567800",
    "upgradeProducts": [
      "3234567800"
    ],
    "downgradeProducts": [
      "4234567800"
    ]
  },
  "liveChanges": {
    "externalReferenceId": "sku-1234-5678-xyz",
    "catalogs": [
      {
        "catalogId": "123456000",
        "categories": [
          {
            "categoryId": "19000000"
          }
        ],
        "prices": [
          {
            "prices": [
              {
                "currency": "USD",
                "locale": "en_US",
                "configuredPrice": 15.99
              }
            ]
          }
        ]
      }
    ]
  },
  "localizations": [
    {
      "locale": "en_US"
    }
  ],
  "variations": [
    {
      "varyingAttributes": [
        {
          "attributeName": "fulfillmentType",
          "attributeValue": "Download"
        }
      ],
      "deploymentRequiredChanges": {
        "otherFulfillmentIntegration": {
          "fulfillerIds": [
            "digitalRiver"
          ]
        },
        "transferProduct": "2234567800",
        "upgradeProducts": [
          "3234567800"
        ],
        "downgradeProducts": [
          "4234567800"
        ]
      },
      "liveChanges": {
        "externalReferenceId": "sku-1234-5678-xyz",
        "catalogs": [
          {
            "catalogId": "123456000",
            "categories": [
              {
                "categoryId": "19000000"
              }
            ],
            "prices": [
              {
                "prices": [
                  {
                    "currency": "USD",
                    "locale": "en_US",
                    "configuredPrice": 15.99
                  }
                ]
              }
            ]
          }
        ]
      },
      "localizations": [
        {
          "locale": "en_US"
        }
      ]
    }
  ]
}

Response

Successful response.

taskIdstring

The task identifier received in the response when you create or update a product (synchronous API).

receivedTimestring

The date and time when Global Commerce received the task.

taskStatus'PUBLISHED' | 'PROCESSING' | 'COMPLETED' | 'FAILED'

The status of the task.

requestType'CREATE_PRODUCT' | 'CREATE_VARIATION' | 'UPDATE_PRODUCT' | 'UPDATE_VARIATION' | 'DELETE_VARIATION' | 'DELETE_LOCALE' | 'DEPLOY_PRODUCT' | 'RETIRE_PRODUCT' | 'UPDATE_PRODUCT_LIVE_CHANGE' | 'UPDATE_VARIATION_LIVE_CHANGE'

The request type for this task.

Example response

{
  "taskId": "d8a81162-aaaa-bbbb-cccc-ea513d1afa82",
  "receivedTime": "2022-05-01T23:00:21.123Z",
  "taskStatus": "PUBLISHED",
  "requestType": "CREATE_PRODUCT"
}