GET Query
GET /services/data/v51.0/query
Operation ID: Query. Tags: Product. Security: bearerAuth.
To look up information about products, use the Query resource of the main REST API from Salesforce and set the value of the q parameter to an SOQL query. The following examples are included in the query parameters section of this page, with corresponding examples in the responses section:
Example 1 of 3: getAllManufacturers
One piece of information that can be completed on a product is its make/manufacturer. This value must be one of the values from the marketplace (if none of them apply, contact the marketplace to check whether a new one can be inserted). In order to insert this relationship, you must first request an export of the data to the marketplace or access the API directly and save the list. If the item limit is exceeded, pagination may be necessary, in which case please refer to the following documentation.
Example 2 of 3: getAllSpecs
Specs consist of all the extra information that can be associated with the products and SKUs. This includes both merely descriptive information, such as "book author", "musical genre",... and also information on variations of SKUs, such as "color" and "size", which define an SKU and need to be chosen in order to complete the purchase. Sellers may fill in the specs within the products with any value (red, blue,...), but the specs themselves (color) must be one of the specs configured by the marketplace. A request for this export may be submitted to the marketplace or this API may be used to create a full list. Some specs may be subject to restrictions during completion (boolean, specific values, only numbers). Please confirm any queries with the marketplace as you fill in each type. If you have more than the permissible number of items, you may need pagination, in which case please refer to the following documentation.
Example 3 of 3: getAllProductImagesByProductId
This call uses the External Product ID to list all its images
Parameters
q(query, string)Example: getAllManufacturers
SELECT FIELDS(ALL) FROM Atonit_Mktplace__Manufacturer__c LIMIT 200Example: getAllSpecs
SELECT FIELDS(ALL) FROM Atonit_Mktplace__Specs__c WHERE Atonit_Mktplace__Is_Deleted__c = false LIMIT 200Example: getAllProductImagesByProductId
SELECT FIELDS(ALL) FROM Atonit_Mktplace__Image__c WHERE Atonit_Mktplace__Product__r.Atonit_Mktplace__External_Id__c= '{{seller-api-prefix}}-product-1' LIMIT 200
Responses
- 200
OK
Headers:
Date(string)
Example:Fri, 23 Apr 2021 17:37:15 GMT.Strict-Transport-Security(string)
Example:max-age=31536002; includeSubDomains.X-Content-Type-Options(string)
Example:nosniff.X-XSS-Protection(string)
Example:1; mode=block.X-Robots-Tag(string)
Example:none.Cache-Control(string)
Example:no-cache,must-revalidate,max-age=0,no-store,private.Sforce-Limit-Info(string)
Example:api-usage=1688/101002.Content-Type(string)
Example:application/json;charset=UTF-8.Vary(string)
Example:Accept-Encoding.Content-Encoding(string)
Example:gzip.Transfer-Encoding(string)
Example:chunked.
Media type:
application/json. Schema:object.Example: getAllManufacturers
{ "totalSize": 31, "done": true, "records": [ { "Id": "a0C5Y00001sGTZlUAO", "Name": "Samsung", "CreatedDate": "2021-03-22T19:24:42.000+0000", "LastModifiedDate": "2021-04-12T18:05:42.000+0000", "Atonit_Mktplace__Description__c": null, "Atonit_Mktplace__Marketplace_Id__c": "Samsung" }, { "Id": "a0C5Y00001sGTZmUAO", "Name": "Apple", "CreatedDate": "2021-03-22T19:24:42.000+0000", "LastModifiedDate": "2021-04-12T18:05:42.000+0000", "Atonit_Mktplace__Description__c": null, "Atonit_Mktplace__Marketplace_Id__c": "Apple" }, { "Id": "a0C5Y00001sGTZnUAO", "Name": "Atari", "CreatedDate": "2021-03-22T19:24:42.000+0000", "LastModifiedDate": "2021-04-12T18:05:42.000+0000", "Atonit_Mktplace__Description__c": null, "Atonit_Mktplace__Marketplace_Id__c": "Atari" } ] }Example: getAllSpecs
{ "totalSize": 59, "done": true, "records": [ { "Id": "a0Y5Y00000nTXSSUA4", "Name": "Available for In Store Pickup", "CreatedDate": "2021-03-22T21:13:23.000+0000", "LastModifiedDate": "2021-04-12T18:05:11.000+0000", "Atonit_Mktplace__Is_Deleted__c": false, "Atonit_Mktplace__Marketplace_Id__c": "availableForInStorePickup", "Atonit_Mktplace__Set_of_Text__c": false, "Atonit_Mktplace__Update_Timestamp__c": "2021-04-12T18:04:57.000+0000" }, { "Id": "a0Y5Y00000nTXSTUA4", "Name": "Battery Life", "CreatedDate": "2021-03-22T21:13:23.000+0000", "LastModifiedDate": "2021-04-12T18:05:11.000+0000", "Atonit_Mktplace__Is_Deleted__c": false, "Atonit_Mktplace__Marketplace_Id__c": "batteryLife", "Atonit_Mktplace__Set_of_Text__c": false, "Atonit_Mktplace__Update_Timestamp__c": "2021-04-12T18:04:57.000+0000" }, { "Id": "a0Y5Y00000nTXSUUA4", "Name": "Battery Type", "CreatedDate": "2021-03-22T21:13:23.000+0000", "LastModifiedDate": "2021-04-12T18:05:11.000+0000", "Atonit_Mktplace__Is_Deleted__c": false, "Atonit_Mktplace__Marketplace_Id__c": "batteryType", "Atonit_Mktplace__Set_of_Text__c": false, "Atonit_Mktplace__Update_Timestamp__c": "2021-04-12T18:04:57.000+0000" }, { "Id": "a0Y5Y00000nTXSXUA4", "Name": "Color", "CreatedDate": "2021-03-22T21:13:23.000+0000", "LastModifiedDate": "2021-04-12T18:05:11.000+0000", "Atonit_Mktplace__Is_Deleted__c": false, "Atonit_Mktplace__Marketplace_Id__c": "color", "Atonit_Mktplace__Set_of_Text__c": false, "Atonit_Mktplace__Update_Timestamp__c": "2021-04-12T18:04:57.000+0000" } ] }Example: getAllProductImagesByProductId
{ "totalSize": 2, "done": true, "records": [ { "Id": "a085Y00001AhajFQAR", "Name": "I-9353", "CreatedDate": "2021-04-22T18:39:01.000+0000", "LastModifiedDate": "2021-04-23T18:35:05.000+0000", "Atonit_Mktplace__Product__c": "a0M5Y00000csztLUAQ", "Atonit_Mktplace__Order__c": 1, "Atonit_Mktplace__Spec_Value__c": "Vermelho", "Atonit_Mktplace__Spec__c": "a0Y5Y00000nTXSXUA4", "Atonit_Mktplace__URL__c": "https://via.placeholder.com/150.png", "Atonit_Mktplace__View_Type__c": "swatch-small-medium-large", "Atonit_Mktplace__External_Id__c": "atonit-vitta-product-1-sku-image-1" }, { "Id": "a085Y00001AhajPQAR", "Name": "I-9354", "CreatedDate": "2021-04-22T18:59:02.000+0000", "LastModifiedDate": "2021-04-23T18:31:40.000+0000", "Atonit_Mktplace__Product__c": "a0M5Y00000csztLUAQ", "Atonit_Mktplace__Order__c": 1, "Atonit_Mktplace__Spec_Value__c": null, "Atonit_Mktplace__Spec__c": null, "Atonit_Mktplace__URL__c": "https://via.placeholder.com/150.png", "Atonit_Mktplace__View_Type__c": "swatch-small-medium-large", "Atonit_Mktplace__External_Id__c": "atonit-vitta-product-1-image-1" } ] }