API reference · LinkedIn
linkedin/bulk/profile-posts
Integrate this model through SandBase's unified API, with production-ready schemas and examples.
Production endpoint
Send your first request
OpenAI-compatible endpoint with unified authentication and usage tracking.
POST
https://api.sandbase.ai/v1/runModel ID
linkedin/bulk/profile-posts01
Input Schema
14 parameters · 0 required · 14 optional
| Parameter | Type | Required | Description |
|---|---|---|---|
maxPosts | integer | Optional | Maximum number of posts to scrape per each profile or company. Default is 10. This overrides pagination. If you set this to 0, it will scrape all posts. · Min: -9007199254740991 · Max: 9007199254740991 |
targetUrls | array | Optional | List of LinkedIn profile or company URLs to scrape. Example: `https://www.linkedin.com/in/satyanadella/` will fetch posted or re-posted content by Bill Gates. |
maxComments | integer | Optional | Maximum number of comments to scrape per post. Default is 5. · Min: -9007199254740991 · Max: 9007199254740991 |
postedLimit | string | Optional | Fetch posts no older than X time. Options: '24h', 'week', 'month'. · Options: any, 1h, 24h, week, month, 3months, 6months, year any1h24hweekmonth3months6monthsyear |
maxReactions | integer | Optional | Maximum number of reactions to scrape per post. Default is 5. · Min: -9007199254740991 · Max: 9007199254740991 |
contextCountry | string | Optional | Set the context country for LinkedIn. This can affect the content you see on LinkedIn, as it may vary by region. · Options: any, US, GB, DE, FR anyUSGBDEFR |
includeReposts | boolean | Optional | Include reposts (shared posts without comments). By default, all posts are scraped. · Default: true |
scrapeComments | boolean | Optional | Scrape comments of posts. · Default: false |
postedLimitDate | string | Optional | Scrape posts from now up to and including this date. It supports the [Date time string format](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date#date_time_string_format). For example, "2011-10-10", or "2011-10-10T14:48:00.000+09:00" or a timestamp: "628021800000" |
scrapeReactions | boolean | Optional | Scrape reactions of posts. · Default: false |
includeQuotePosts | boolean | Optional | Include quote posts (shared posts with comments). By default, all posts are scraped. · Default: true |
postNestedComments | boolean | Optional | Whether to add comments items inside post items. In a case of hundreds of comments, the Actor might hit the max item size limit and won't be able to save a post. |
commentsPostedLimit | string | Optional | Fetch comments no older than X time. Options: '24h', 'week', 'month'. · Options: any, 1h, 24h, week, month any1h24hweekmonth |
postNestedReactions | boolean | Optional | Whether to add reactions items inside post items. In a case of hundreds of reactions, the Actor might hit the max item size limit and won't be able to save a post. |
02
Output Schema
| Field | Type | Description |
|---|---|---|
id | string | Unique identifier for the generation task |
status | string | Task status: pending, running, completed, failed, timeout |
model | string | Model used for the generation |
outputs | array | Array of output items |
outputs[].url | string | URL of the generated artifact |
outputs[].content_type | string | MIME type (e.g. image/png, video/mp4) |
error | object | null | Error details if failed, null on success |
error.type | string | Machine-readable error type code |
error.message | string | Human-readable error description |
Async Workflow
This model uses asynchronous execution. Submit a request and poll for the result.
- Submit — POST to /v1/run, receive an
id - Poll — GET /v1/run/{id} until status is
completed,failed, ortimeout - Retrieve — Read
outputsfrom the completed response
03
Code Examples
Ready-to-run snippets
# Step 1: Submit
curl -X POST https://api.sandbase.ai/v1/run \
-H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_API_KEY" \
-d '{
"model": "linkedin/bulk/profile-posts",
"includeReposts": true,
"scrapeComments": false,
"scrapeReactions": false,
"includeQuotePosts": true,
"prompt": "a beautiful sunset over mountains"
}'
# Step 2: Poll result (replace <id>)
curl https://api.sandbase.ai/v1/run/<id> \
-H "Authorization: Bearer YOUR_API_KEY"
