Master Data API - v2
vtex · Company
# 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. W
Authentication
Sample Requests
Returns the list of indices by data entity.
Hover any highlighted part to learn what it does
| Content-Type | application/json |
curl -X GET "https://api.apis.guru/v2/specs/vtex.local/Master-Data-API-/1.0/api/dataentities/{dataEntityName}/indices" \
-H "Content-Type: application/json"import requests
headers = {
"Content-Type": "application/json"
}
response = requests.get(
"https://api.apis.guru/v2/specs/vtex.local/Master-Data-API-/1.0/api/dataentities/{dataEntityName}/indices",
headers=headers,
)
print(response.json())const url = 'https://api.apis.guru/v2/specs/vtex.local/Master-Data-API-/1.0/api/dataentities/{dataEntityName}/indices';
const response = await fetch(url, {
headers: {
'Content-Type': 'application/json'
},
});
const data = await response.json();
console.log(data);package main
import (
"fmt"
"io"
"net/http"
)
func main() {
targetURL := "https://api.apis.guru/v2/specs/vtex.local/Master-Data-API-/1.0/api/dataentities/{dataEntityName}/indices"
req, _ := http.NewRequest("GET", targetURL, nil)
req.Header.Set("Content-Type", "application/json")
client := &http.Client{}
resp, _ := client.Do(req)
defer resp.Body.Close()
body, _ := io.ReadAll(resp.Body)
fmt.Println(string(body))
}require "net/http"
require "json"
uri = URI("https://api.apis.guru/v2/specs/vtex.local/Master-Data-API-/1.0/api/dataentities/{dataEntityName}/indices")
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = uri.scheme == "https"
req = Net::HTTP::Get.new(uri)
req["Content-Type"] = "application/json"
res = http.request(req)
puts JSON.parse(res.body)<?php
$url = "https://api.apis.guru/v2/specs/vtex.local/Master-Data-API-/1.0/api/dataentities/{dataEntityName}/indices";
$opts = ["http" => [
"method" => "GET",
"header" => implode("\r\n", [
"Content-Type: application/json"
]),
]];
$ctx = stream_context_create($opts);
$res = file_get_contents($url, false, $ctx);
print_r(json_decode($res, true));Return the schemas saved.
Hover any highlighted part to learn what it does
| Content-Type | application/json |
curl -X GET "https://api.apis.guru/v2/specs/vtex.local/Master-Data-API-/1.0/api/dataentities/{dataEntityName}/schemas" \
-H "Content-Type: application/json"import requests
headers = {
"Content-Type": "application/json"
}
response = requests.get(
"https://api.apis.guru/v2/specs/vtex.local/Master-Data-API-/1.0/api/dataentities/{dataEntityName}/schemas",
headers=headers,
)
print(response.json())const url = 'https://api.apis.guru/v2/specs/vtex.local/Master-Data-API-/1.0/api/dataentities/{dataEntityName}/schemas';
const response = await fetch(url, {
headers: {
'Content-Type': 'application/json'
},
});
const data = await response.json();
console.log(data);package main
import (
"fmt"
"io"
"net/http"
)
func main() {
targetURL := "https://api.apis.guru/v2/specs/vtex.local/Master-Data-API-/1.0/api/dataentities/{dataEntityName}/schemas"
req, _ := http.NewRequest("GET", targetURL, nil)
req.Header.Set("Content-Type", "application/json")
client := &http.Client{}
resp, _ := client.Do(req)
defer resp.Body.Close()
body, _ := io.ReadAll(resp.Body)
fmt.Println(string(body))
}require "net/http"
require "json"
uri = URI("https://api.apis.guru/v2/specs/vtex.local/Master-Data-API-/1.0/api/dataentities/{dataEntityName}/schemas")
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = uri.scheme == "https"
req = Net::HTTP::Get.new(uri)
req["Content-Type"] = "application/json"
res = http.request(req)
puts JSON.parse(res.body)<?php
$url = "https://api.apis.guru/v2/specs/vtex.local/Master-Data-API-/1.0/api/dataentities/{dataEntityName}/schemas";
$opts = ["http" => [
"method" => "GET",
"header" => implode("\r\n", [
"Content-Type: application/json"
]),
]];
$ctx = stream_context_create($opts);
$res = file_get_contents($url, false, $ctx);
print_r(json_decode($res, true));In the first request, the `X-VTEX-MD-TOKEN` token will be returned in the header. This token must be passed to the next request in the query string `_token` parameter. The token has a timeout of 10 minutes, which refreshes after each request. After the token is obtained it is no longer necessary
Hover any highlighted part to learn what it does
| Accept | application/json |
| REST-Range | resources=0-10 |
| Content-Type | application/json |
curl -X GET "https://api.apis.guru/v2/specs/vtex.local/Master-Data-API-/1.0/api/dataentities/{dataEntityName}/scroll?_sort=firstName%20ASC&_token=%7BtokenValueExample%7D&_where=firstName%20is%20not%20null.&_fields=email%2CfirstName%2Cdocument&_schema=schema&_keyword=String%20to%20search" \
-H "Accept: application/json" \
-H "REST-Range: resources=0-10" \
-H "Content-Type: application/json"import requests
params = {
"_sort": "firstName ASC",
"_token": "{tokenValueExample}",
"_where": "firstName is not null.",
"_fields": "email,firstName,document",
"_schema": "schema",
"_keyword": "String to search"
}
headers = {
"Accept": "application/json",
"REST-Range": "resources=0-10",
"Content-Type": "application/json"
}
response = requests.get(
"https://api.apis.guru/v2/specs/vtex.local/Master-Data-API-/1.0/api/dataentities/{dataEntityName}/scroll",
params=params,
headers=headers,
)
print(response.json())const url = new URL('https://api.apis.guru/v2/specs/vtex.local/Master-Data-API-/1.0/api/dataentities/{dataEntityName}/scroll');
url.searchParams.set('_sort', 'firstName ASC');
url.searchParams.set('_token', '{tokenValueExample}');
url.searchParams.set('_where', 'firstName is not null.');
url.searchParams.set('_fields', 'email,firstName,document');
url.searchParams.set('_schema', 'schema');
url.searchParams.set('_keyword', 'String to search');
const response = await fetch(url, {
headers: {
'Accept': 'application/json',
'REST-Range': 'resources=0-10',
'Content-Type': 'application/json'
},
});
const data = await response.json();
console.log(data);package main
import (
"fmt"
"io"
"net/http"
"net/url"
)
func main() {
baseURL, _ := url.Parse("https://api.apis.guru/v2/specs/vtex.local/Master-Data-API-/1.0/api/dataentities/{dataEntityName}/scroll")
q := baseURL.Query()
q.Set("_sort", "firstName ASC")
q.Set("_token", "{tokenValueExample}")
q.Set("_where", "firstName is not null.")
q.Set("_fields", "email,firstName,document")
q.Set("_schema", "schema")
q.Set("_keyword", "String to search")
baseURL.RawQuery = q.Encode()
targetURL := baseURL.String()
req, _ := http.NewRequest("GET", targetURL, nil)
req.Header.Set("Accept", "application/json")
req.Header.Set("REST-Range", "resources=0-10")
req.Header.Set("Content-Type", "application/json")
client := &http.Client{}
resp, _ := client.Do(req)
defer resp.Body.Close()
body, _ := io.ReadAll(resp.Body)
fmt.Println(string(body))
}require "net/http"
require "json"
uri = URI("https://api.apis.guru/v2/specs/vtex.local/Master-Data-API-/1.0/api/dataentities/{dataEntityName}/scroll")
uri.query = URI.encode_www_form({
"_sort" => "firstName ASC",
"_token" => "{tokenValueExample}",
"_where" => "firstName is not null.",
"_fields" => "email,firstName,document",
"_schema" => "schema",
"_keyword" => "String to search"
})
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = uri.scheme == "https"
req = Net::HTTP::Get.new(uri)
req["Accept"] = "application/json"
req["REST-Range"] = "resources=0-10"
req["Content-Type"] = "application/json"
res = http.request(req)
puts JSON.parse(res.body)<?php
$url = "https://api.apis.guru/v2/specs/vtex.local/Master-Data-API-/1.0/api/dataentities/{dataEntityName}/scroll?" . http_build_query([
"_sort" => "firstName ASC",
"_token" => "{tokenValueExample}",
"_where" => "firstName is not null.",
"_fields" => "email,firstName,document",
"_schema" => "schema",
"_keyword" => "String to search"
]);
$opts = ["http" => [
"method" => "GET",
"header" => implode("\r\n", [
"Accept: application/json",
"REST-Range: resources=0-10",
"Content-Type: application/json"
]),
]];
$ctx = stream_context_create($opts);
$res = file_get_contents($url, false, $ctx);
print_r(json_decode($res, true));Postman Setup Guide
- See official documentation for authentication and setup.
What can you build with Master Data API - v2?
Master Data API - v2 is a Company API. Developers commonly use company APIs for:
- enriching CRM records with company firmographics
- building lead-generation and prospecting tools
- verifying business identity and registration details
- monitoring competitors and market intelligence
- powering B2B data enrichment pipelines
No authentication required. This API is open — no signup or key needed. Ideal for quick prototypes and public-facing features. Master Data API - v2 is free to use, making it a low-risk choice to experiment with.
New to APIs? Read our beginner's guide · Learn about API keys · What is REST?