Ads · Product Catalogs

Create, update or delete products in bulk

Creates, updates or deletes products in bulk. Works with Meta Ads.

POSThttps://api.pozy.ai/v1/ads/catalogs/{catalogId}/products/batch
Facebook and InstagrambatchAdCatalogProducts

Guide: Product catalogs and catalog ads

Request

Send your API key as Authorization: Bearer pz_live_.... Read-only keys cannot call it. Keys with the ads resource group disabled get 403 resource_group_disabled. Authentication

Path parameters

NameTypeNotes
catalogIdrequiredstring

Request body

application/json, required

  • accountIdstringrequired
  • catalogAccountIdstring
  • requestsarray of objectrequired

    At least 1 item. Up to 5000 items.

    • methodstringrequired

      One of CREATE, UPDATE, DELETE.

    • productobjectrequired
      31 child fields
      • retailerIdstringrequired

        Up to 100 characters.

      • namestring

        Up to 200 characters.

      • descriptionstring

        Up to 9999 characters.

      • urlstring (URL)
      • imageUrlstring (URL)
      • additionalImageUrlsarray of string (URL)

        Up to 20 items.

      • pricenumber
      • currencystring
      • salePricenumber
      • salePriceStartDatestring
      • salePriceEndDatestring
      • availabilitystring

        One of in stock, out of stock, preorder, available for order, discontinued, pending.

      • conditionstring

        One of new, refurbished, used.

      • brandstring

        Up to 100 characters.

      • categorystring

        Up to 250 characters.

      • googleProductCategorystring

        Up to 250 characters.

      • productTypestring

        Up to 750 characters.

      • gtinstring

        Up to 50 characters.

      • mpnstring

        Up to 100 characters.

      • inventoryinteger

        At least 0.

      • visibilitystring

        One of published, staging.

      • colorstring

        Up to 200 characters.

      • sizestring

        Up to 200 characters.

      • genderstring

        One of female, male, unisex.

      • materialstring

        Up to 200 characters.

      • patternstring

        Up to 100 characters.

      • customLabel0string

        Up to 100 characters.

      • customLabel1string

        Up to 100 characters.

      • customLabel2string

        Up to 100 characters.

      • customLabel3string

        Up to 100 characters.

      • customLabel4string

        Up to 100 characters.

Example

curl -X POST "https://api.pozy.ai/v1/ads/catalogs/6f2f2ffcf4ace3659342c4c2/products/batch" \
  -H "Authorization: Bearer $POZY_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "accountId": "696e0b682d0a31188e7a2ba9",
  "requests": [
    {
      "method": "CREATE",
      "product": {
        "retailerId": "62ed28b157a658d89f9173aa"
      }
    }
  ]
}'

Response

202 on success

  • handlesarray of string
  • statusUrlstring
202 response
{
  "handles": [
    "acme"
  ],
  "statusUrl": "https://pozy.ai/media/example-1.jpg"
}

Errors

Errors use one shape: { error, type, code, param?, details? }. The ones you are most likely to see here:

400invalid_request_errorA parameter or body field is missing or invalid. param names it.
401authentication_errorThe API key is missing, revoked or expired.
403permission_errorThe key is read-only, scoped to other profiles, or has this resource group disabled.
404not_foundNothing with that id exists in your workspace.
429rate_limit_errorToo many requests this minute. Wait for Retry-After seconds.

Every code is listed in Errors.

More in Product Catalogs