# HarvestAPI · LinkedIn search linkedin posts

Get public social media posts, profiles and videos with HarvestAPI · LinkedIn search linkedin posts from Alexandria through one Spiral API key. Search LinkedIn posts by keywords, author, date range, and more. It runs in the background and returns structured JSON. Pay as you go, with no subscription.

- Provider: Alexandria
- Category: Social Media
- Runs: In the background
- Returns: json
- Tool id: `alexandria` / `harvestapi/linkedin/search-posts`
- Page: https://spiral.ai/tools/alexandria/harvestapi/linkedin/search-posts

## Pricing

Up to $0.0034918 per run.

## Limits

- Longest queue wait: 1 hour
- Run deadline: 5 minutes
- Longest run, end to end: 225 minutes
- Largest inline input: 1 MB
- Largest input file: 2 GB
- Largest output: 5 GB

## Input

| Field | Kind | Allowed | Default | Description |
| --- | --- | --- | --- | --- |
| `page` | number |  | — | Page number for pagination. |
| `group` | text |  | — | Group LinkedIn URL or Group ID. |
| `search` | text |  | — | Keywords to search for in posts. |
| `sortBy` | text |  | — | Sort by field. Supported values: 'relevance', 'date'. |
| `company` | text |  | — | Filter posts by this company URL(s) or company ID(s) (comma-separated). Note: LinkedIn returns fewer results per company when using post search. To extract all posts by a company, use the /linkedin/company-posts endpoint. |
| `profile` | text |  | — | Filter posts by author's profile URL(s) or public identifier(s) or profile ID(s) (comma-separated). Note: LinkedIn returns fewer results per profile when using post search. To extract all posts by a profile, use the /linkedin/profile-posts endpoint. |
| `companyId` | text |  | — | Filter posts by company ID or IDs (comma-separated). It's faster to search by ID. Note: LinkedIn returns fewer results per company when using post search. To extract all posts by a company, use the /linkedin/company-posts endpoint. |
| `profileId` | text |  | — | Filter posts by author's profile ID or IDs (comma-separated). It's faster to search by ID. Note: LinkedIn returns fewer results per profile when using post search. To extract all posts by a profile, use the /linkedin/profile-posts endpoint. |
| `contentType` | text |  | — | Filter by content type. Supported values: 'videos', 'images', 'live_videos', 'documents', 'collaborative_articles', 'jobs'. |
| `postedLimit` | text |  | — | Filter posts by maximum posted date. Supported values: '24h', 'week', 'month'. This parameter will be sent to LinkedIn, the filtering will be done on their side. |
| `authorKeywords` | text |  | — | Filter by keywords in authors' profiles. |
| `authorsCompany` | text |  | — | List of LinkedIn companies where authors of posts work (comma-separated). It supports company URLs and IDs. |
| `paginationToken` | text |  | — | Required if it was returned by the previous page. Otherwise the page will always be 1 (on LinkedIn side). Doesn't apply for all queries, usually profile posts return this token. |
| `mentioningMember` | text |  | — | Filter posts mentioning this LinkedIn profile URL or ID (comma-separated). It supports profile URLs and IDs. |
| `authorsIndustryId` | text |  | — | List of LinkedIn industry IDs of authors' companies (comma-separated). It supports industry IDs. Full list of industry IDs: https://github.com/HarvestAPI/linkedin-industry-codes-v2/blob/main/linkedin_industry_code_v2_all_eng.csv. |
| `mentioningCompany` | text |  | — | Filter posts mentioning this LinkedIn company URL or ID (comma-separated). It supports company URLs and IDs. |
| `scrapePostedLimit` | text |  | — | Post-Filter posts by maximum posted date. Supported values: '1h', '24h', 'week','month', '3months', '6months', 'year'. This parameter will be applied after receiving results from LinkedIn, the filtering will be done on our side. |

## Example

```bash
curl https://api.spiral.ai/v1/runs \
  -H "Authorization: Bearer $SPIRAL_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: $(uuidgen)" \
  -d '{
    "provider": "alexandria",
    "model": "harvestapi/linkedin/search-posts",
    "input": {
      "page": 1
    }
  }'
```

Try it in the Playground: https://spiral.ai/start?provider=alexandria&model=harvestapi%2Flinkedin%2Fsearch-posts

## Common questions

### HarvestAPI · LinkedIn search linkedin posts

**How much does HarvestAPI · LinkedIn search linkedin posts cost?**

Up to $0.0034918 per run. You pay as you go from one Spiral balance, with no subscription, and a failed run is not charged.

**How do I use HarvestAPI · LinkedIn search linkedin posts through an API?**

Send `POST /v1/runs` with `"provider": "alexandria"`, `"model": "harvestapi/linkedin/search-posts"` and the input fields on this page, using one Spiral API key. It runs in the background: poll the run, or name a webhook to be told when it finishes.

**Do I need an account with Alexandria to use HarvestAPI · LinkedIn search linkedin posts?**

No. Spiral runs it on its own Alexandria account and charges your Spiral balance.

**Can my AI agent use HarvestAPI · LinkedIn search linkedin posts?**

Yes. Agents find and run it through Spiral's MCP server, CLI or agent skill, with the same API key.

