PrerequisitesBefore you begin, you’ll need:
- A developer account with an approved App
- Your App’s Bearer Token
Get recent Post counts
1
Build a query
Use the same query syntax as recent search. For example, to count Posts from @XDevelopers:
2
Make the request
cURL
3
Review the response
Granularity options
Control how counts are grouped:| Granularity | Description |
|---|---|
minute | Counts per minute |
hour | Counts per hour (default) |
day | Counts per day |
cURL
Filter by time range
Limit counts to a specific time period:cURL
Common parameters
| Parameter | Description | Default |
|---|---|---|
query | Search query (required) | — |
granularity | Time bucket size | hour |
start_time | Oldest timestamp (ISO 8601) | 7 days ago |
end_time | Newest timestamp (ISO 8601) | Now |