Keeta Keemart Products
keeta.products.list
Every product in a Keemart category at a location: name, size, price, usual price, offers, stock and subcategory.
At a glance
- Endpoint ID
keeta.products.list- Price
- By request
- Runs for up to
- 30 seconds
Request
Send the endpoint ID as capability and its fields as input. Set UPSCRAPE_API_KEY to your key first.
curl --request POST \ --url https://data.upscrape.com/execute \ --header "Authorization: Bearer $UPSCRAPE_API_KEY" \ --header "Content-Type: application/json" \ --header "Prefer: wait=30" \ --data '{ "capability": "keeta.products.list", "input": { "category_id": "660", "location": { "latitude": 24.89377104655503, "longitude": 46.60596106427802 } }}'
import jsonimport osimport requestspayload = json.loads(r'''{ "capability": "keeta.products.list", "input": { "category_id": "660", "location": { "latitude": 24.89377104655503, "longitude": 46.60596106427802 } }}''')response = requests.post( "https://data.upscrape.com/execute", headers={ "Authorization": f"Bearer {os.environ['UPSCRAPE_API_KEY']}", "Content-Type": "application/json", "Prefer": "wait=30", }, json=payload,)response.raise_for_status()print(json.dumps(response.json(), indent=2))
const response = await fetch("https://data.upscrape.com/execute", { method: "POST", headers: { "Authorization": `Bearer ${process.env.UPSCRAPE_API_KEY}`, "Content-Type": "application/json", "Prefer": "wait=30", }, body: JSON.stringify({ "capability": "keeta.products.list", "input": { "category_id": "660", "location": { "latitude": 24.89377104655503, "longitude": 46.60596106427802 } }}),});if (!response.ok) { throw new Error(`Upscrape request failed: ${response.status}`);}console.log(JSON.stringify(await response.json(), null, 2));
Input
| Field | Type | Required | What it does | Example |
|---|---|---|---|---|
category_id |
string | yes | The category's ID from the categories endpoint, such as 148 for Salty Snacks. | 660 |
location |
object | yes | The delivery address as latitude and longitude. | {…} |
category_name |
string | no | The category's name, kept with the results so your rows say where they came from. | |
lat |
number | no | Latitude, as an alternative to location. | |
lng |
number | no | Longitude, as an alternative to location. | |
store_id |
string | no | The store's ID. Found from the location when you leave it out. | |
title |
string | no | A label kept with the results. |
Response
A finished call answers with HTTP 200; the data is in results[0].data, and billing.credits_charged is what it cost. A call still running after the wait answers 202: see jobs and results.
This is results[0].data from a real run:
{ "store_id": "90015", "products": [ { "name": "Iced Coffee of the Day Colombia 12oz", "display_name": "Iced Coffee of the Day Colombia", "price": 1, "barcode": "00415", "currency": "SAR", "id": "10147503", "in_stock": true, "limit_buy_text": "Only 27 left in stock", "original_price": 9, "original_price_minor": 900, "sku_id": "10147503", "spec": "12oz", "stock_quantity": 27, "subcategory_id": "662", "subcategory_name": "Cold Coffee", "discounts": [ "First-order offer" ] }, { "name": "Matilda Cake 110g", "display_name": "Matilda Cake", "price": 13.5, "barcode": "05848", "currency": "SAR", "id": "10228822", "in_stock": true, "limit_buy_text": "Only 9 left in stock", "original_price": 16, "original_price_minor": 1600, "sku_id": "10228822", "spec": "110g", "stock_quantity": 9, "subcategory_id": "1364", "subcategory_name": "Best sellers", "discounts": [ "15% off" ] } ]}
Fields
| Field | Type | What it is | Example |
|---|---|---|---|
products[].name |
string | The name of the category or product. | Iced Coffee of the Day Colombia 12oz |
products[].price |
integer | The price. | 1 |
products[].original_price |
integer | The price before the discount. | 9 |
products[].subcategory_name |
string | The sub-category it is in. | Cold Coffee |
products[].in_stock |
boolean | Whether the product is in stock. | true |
products[].stock_quantity |
integer | How many are left, as Keeta shows it. | 27 |
products[].limit_buy_text |
string | Keeta's note on how many are left. | Only 27 left in stock |
products[].display_name |
string | The product's name as shown. | Iced Coffee of the Day Colombia |
products[].barcode |
string | The product's barcode number. | 00415 |
products[].currency |
string | The currency. | SAR |
products[].discounts |
array | Discounts on the product. | First-order offer |
products[].id |
string | Keeta's ID for it. | 10147503 |
products[].original_price_minor |
integer | The price before the discount, in halalas. | 900 |
products[].sku_id |
string | Keeta's ID for this version of the product. | 10147503 |
products[].spec |
string | The size or version. | 12oz |
products[].subcategory_id |
string | Keeta's ID for the sub-category. | 662 |
products |
array | The products. | 97 records |
store_id |
string | Keeta's ID for the store. | 90015 |
If a call fails
A failed call costs nothing. The response carries an error.code you can branch on; Errors and retries lists every code and which ones to retry.
Other Keeta Keemart endpoints
Something missing or unclear? Ask the team that builds the Keeta Keemart endpoints.