# Metadata

## Returns the public metadata of the entire Catalog model.

 - [GET /rest/Catalog/$metadata](https://docs.api.saleslayer.com/apis/catalog-v2.0/metadata/getmetadataasync.md): ## Authentication
            
Requires a valid API key in the X-API-KEY header.
            
## Response
            
200 OK — A JSON schema document describing every resource in the Catalog
(Category, Attribute Set, Product, Variant, Point of Sale) and the relationships
between them. Use this document to build requests against the rest of the API.
            
## Error Responses
            
- 401 Unauthorized — Missing or invalid API key.
- 403 Forbidden — Feature disabled for the tenant.
- 404 Not Found — Tenant or model not found.
- 500 Internal Server Error — Unexpected technical error.
            
## Example
            
Request:
http
GET /$metadata HTTP/1.1
X-API-KEY: your-api-key-here

            
Response:
http
HTTP/1.1 200 OK
Content-Type: application/json

## Returns the public metadata (JSON Schema) of the Category model.

 - [GET /rest/Catalog/Categories/$metadata](https://docs.api.saleslayer.com/apis/catalog-v2.0/metadata/getcategorymetadataasync.md): ## Authentication
            
Requires a valid API key in the X-API-KEY header.
            
## Description
            
The metadata is a JSON Schema document that describes:
- The implicit and custom properties exposed by the Category resource.
- The embedded resources (Products, Variants) and their relationships.
            
The schema should be consulted to build requests against the other Category endpoints
(which fields can be used in $select, $filter, $orderby, request bodies, etc.).
            
## Response
            
200 OK — Returns the JSON Schema as a ServiceDocumentRepresentation.
            
## Error Responses
            
- 401 Unauthorized — Missing or invalid API key.
- 403 Forbidden — Feature disabled for the tenant.
- 404 Not Found — Tenant or model not found.
- 500 Internal Server Error — Unexpected technical error.
            
## Example
            
Request:
http
GET /Categories/$metadata HTTP/1.1
X-API-KEY: your-api-key-here

            
Response:
http
HTTP/1.1 200 OK
Content-Type: application/json

## Returns the public JSON Schema describing a Custom Entity referenced by its denominator.

 - [GET /rest/Catalog/CustomEntities('{customEntityDenominator}')/$metadata](https://docs.api.saleslayer.com/apis/catalog-v2.0/metadata/getcustomentitymetadataasync.md): ## Authentication
            
Requires a valid API key in the X-API-KEY header.
            
## Description
            
The metadata is a JSON Schema document that describes the implicit and custom properties
exposed by the specified Custom Entity resource. The schema should be consulted to build
requests against the other Custom Entity endpoints (which fields can be used in $select,
$filter, $orderby, request bodies, etc.).
            
## Response
            
200 OK — Returns the JSON Schema as a ServiceDocumentRepresentation.
            
## Error Responses
            
- 401 Unauthorized — Missing or invalid API key.
- 403 Forbidden — Feature disabled for the tenant.
- 404 Not Found — Tenant or Custom Entity not found.
- 500 Internal Server Error — Unexpected technical error.
            
## Example
            
Request:
http
GET /CustomEntities('Brand')/$metadata HTTP/1.1
X-API-KEY: your-api-key-here

            
Response:
http
HTTP/1.1 200 OK
Content-Type: application/json

## Returns the public JSON Schema describing all available Custom Entities for the tenant.

 - [GET /rest/Catalog/CustomEntities/$metadata](https://docs.api.saleslayer.com/apis/catalog-v2.0/metadata/getcustomentitiesmetadataasync.md): ## Authentication
            
Requires a valid API key in the X-API-KEY header.
            
## Description
            
The metadata is a JSON Schema document that lists the Custom Entities defined in the PIM
for the current tenant, together with their relationships. Use the returned denominators
to query individual Custom Entity schemas via GET /CustomEntities('{denominator}')/$metadata.
            
## Response
            
200 OK — Returns the JSON Schema as a ServiceDocumentRepresentation.
            
## Error Responses
            
- 401 Unauthorized — Missing or invalid API key.
- 403 Forbidden — Feature disabled for the tenant.
- 404 Not Found — Tenant not found.
- 500 Internal Server Error — Unexpected technical error.
            
## Example
            
Request:
http
GET /CustomEntities/$metadata HTTP/1.1
X-API-KEY: your-api-key-here

            
Response:
http
HTTP/1.1 200 OK
Content-Type: application/json

## Returns the public metadata of the Point of Sale model.

 - [GET /rest/Catalog/PointsOfSale/$metadata](https://docs.api.saleslayer.com/apis/catalog-v2.0/metadata/getpointofsalemetadataasync.md): ## Authentication
            
Requires a valid API key in the X-API-KEY header.
            
## Response
            
200 OK — A JSON schema document describing the Point of Sale resource and its
relationships. Use this document to build requests against the API.
            
## Error Responses
            
- 401 Unauthorized — Missing or invalid API key.
- 403 Forbidden — Feature disabled for the tenant.
- 404 Not Found — Tenant or model not found.
- 500 Internal Server Error — Unexpected technical error.
            
## Example
            
Request:
http
GET /PointsOfSale/$metadata HTTP/1.1
X-API-KEY: your-api-key-here

            
Response:
http
HTTP/1.1 200 OK
Content-Type: application/json

## Returns the public JSON Schema describing the Product model.

 - [GET /rest/Catalog/Products/$metadata](https://docs.api.saleslayer.com/apis/catalog-v2.0/metadata/getproductmetadataasync.md): ## Authentication
            
Requires a valid API key in the X-API-KEY header.
            
## Description
            
The metadata is a JSON Schema document that describes:
- The implicit and custom properties exposed by the Product resource.
- The associated resources (Category, Attribute Set, Variant) and their relationships.
            
The schema should be consulted to build requests against the other Product endpoints
(which fields can be used in $select, $filter, $orderby, request bodies, etc.).
            
## Response
            
200 OK — Returns the JSON Schema as a ServiceDocumentRepresentation.
            
## Error Responses
            
- 401 Unauthorized — Missing or invalid API key.
- 403 Forbidden — Feature disabled for the tenant.
- 404 Not Found — Tenant or model not found.
- 500 Internal Server Error — Unexpected technical error.
            
## Example
            
Request:
http
GET /Products/$metadata HTTP/1.1
X-API-KEY: your-api-key-here

            
Response:
http
HTTP/1.1 200 OK
Content-Type: application/json

## Returns the public JSON Schema describing the Variant model.

 - [GET /rest/Catalog/Variants/$metadata](https://docs.api.saleslayer.com/apis/catalog-v2.0/metadata/getvariantmetadataasync.md): ## Authentication
            
Requires a valid API key in the X-API-KEY header.
            
## Description
            
The metadata is a JSON Schema document that describes:
- The implicit and custom properties exposed by the Variant resource.
- The associated resources (Product) and their relationships.
            
The schema should be consulted to build requests against the other Variant endpoints
(which fields can be used in $select, $filter, $orderby, request bodies, etc.).
            
## Response
            
200 OK — Returns the JSON Schema as a ServiceDocumentRepresentation.
            
## Error Responses
            
- 401 Unauthorized — Missing or invalid API key.
- 403 Forbidden — Feature disabled for the tenant.
- 404 Not Found — Tenant or model not found.
- 500 Internal Server Error — Unexpected technical error.
            
## Example
            
Request:
http
GET /Variants/$metadata HTTP/1.1
X-API-KEY: your-api-key-here

            
Response:
http
HTTP/1.1 200 OK
Content-Type: application/json

