Master Data API - v2

Description

ATTENTION: This version isn’t compliant with data entities of old version (e.g. CL and AD). It’s possible to use this configuration only to new data entities.

Welcome!

VTEX Master Data is an easy-to-use, secure, fast, scalable and extensible repository. On it you can create your own Entities, store data and consult directly from the storefront or use it to store info for some external integration.

There are internal VTEX modules that use VTEX Master Data as data repository. We have the VTEX Customer Service, VTEX Profile System and VTEX InStore, for example. It is also used by other internal services.

There are two ways to use Master Data:

  1. Directly from the storefront
  2. External integration

Directly from the storefront

If your scenario is to be used inside the storefront, be aware of the following observations:

  1. Use the storefront host to query or store information to avoid CORS;
  2. Configure which information should be public and which shouldn’t, inside the JSON Schema of the Data Entity;
  3. Do not create query loops (the storefront may be affected with Throttling and apis may be turned off as a security protection);
  4. Never add via JS any type of authentication key (x-vtex-api-appkey or x-vtex-api-apptoken);

It’s important to avoid CORS using the relative path

External Integration

If your scenario is to perform external integration, such as migrating client data from another service, be aware of the following observations:

  1. Use the host {{accountName}}.vtexcommercestable.com.br;
  2. Use the authentication keys (x-vtex-api-appkey ou x-vtex-api-apptoken);

Most used attributes listed here

NameDescription
accountNameAccount name in VTEX License Manager
nameData Entity name
schemaJSON Schema of a Data Entity
idIdentifier of a document
x-vtex-api-appKeyUser key
x-vtex-api-appTokenUser token

Use this page to mock Master Data API - v2 in your testing and development.

Run our mock API sample using the open source WireMock library, or in the free edition of WireMock Cloud. You'll have a working API server simulating the behavior of Master Data API - v2, which will allow you to keep building and testing even if the actual API you isn't currently available.

Ready to accelerate your development flow

Shorter release cycles, more predictable schedules and fewer defects in production.
Start Mocking for Free *Free forever. No credit card needed