This is the API reference for integrating with Grid Products. It provides detailed information on endpoints, authentication, and examples for retrieving, updating, and managing your product data.
Postman Collection
For easy testing and configuration, you can import our ready-to-use Postman collection into Postman.
Configuration Notes:
- URL Placeholders: Replace
<tenant-id>
,<environment>
, and<space-id>
with your actual values. - Data Residency: Replace
<data-residency>
with one of the following:eu
,us
,in
,au
, oruae
. - Headers: Set the
x-api-key
orAuthorization
header to your generated access token from the Grid Console.
Authentication
To use the Grid Products API, every request requires an access token. Here's how to generate one:
- Go to the Apps → Developer tab in the Phygrid Console.
- Generate an access token.
- Add the token as an
x-api-key
in your request headers.
URL Overview
The {base-url}
for the Grid Products API varies based on your data residency. Use the correct region-specific URL from the table below:
Region | URL |
---|---|
EU | https://api.omborigrid.com/regions/eu/products |
US | https://api.omborigrid.com/regions/us/products |
IN | https://api.omborigrid.com/regions/in/products |
AU | https://api.omborigrid.com/regions/au/products |
UAE | https://api.omborigrid.com/regions/uae/products |
Replace {tenant-id}
with your tenant ID and {environment}
with the environment where your products data will live (e.g., dev
, staging
).
Endpoints Overview
Here's a quick overview of available API endpoints:
Method | Endpoint | Description |
---|---|---|
GET | /products | Returns a list of products. |
GET | /products/{id} | Retrieves a specific product by ID. |
GET | /products-barcode/{barcode} | Retrieves a specific product by barcode. |
GET | /search | Searches products or product types by keyword. |
POST | /products/push | Pushes products into the database. |
DELETE | /products | Removes specified products by ID. |
PATCH | /products | Updates products in the database. |
POST | /products-push | Pushes products into a specific space. |
PATCH | /variants | Updates variant-level information. |
GET | /product-types | Returns a list of product types. |
GET | /product-types/{id} | Retrieves a specific product type by ID. |
POST | /product-types | Pushes product types into the database. |
DELETE | /product-types | Removes specified product types by ID. |
Working with Products
Fetch Products
Retrieve products with a GET
request:
GET {base-url}/{tenant-id}/{environment}/products
POST {base-url}/{tenant-id}/{environment}/products
For large requests (>2k characters) we recommend performing the same call using POST method instead to avoid URL-length limitations.
Response
{
list: Array<Partial<GridProduct>>,
count: number,
facets: { [propertyName]: FacetResults[] },
attributeFilters: { [key]: string[] }
}
Reference: GridProduct
Query Parameters
Use the following parameters as GET properties in the URL to refine your results:
Parameter | Type | Description | Example |
---|---|---|---|
search | string | Search for products by keyword. | Desks |
limit | number | Max number of results to return (default: 50). | 100 |
page | number | Pagination (default: 1). | 1 |
select | string | Specify which fields to return (comma-separated). | productName, productPrice |
filter | object | Apply filters using a query string. | {"gt": ["price", 10]} |
sort | string | Sort results (e.g., field asc or field desc). | price asc |
GET Product by ID
Retrieve a specific product by its ID:
GET {base-url}/{tenant-id}/{environment}/products/{productGroupId}
Response
Returns Partial<GridProduct>
Query Parameters
To use query parameters, add them as GET properties to the URL.
Parameter | Type | Description | Example |
---|---|---|---|
productGroupId | string | The ID of the Product | 100001 |
select | string | List of selected fields to be returned (comma-separated) | productGroupId, productName, productDescription |
filter | string | Query string to use for filtering results based on filterable fields (operators and string values should be enclosed in double quotes) | {"gt": ["productPriceList/listPrice", 10]} |
includeProductsByVariantsByGroupId | boolean | Flag to merge in response the variants related info based on matching variantsByGroupId field | false |
GET Product By Barcode
Retrieves a specific product by barcode ID. Variants checked:
- globalTradeItemNumber
- europeanArticleNumber
- universalProductCode
GET {base-url}/{tenant-id}/{environment}/products-barcode/{barcode}
Response
{
productDetails: Partial<GridProduct>,
productId: string
}
Reference: GridProduct
Query Parameters
To use query parameters, add them as GET properties to the URL.
Parameter | Type | Description | Example |
---|---|---|---|
barcode | string | Barcode ID | 0999999999993 |
select | string | List of selected fields to be returned (comma-separated) | productGroupId, productName, productDescription |
filter | string | Query string to use for filtering results based on filterable fields (operators and string values should be enclosed in double quotes) | {"gt": ["productPriceList/listPrice", 10]} |
includeProductsByVariantsByGroupId | boolean | Flag to merge in response the variants related info based on matching variantsByGroupId field | false |
GET Search
Searches products or product types by keyword.
{base-url}/{tenant-id}/{environment}/search
Response
{
products: Array<Partial<GridProduct>>,
productTypes: Array<ProductType>
}
Reference: GridProduct, ProductType
Query Parameters
To use query parameters, add them as GET properties to the URL.
Parameter | Type | Description | Example |
---|---|---|---|
term | string | Query to search for | Desk |
select | string | List of selected fields to be returned (comma-separated) | productGroupId, productName, productDescription |
GET Product Recommendations by ID
Retrieves a list of product recommendations taken from RelatedProductGroups
GET {base-url}/{tenant-id}/{environment}/product-recommendations/{productGroupId}
Response
Array<Partial<GridProduct>>
Query Parameters
To use query parameters, add them as GET properties to the URL.
Parameter | Type | Description | Example |
---|---|---|---|
productGroupId | string | The ID of the Product | 100001 |
POST Push Products
This API allows you to upload or merge products following the GridProduct
format. The only required field is productGroupId
, while other fields are optional.
Body
The body of the request should be an Array of GridProducts JSON format using the content-type
header application/json
.
Parameter | Type | Description |
---|---|---|
data | <Partial<GridProduct>> | An array of Partial<GridProduct> . This can be a list of products in full GridProduct format or Partial<GridProduct> to update specific product fields. |
Payload
Please ensure that the productGroupId
is always included in the payload.
You have the flexibility to send either a single product field, multiple fields, or the entire product in your payload.
Parameter | Type | Expected | Description |
---|---|---|---|
productName | ProductName[] | replace | The product name will be updated with the new value. |
productShortDescription | ProductShortDescription[] | replace | Product short description will be updated with the new value. |
productInternalName | productInternalName[] | replace | Product internal name will be updated with the new value. |
storageInstructions | ProductStorageInstructions[] | replace | Product storage instructions will be updated with the new value. |
consumerStorageInstruction | ProductConsumerStorageInstruction[] | replace | Product consumer storage instructions will be updated with the new value. |
productShippingInstruction | ProductShippingInstruction[] | replace | Product shipping instructions will be updated with the new value. |
productType | Array<string> | replace | Product type will be updated with the new value. |
productLabel | ProductLabel[] | replace | Product label will be updated with the new value. |
productTags | ProductTags[] | replace | Product tags will be updated with the new value. |
brand | ProductBrand[] | replace | Product brand will be updated with the new value. |
productVendor | ProductVendor[] | replace | Product vendor will be updated with the new value. |
productDescription | productDescription[] | replace | Product description will be replaced with the new value. |
variants | Variant[] | merge | It will merge and update product variants array based on productId and productGroupId. |
productFeature | ProductFeature[] | merge | It will merge and update product features array based on productId. |
productPriceList | productPriceList[] | merge | It will merge and update product prices array based on productId and spaceId. |
productStatus | ProductStatus[] | merge | It will merge and update product status array based on spaceId. |
catalogPageLocationProduct | CatalogPageLocationProduct[] | merge | It will merge and update product catalogue array based on productId and productGroupId. |
customProperties | CustomProperties[] | merge | It will merge and update product custom properties array based on key and spaceId. |
productItemQuantity | ProductItemQuantity[] | merge | It will merge and update product quantity array based on productId and spaceId. |
We will provide two payload examples to illustrate both the replace and merge operations:
-
When sending the
productName
andproductDescription
in the payload, both of these fields will undergo updates, with the existing values being replaced by the new ones.curl --location '{base-url}/{tenant-id}/{environment}/products-push' \ --header 'Content-Type: application/json' \ --data '{ "data": [ { "productGroupId": "<product-group-id>", "productName": [ { "isoLanguageId": "en-GB", "productName": "<product-name>" }, { "isoLanguageId": "en-US", "productName": "<product-name>" } ], "productDescription": [ { "isoLanguageId": "en-GB", "productDescription": "<product-description>" }, { "isoLanguageId": "en-US", "productDescription": "<product-description> " } ] } ] }'
-
When including the
roductPriceList
andproductItemQuantity
in the payload, these fields will be subject to updates through a merge operation using theproductId
andspaceId
as key parameters.curl --location '{base-url}/{tenant-id}/{environment}/products-push' \ --header 'Content-Type: application/json' \ --data '{ "data":[ { "productGroupId": "xxxxxxx", "productPriceList": [ { "isoLanguageId": "en-GB", "productId": "xxxxxxx", "isoCurrencyCode": "EUR", "listPrice": 1140, "priceListType": "Standard", "spaceId": "xxxxxxx" }, { "isoLanguageId": "en-GB", "productId": "xxxxxxx", "isoCurrencyCode": "USD", "listPrice": 11401, "priceListType": "Standard", "spaceId": "xxxxxxx" } ], "productItemQuantity": [ { "productId": "xxxxxxx", "productItemQuantity": 90, "spaceId": "xxxxxxx" }, { "productId": "xxxxxxx", "productItemQuantity": 910, "spaceId": "xxxxxxx" } ] } ] }'
The spaceIds array is not included in the request payload. Instead, it is automatically populated based on the values of productPriceList
, productStatus
, and productItemQuantity
.
Limitations: 100 products per batch
DELETE Space Products
This API detaches products from space by sending an array of productGroupId
. It will remove these products from the specified space and any relevant subfields in the GridProduct
that are related to this space.
Body
Parameter | Type | Description | Example |
---|---|---|---|
data | Array<string> | An array of productGroupId | ['045xxx','046xxx',...] |
Response
Upon a successful request, the API will return a JSON response with status information for each product removed.
{
"data": [
{
"productGroupId": "045xxx",
"status": 202
},
{
"productGroupId": "046xxx",
"status": 202
},
....
]
}
DELETE Products
Removes products from the Grid Products database based on specified ID's
DELETE {base-url}/{tenant-id}/{environment}/products
Parameter | Type | Description | Example |
---|---|---|---|
data | Array<string> | List of product ID's to be removed from the database | ["1001", "1002"] |
PATCH (Update) Products
Updates products with the fields specified in the data object. Shallow-update is performed. Fields not passed in this call will remain the same. Fields containing Arrays or Objects will be completely overwritten.
PATCH {base-url}/{tenant-id}/{environment}/products
Parameter | Type | Description |
---|---|---|
data | Array<Partial<GridProduct>> | List of products with fields in GridProduct format to update to the Database |
Limitations: 100 records per batch
GET Product Variant
Retrieves a specific variant by ID
GET {base-url}/{tenant-id}/{environment}/variants/{productId}
Response
Returns [VariantInfo](data-model)
Query Parameters
Parameter | Type | Description | Example |
---|---|---|---|
productId | string | The ID of the Product variant | 100001 |
PATCH (Update) Variants
Updates variants with the fields specified in the data object without requiring the product's productGroupId
. Shallow-update is performed. Fields not passed in this call stay the same. Fields containing Arrays or Objects (productPriceList
and productItemQuantity
) with the matching specified variant's productId
and spaceId
only will be upserted.
PATCH {base-url}/{tenant-id}/{environment}/variants
Query Parameters
Parameter | Type | Description |
---|---|---|
data | Array<Partial<VariantUpdateFields>> | List of variants level information with fields in VariantUpdateFields format to update to the Database |
upsertSpaceIds | boolean | Flag to upsert spaceId values from the productItemQuantity and productPriceList fields to the main product’s spaceIds field |
Reference: [VariantUpdateFields](data-model)
Product Types
GET Product Types List
Returns list of product types associated with the tenant id and environment
GET {base-url}/{tenant-id}/{environment}/product-types
Response
Returns Array<ProductType>
Query Parameters
Parameter | Type | Description | Example |
---|---|---|---|
ids | string | List of product types ids to be returned | Furniture, Tech |
GET Product Type Details
Returns details of a specific product type
GET {base-url}/{tenant-id}/{environment}/product-types/{productTypeId}
Response
Returns [ProductType](data-model)
Query Parameters
Parameter | Type | Description | Example |
---|---|---|---|
productTypeId | string | Product type ID to be returned | Furniture |
POST Product Types
Update or insert product types to database
Response
Returns Array<[OperationResponse](https://docs.microsoft.com/en-us/javascript/api/@azure/cosmos/operationresponse?view=azure-node-latest)>
Limitations: 100 product types documents per batch
Reference: ProductType
DELETE Product Types
Removes product types from the Grid Products database based on specified ids
DELETE {base-url}/{tenant-id}/{environment}/product-types
Response
Returns Array<{ id: string; status: number; }>
Query Parameters
Parameter | Type | Description | Example |
---|---|---|---|
data | Array<string> | List of product type IDs to remove from Grid Products database | ["Furniture", "Tech"] |
Reference: ProductType