# Get Location

Fetches metadata for a public Instagram location from its direct server-rendered Relay payload.

- Platform: [Instagram](https://docs.upscrape.com/docs/platforms/instagram)
- Capability ID: `instagram.location.get`
- Cost: 1 credit per request
- Maximum runtime: 60 seconds
- Execute endpoint: `POST https://data.upscrape.com/execute`

## Request

Use the exact public capability ID in the shared execute envelope.

```bash
curl --request POST \
  --url https://data.upscrape.com/execute \
  --header "Authorization: Bearer YOUR_API_KEY" \
  --header "Content-Type: application/json" \
  --header "Prefer: wait=30" \
  --data '{
  "input": {
    "location_id": "213385402"
  },
  "capability": "instagram.location.get"
}'
```

## Input

| Field | Type | Required | Description |
| --- | --- | --- | --- |
| `location_id` | `string` | Yes | Numeric Instagram location ID |

### Example input

```json
{
  "location_id": "213385402"
}
```

## Response

Successful output is returned in `results[0].data`. Raw platform output is intentionally open-ended and may evolve with the upstream source.

### Illustrative sample output

This redacted fixture is an example, not a fixed response schema.

```json
{
  "data": {
    "category": "City",
    "hours": {
      "status": ""
    },
    "ig_business": {
      "profile": null
    },
    "lat": 51.5141,
    "lng": -0.1094,
    "location_address": "",
    "location_city": "",
    "location_id": "213385402",
    "location_zip": "",
    "media_count": 106157871,
    "name": "London, United Kingdom",
    "phone": "[redacted:phone]",
    "price_range": 2,
    "slug": "london-united-kingdom"
  },
  "location_id": "213385402"
}
```
### Illustrative output fields

Derived from the sample above for orientation only. These fields are not a fixed response schema.

| Path | Observed type | Example |
| --- | --- | --- |
| `data` | `object` | 14 fields |
| `data.category` | `string` | City |
| `data.hours` | `object` | 1 fields |
| `data.ig_business` | `object` | 1 fields |
| `data.lat` | `number` | 51.5141 |
| `data.lng` | `number` | -0.1094 |
| `data.location_address` | `string` |  |
| `data.location_city` | `string` |  |
| `data.location_id` | `string` | 213385402 |
| `data.location_zip` | `string` |  |
| `data.media_count` | `integer` | 106157871 |
| `data.name` | `string` | London, United Kingdom |
| `data.phone` | `string` | [redacted:phone] |
| `data.price_range` | `integer` | 2 |
| `data.slug` | `string` | london-united-kingdom |
| `location_id` | `string` | 213385402 |

## Execution behavior

A `200` response completed inline. A `202` response was queued; poll `GET /jobs/{id}` until the job reaches `completed` or `failed`. Use an `Idempotency-Key` when retrying must not create a duplicate logical job.

## Related documentation

- [Authentication](https://docs.upscrape.com/docs/api/authentication)
- [Jobs and results](https://docs.upscrape.com/docs/api/jobs)
- [Errors and retries](https://docs.upscrape.com/docs/api/errors)
- [Idempotency](https://docs.upscrape.com/docs/api/idempotency)
