# Instamart Products

Extract Instamart product details — MRP, selling price, stock — from product URLs

**Pricing:** $1 / 1k products

**Endpoint:** `POST /api/v1/agents/instamart/products/run`

**Auth:** `Authorization: Bearer mk_live_...`

## Parameters

| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| `urls` | array | Yes | Instamart product page URLs. One per line. |
| `stores` | array | No | Pick one or more dark-store locations (city - pincode - store ID). |
| `cities` | array | No | Or expand by city — pick one or more cities and we'll include all their stores. |
| `pincodes` | array | No | Or expand by pincode — pick one or more pincodes and we'll include all their stores. |

## Example

```bash
curl -X POST https://api.mindcase.co/api/v1/agents/instamart/products/run \
  -H "Authorization: Bearer mk_live_YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"params":{"urls":["..."]}}'
```

```python
import requests

resp = requests.post(
    "https://api.mindcase.co/api/v1/agents/instamart/products/run",
    headers={"Authorization": "Bearer mk_live_YOUR_API_KEY"},
    json={"params": {
    "urls": [
        "..."
    ]
}},
)
data = resp.json()
```

## Get the results

`run` is async and returns a `job_id`. Poll until `status` is `completed`, then read the rows:

```bash
# 1) check status
curl https://api.mindcase.co/api/v1/jobs/JOB_ID \
  -H "Authorization: Bearer mk_live_YOUR_API_KEY"

# 2) when status == completed, fetch the rows
curl https://api.mindcase.co/api/v1/jobs/JOB_ID/results \
  -H "Authorization: Bearer mk_live_YOUR_API_KEY"
```

Full API reference (auth, jobs, balance, endpoints): https://mindcase.co/skills.md

## Response columns

| Field | Display name | Type |
|-------|--------------|------|
| `productUrl` | Product URL | url |
| `storeId` | Store ID | text |
| `city` | City | text |
| `pincode` | Pincode | text |
| `productName` | Product Name | text |
| `brand` | Brand | text |
| `image` | Image | url |
| `price` | Price | currency |
| `mrp` | MRP | currency |
| `discount` | Discount % | percentage |
| `quantity` | Quantity | text |
| `rating` | Rating | rating |
| `ratingCount` | Rating Count | number |
| `inStock` | In Stock | boolean |
| `inventory` | Inventory | number |
| `category` | Category | text |
| `subCategory` | Sub-Category | text |
| `platform` | Platform | text |
| `productId` | Product ID | text |
