Working with entity identifiers

Orders, products, product variants and collections already have their own IDs in the store's e-commerce platform. In Yotpo, each of them has two IDs:

  • external_id: the store's own ID for the order, product, variant or collection, as it appears in the platform. It can't be changed once the entity exists in Yotpo.
  • yotpo_id: the ID Yotpo assigns to the same entity when it's created.

Endpoints that work on a single entity, such as Retrieve product by ID or Update product, take the yotpo_id in the path. To get it from an external_id, call the list endpoint with the external_ids filter (up to 100 IDs, comma-separated and URL-encoded). The response includes each entity's yotpo_id.

Example: update a product you created

  1. Create the product with Create product, using your platform's product ID as external_id.
  2. Call Retrieve products with external_ids=YOUR_PRODUCT_ID and read yotpo_id from the product in the response.
  3. Update the product with Update product, passing that yotpo_id as yotpo_product_id in the path.

Example: from a platform product ID to Yotpo data

  1. Call Retrieve products with external_ids=YOUR_PRODUCT_ID.
  2. Read yotpo_id from the product in the response.
  3. Use it in the path of Retrieve product by ID or Retrieve product variants.

Orders work the same way: Retrieve orders with external_ids, then Retrieve order by ID with the yotpo_id. App partners call these endpoints on developers.yotpo.com; each reference page shows the partner URL.


Did this page help you?