Posts
Search, filter, and retrieve scraped Reddit posts.
GET
/api/v1/workspaces/{workspace_id}/postsList Posts
Search and filter scraped posts with advanced options. Supports cursor-based pagination.
Path Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| workspace_id | uuid | Required | Workspace ID |
Query Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| q | string | Optional | Full-text search query |
| subreddit | string | Optional | Filter by subreddit name |
| author | string | Optional | Filter by author username |
| min_score | integer | Optional | Minimum post score |
| max_score | integer | Optional | Maximum post score |
| post_type | string | Optional | Filter by type (link, self, image, video) |
| sentiment | string | Optional | Filter by sentiment (positive, negative, neutral) |
| sort_by | string | Default: created_utc | Sort field |
| sort_order | string | Default: desc | asc or desc |
| limit | integer | Default: 50 | Max results (1-200) |
| cursor | string | Optional | Pagination cursor from previous response |
Code Examples
bash
curl "https://api.sentrasa.com/api/v1/workspaces/{workspace_id}/posts?q=AI&subreddit=technology&min_score=100&limit=20" \
-H "X-API-Key: rp_your_api_key"Response
200Paginated post listjson
{
"posts": [
{
"id": "t3_abc123",
"subreddit": "technology",
"title": "New AI breakthrough announced",
"author": "tech_guru",
"created_utc": "2026-03-20T10:00:00Z",
"score": 1542,
"upvote_ratio": 0.95,
"num_comments": 234,
"selftext": "Today a major breakthrough...",
"post_type": "self",
"sentiment_label": "positive",
"sentiment_score": 0.82
}
],
"total": 1,
"cursor": "eyJpZCI6InQzX2FiYzEyMyJ9",
"has_more": false
}GET
/api/v1/workspaces/{workspace_id}/posts/{post_id}Get Post
Get full details of a single scraped post.
Path Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| workspace_id | uuid | Required | Workspace ID |
| post_id | string | Required | Reddit post ID (e.g. t3_abc123) |
Code Examples
bash
curl https://api.sentrasa.com/api/v1/workspaces/{workspace_id}/posts/t3_abc123 \
-H "X-API-Key: rp_your_api_key"Response
200Post detailsjson
{
"id": "t3_abc123",
"workspace_id": "ws_550e8400-e29b-41d4-a716-446655440000",
"subreddit": "technology",
"title": "New AI breakthrough announced",
"author": "tech_guru",
"created_utc": "2026-03-20T10:00:00Z",
"permalink": "/r/technology/comments/abc123/new_ai_breakthrough/",
"url": null,
"score": 1542,
"upvote_ratio": 0.95,
"num_comments": 234,
"selftext": "Today a major breakthrough was announced...",
"post_type": "self",
"is_nsfw": false,
"is_spoiler": false,
"flair": "Discussion",
"total_awards": 5,
"has_media": false,
"media_urls": [],
"sentiment_score": 0.82,
"sentiment_label": "positive",
"keywords": [
"AI",
"breakthrough",
"technology"
],
"scraped_at": "2026-03-20T14:00:00Z"
}GET
/api/v1/workspaces/{workspace_id}/posts/subreddits/listList Subreddits
Get all subreddits with post counts in the workspace.
Path Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| workspace_id | uuid | Required | Workspace ID |
Code Examples
bash
curl https://api.sentrasa.com/api/v1/workspaces/{workspace_id}/posts/subreddits/list \
-H "X-API-Key: rp_your_api_key"Response
200Subreddit list with countsjson
[
{
"subreddit": "technology",
"post_count": 450
},
{
"subreddit": "programming",
"post_count": 320
}
]