# Harvest directory profiles

Collect profiles across a bounded number of public directory pages using a category or subcategory filter.

- Platform: [Linktree](https://docs.upscrape.com/docs/platforms/linktree)
- Capability ID: `linktree.directory.profiles`
- 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": {
    "category": "business",
    "max_pages": 2
  },
  "capability": "linktree.directory.profiles"
}'
```

## Input


| Field | Type | Required | Description |
| --- | --- | --- | --- |
| `category` | `string` | No | Primary directory category. Omit both filters for all profiles; mutually exclusive with subcategory. Allowed values: `all`, `business`, `creative`, `education`, `entertainment`, `fashion-beauty`, `food-beverage`, `government-politics`, `health-wellness`, `non-profit`, `other`, `tech`, `travel-tourism`. |
| `max_pages` | `integer` | No | Maximum pages to fetch (about 18 profiles each; default 10, maximum 25). The walk stops sooner at the reported end. From 1 to 25. Default: `10`. |
| `subcategory` | `string` | No | Secondary directory filter discovered from Linktree's public taxonomy; mutually exclusive with category. Allowed values: `affiliate-marketing`, `agency-consulting`, `alcohol`, `automobiles`, `actor`, `activism`, `attractions`, `bars-restaurants`, `campus-organizations`, `cannabis`, `chef`, `climate`, `clothing-accessories`, `coffee-tea`, `comedy`, `community-organization`, `contests-giveaways`, `cosplay`, `countries-municipalities`, `crafts`, `crowdfunding`, `dance-theatre`, `desserts`, `designer`, `digital-creator`, `disaster-relief`, `diversity-inclusion`, `e-learning`, `edutech`, `electronic-press-kit`, `emergency-services`, `fan-club`, `film-tv`, `financial-services`, `fintech`, `fragrances`, `gaming-esports`, `groceries`, `hair-care`, `hardware`, `healthcare`, `home-cooking`, `home-improvement-maintenance`, `hotels-lodging`, `hr-recruiting`, `influencer`, `jewelry`, `judiciary`, `law-enforcement`, `legal-services`, `library`, `life-coaching`, `live-events`, `makeup-skincare`, `marketing-advertising`, `memes`, `military-veterans`, `mobile-app`, `model`, `museums`, `music`, `nail-care`, `not-listed`, `nutrition`, `performance-art`, `personal`, `pets`, `policy`, `politicians-campaigns`, `portfolio`, `public-figure`, `public-relations`, `public-services`, `radio-podcasts`, `real-estate`, `recreation`, `religion`, `saas`, `schools-universities`, `shoes`, `shopping-retail`, `social-media`, `spirituality`, `sports`, `startup`, `talent-agency`, `talent-management`, `tattoos-piercings`, `teacher`, `transportation`, `venture-capital`, `visual-arts`, `weddings`, `wildlife`, `writer`. |

### Example input

```json
{
  "category": "business",
  "max_pages": 2
}
```

## 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
{
  "pages_fetched": 2,
  "profiles": [
    {
      "avatar_url": "https://ugc.production.linktr.ee/LjwiPG26RCKWksfW1a2d_804MRaOmd7zHCIZg",
      "category_id": "business",
      "category_name": "Business",
      "profile_title": "Yeesco",
      "profile_url": "https://linktr.ee/lojasyeesco",
      "username": "lojasyeesco",
      "verified": false
    },
    {
      "avatar_url": "https://ugc.production.linktr.ee/gktK40SHi6rJZd3BQFCA_gwckDcyA5PEYqjZ5",
      "category_id": "business",
      "category_name": "Business",
      "profile_url": "https://linktr.ee/vannise2019",
      "username": "vannise2019",
      "verified": false
    },
    {
      "avatar_url": "https://ugc.production.linktr.ee/HpU1lQbTHeGWCjC7kNfm_o4KTOhJ9dKjAPCvD",
      "badges": [
        "VERIFICATION_TICK"
      ],
      "category_id": "business",
      "category_name": "Business",
      "profile_title": "Oh My Technology",
      "profile_url": "https://linktr.ee/ohmytechnology",
      "username": "ohmytechnology",
      "verified": true
    }
  ],
  "selected_category": "business"
}
```
### Illustrative output fields

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

| Path | Observed type | Example |
| --- | --- | --- |
| `pages_fetched` | `integer` | 2 |
| `profiles` | `array` | 3 items |
| `profiles` | `array` | 3 items |
| `selected_category` | `string` | business |

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