Endpoints
Complete API reference for the WhatPeoplePayFor Worker API. All endpoints are prefixed with /agent and require a Bearer token.
/agent/bootstrapDiscover available data months, category count, and all queryable endpoints. Call this first to understand what data is available.
Parameters
None
Example
curl -H "Authorization: Bearer wpp_live_..." \ https://api.whatpeoplepayfor.com/agent/bootstrap
Response
{
"data": {
"months": ["2026-03"],
"categories": 274,
"endpoints": {
"ask": "/agent/ask",
"query": "/agent/query/*",
"sse": "/agent/sse/*"
}
}
}/agent/askAsk a natural-language market question. The API returns an answer with supporting evidence and suggested next actions.
Request body
| Field | Type | Description |
|---|---|---|
| question | string | The market question to answer |
Example
curl -X POST \
-H "Authorization: Bearer wpp_live_..." \
-H "Content-Type: application/json" \
-d '{"question": "What are the top growth categories?"}' \
https://api.whatpeoplepayfor.com/agent/askResponse
{
"data": {
"answer": "AI-generated services show the highest growth...",
"evidence": {
"categories_analyzed": 274,
"top_movers": [...]
},
"next_actions": [
"Query snapshots for AI category",
"Check pain points in top categories"
]
}
}/agent/query/snapshotsQuery individual gig snapshots with filtering, sorting, and pagination.
Parameters
| Param | Type | Description |
|---|---|---|
| month | string | Data month, e.g. "2026-03" |
| category_slug | string | Filter by category slug |
| q | string | Full-text search query |
| limit | number | Max results (default 20) |
| offset | number | Pagination offset |
| sort | string | Sort field (e.g. "price", "orders") |
Example
curl -H "Authorization: Bearer wpp_live_..." \ "https://api.whatpeoplepayfor.com/agent/query/snapshots?month=2026-03&category_slug=ai-services&limit=5"
Response
{
"data": [
{
"title": "I will build a custom AI chatbot",
"price": 150,
"orders": 342,
"seller": "ai_expert",
"category_slug": "ai-services",
"month": "2026-03"
}
]
}/agent/query/category-rollupsGet category-level aggregations including average revenue, order counts, and gig counts.
Parameters
| Param | Type | Description |
|---|---|---|
| month | string | Data month |
| limit | number | Max results |
| offset | number | Pagination offset |
| sort | string | Sort field (e.g. "avg_revenue") |
Example
curl -H "Authorization: Bearer wpp_live_..." \ "https://api.whatpeoplepayfor.com/agent/query/category-rollups?month=2026-03&limit=5&sort=avg_revenue"
Response
{
"data": [
{
"category": "AI Services",
"category_slug": "ai-services",
"avg_revenue": 12500,
"avg_orders": 85,
"gig_count": 1240,
"month": "2026-03"
}
]
}/agent/query/pain-pointsGet extracted buyer pain points — common concerns and frustrations that buyers express when purchasing services.
Parameters
| Param | Type | Description |
|---|---|---|
| month | string | Data month |
| category_slug | string | Filter by category slug |
| limit | number | Max results |
Example
curl -H "Authorization: Bearer wpp_live_..." \ "https://api.whatpeoplepayfor.com/agent/query/pain-points?month=2026-03&category_slug=ai-services&limit=5"
Response
{
"data": [
{
"pain_point": "Inconsistent output quality",
"frequency": 42,
"category_slug": "ai-services",
"month": "2026-03"
}
]
}/agent/query/statsGet overall dataset statistics for a given month — total snapshots, categories, and data points.
Parameters
| Param | Type | Description |
|---|---|---|
| month | string | Data month |
Example
curl -H "Authorization: Bearer wpp_live_..." \ "https://api.whatpeoplepayfor.com/agent/query/stats?month=2026-03"
Response
{
"data": {
"total_snapshots": 48200,
"total_categories": 274,
"total_pain_points": 3150,
"month": "2026-03"
}
}/agent/query/monthsList all available data months. Use this to discover which months have data before querying.
Parameters
None
Example
curl -H "Authorization: Bearer wpp_live_..." \ https://api.whatpeoplepayfor.com/agent/query/months
Response
{
"data": ["2026-01", "2026-02", "2026-03"]
}/agent/sse/snapshotsServer-Sent Events stream of gig snapshots. Same parameters as query/snapshots. Results are streamed as individual SSE events for real-time consumption.
Parameters
Same as query/snapshots (month, category_slug, q, limit, offset, sort).
Example
curl -N -H "Authorization: Bearer wpp_live_..." \
"https://api.whatpeoplepayfor.com/agent/sse/snapshots?month=2026-03&limit=5"
data: {"title":"I will build a custom AI chatbot","price":150,"orders":342}
data: {"title":"I will create an AI voice assistant","price":200,"orders":218}
data: [DONE]/agent/sse/category-rollupsServer-Sent Events stream of category rollups. Same parameters as query/category-rollups. Results are streamed as individual SSE events.
Parameters
Same as query/category-rollups (month, limit, offset, sort).
Example
curl -N -H "Authorization: Bearer wpp_live_..." \
"https://api.whatpeoplepayfor.com/agent/sse/category-rollups?month=2026-03&limit=5"
data: {"category":"AI Services","avg_revenue":12500,"avg_orders":85,"gig_count":1240}
data: {"category":"Web Development","avg_revenue":9800,"avg_orders":120,"gig_count":2100}
data: [DONE]