Apollo Pharmacy Category Products
apollo-pharmacy.category.products
Walk a public Apollo Pharmacy category with its total item count and each product's price and MRP.
At a glance
- Endpoint ID
apollo-pharmacy.category.products- Price
- 1 credit per call; failed calls are free
- Runs for up to
- 60 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": "apollo-pharmacy.category.products", "input": { "max_pages": 1, "page": 1, "slug": "pain-relief" }}'
import jsonimport osimport requestspayload = json.loads(r'''{ "capability": "apollo-pharmacy.category.products", "input": { "max_pages": 1, "page": 1, "slug": "pain-relief" }}''')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": "apollo-pharmacy.category.products", "input": { "max_pages": 1, "page": 1, "slug": "pain-relief" }}),});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 |
|---|---|---|---|---|
slug |
string | one of | Public listing slug, as returned by the category list. | pain-relief |
url |
string | one of | Public listing page URL on www.apollopharmacy.in. | |
max_pages |
integer | no | How many listing pages to read forward from page. From 1 to 5. Default: 1. |
1 |
page |
integer | no | First listing page to read. One page carries 24 products. From 1 to 100. Default: 1. |
1 |
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:
{ "end_page": 1, "has_more": true, "listing_url": "https://www.apollopharmacy.in/shop-by-category/pain-relief", "max_page": 36, "start_page": 1, "total_items": 859, "products": [ { "name": "Volini Pain Relief Spray, 100 gm", "price": 318.8, "mrp": 375, "rating": 3.9, "review_count": 157, "availability": "in_stock", "currency": "INR", "discount_percent": 15, "image_url": "https://images.apollo247.in/pub/media/catalog/product/V/O/VOL0129_1-AUG23_1.jpg", "pack_form": "Bottle", "pack_size": "100", "prescription_required": false, "product_form": "Spray", "product_id": "1364", "sku": "VOL0129", "unit_price": "₹3.19/gm", "url": "https://www.apollopharmacy.in/otc/volini-spray-100g", "tags": [ "Muscle Pain", "Joint Pain" ] }, { "name": "Dr.Ortho Oil, 120 ml", "price": 299, "mrp": 299, "availability": "in_stock", "currency": "INR", "image_url": "https://images.apollo247.in/pub/media/catalog/product/D/R/DRO0100_1-JULY23_1.jpg", "pack_form": "Bottle", "pack_size": "120", "prescription_required": false, "product_form": "Oil", "product_id": "1202", "sku": "DRO0100", "unit_price": "₹2.49/ml", "url": "https://www.apollopharmacy.in/otc/dr-ortho-oil-120ml", "tags": [ "Joint Pain", "Muscle Pain" ] } ]}
Fields
| Field | Type | Example |
|---|---|---|
products[].name |
string | Volini Pain Relief Spray, 100 gm |
products[].price |
number | 318.8 |
products[].mrp |
integer | 375 |
products[].rating |
number | 3.9 |
products[].review_count |
integer | 157 |
products[].availability |
string | in_stock |
products[].currency |
string | INR |
products[].discount_percent |
integer | 15 |
products[].image_url |
string | https://images.apollo247.in/pub/media/catalog/product/V/O/VOL01… |
products[].pack_form |
string | Bottle |
products[].pack_size |
string | 100 |
products[].prescription_required |
boolean | false |
products[].product_form |
string | Spray |
products[].product_id |
string | 1364 |
products[].sku |
string | VOL0129 |
products[].tags |
array | Muscle Pain, Joint Pain, Pain Relief |
products[].unit_price |
string | ₹3.19/gm |
products[].url |
string | https://www.apollopharmacy.in/otc/volini-spray-100g |
end_page |
integer | 1 |
has_more |
boolean | true |
listing_url |
string | https://www.apollopharmacy.in/shop-by-category/pain-relief |
max_page |
integer | 36 |
products |
array | 3 records |
start_page |
integer | 1 |
total_items |
integer | 859 |
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 Apollo Pharmacy endpoints
apollo-pharmacy.brand.productsBrand productsapollo-pharmacy.categories.listCategoriesapollo-pharmacy.pincode.checkCheck PIN codeapollo-pharmacy.product.getProductapollo-pharmacy.product.offersProduct offersapollo-pharmacy.product.reviewsProduct reviewsapollo-pharmacy.product.substitutesProduct substitutesapollo-pharmacy.search.productsProducts searchapollo-pharmacy.search.suggestSuggestions searchapollo-pharmacy.stores.nearNearby storesapollo-pharmacy.trending.searchesTrending searches
Something missing or unclear? Ask the team that builds the Apollo Pharmacy endpoints.