# Search Reels

Discovers public Instagram reels through web indexing with bounded page traversal and optional enrichment.

- Platform: [Instagram](https://docs.upscrape.com/docs/platforms/instagram)
- Capability ID: `instagram.reels.search`
- Cost: 1 credit per request
- Maximum runtime: 120 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 $UPSCRAPE_API_KEY" \
  --header "Content-Type: application/json" \
  --header "Prefer: wait=30" \
  --data '{
  "input": {
    "enrich": false,
    "limit": 10,
    "max_pages": 2,
    "query": "space launch"
  },
  "capability": "instagram.reels.search"
}'
```

## Input


| Field | Type | Required | Description |
| --- | --- | --- | --- |
| `enrich` | `boolean` | No | Fetch public metadata with at most four concurrent lookups and a shared 45-second budget; enrichment_status reports each result. Default: `false`. |
| `limit` | `integer` | No | Maximum number of results to return. From 1 to 25. Default: `10`. |
| `max_pages` | `integer` | No | Maximum number of result pages to fetch. From 1 to 5. Default: `2`. |
| `page` | `integer` | No | One-based result page to fetch. At least 1. Default: `1`. |
| `query` | `string` | Yes | Search query. |

### Example input

```json
{
  "enrich": false,
  "limit": 10,
  "max_pages": 2,
  "query": "space launch"
}
```

## 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 example shows one response. Values and optional fields vary with the data available.

```json
{
  "has_more": false,
  "match_mode": "keyword_popular",
  "next_page": 0,
  "pages": 1,
  "query": "space launch",
  "results": [
    {
      "caption": "Daytime launch 😍😍😍 \n\n#nasa #rocket #space #artemis2 #rocketlaunch",
      "id": "3866151443280147993",
      "matched_from": "keyword_popular",
      "play_count": 122433,
      "shortcode": "DWnVEEAk7YZ",
      "type": "Video",
      "url": "https://www.instagram.com/reel/DWnVEEAk7YZ/",
      "user": {
        "id": "17841432538971386",
        "is_verified": false,
        "username": "astronomy4u"
      },
      "video_versions": [
        {
          "height": 0,
          "width": 0
        },
        {
          "height": 0,
          "width": 0
        },
        {
          "height": 0,
          "width": 0
        }
      ]
    },
    {
      "caption": "Liftoff. The Artemis II mission launches from @NASAKennedy at 6:35 p.m. EDT (2235 UTC), propelling four astronauts on a journey around the Moon. Artemis II will pave the way for future Moon landings, as well as the next giant leap — astronauts on Mars. \n\nCredit: NASA \n#Liftoff #Launch #Artemis #Moon #Astronauts",
      "id": "3866007418412553567",
      "matched_from": "keyword_popular",
      "play_count": 102249802,
      "shortcode": "DWm0UOZgVVf",
      "type": "Video",
      "url": "https://www.instagram.com/reel/DWm0UOZgVVf/",
      "user": {
        "id": "17841401474538262",
        "is_verified": true,
        "username": "nasa"
      },
      "video_versions": [
        {
          "height": 0,
          "width": 0
        },
        {
          "height": 0,
          "width": 0
        },
        {
          "height": 0,
          "width": 0
        }
      ]
    },
    {
      "caption": "SPACE SHUTTLE LAUNCH 🌏 Part 324\n\n✨FUN FACT : The Space Shuttle’s two solid rocket boosters that produced about 5.3 million pounds of thrust more than 70% of the total power needed to leave Earth. For the first two minutes, those boosters did most of the work, burning through about 11,000 pounds of fuel per second each before separating and parachuting back into the ocean to be reused.\n\n🧑‍🚀 Follow @s…",
      "id": "3830955804460135332",
      "matched_from": "keyword_popular",
      "play_count": 231180,
      "shortcode": "DUqSgHDETOk",
      "type": "Video",
      "url": "https://www.instagram.com/reel/DUqSgHDETOk/",
      "user": {
        "id": "17841457249930043",
        "is_verified": false,
        "username": "spacegenerationx"
      },
      "video_versions": [
        {
          "height": 0,
          "width": 0
        },
        {
          "height": 0,
          "width": 0
        },
        {
          "height": 0,
          "width": 0
        }
      ]
    }
  ],
  "total_count": 10
}
```
### Illustrative output fields

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

| Path | Observed type | Example |
| --- | --- | --- |
| `has_more` | `boolean` | false |
| `match_mode` | `string` | keyword_popular |
| `next_page` | `integer` | 0 |
| `pages` | `integer` | 1 |
| `query` | `string` | space launch |
| `results` | `array` | 3 items |
| `results` | `array` | 3 items |
| `total_count` | `integer` | 10 |

## 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)
