Datasets API endpoint
Returns value counts for the PitchBook companies dataset by the required `facet`: `status`, `primary_industry`, `financing_status`, `ownership_status`, `hq_country`, `hq_state` or `run_id`. Filters such as `q`, `min_year_founded` and `min_investor_count` apply, and the top 50 values come back.
/datasets/pitchbook-companies/facetsReturns terms-aggregation counts for one field over the PitchBook companies dataset, honoring the same filters as search.
Query parameters:
facet (required) — one of status, primary_industry, financing_status, ownership_status, hq_country, hq_state, run_id.q, status, primary_industry, financing_status, ownership_status, hq_country, hq_state, run_id, min_year_founded, max_year_founded, min_investor_count) apply.Returns {dataset, facet, items:[{value, count}]} (top 50 buckets).
| Field | Filled in, of 50 checked | Values in the sample |
|---|---|---|
| value | 50 | |
| count | 50 | 2,066 to 589,391, median 7,088 |
| Parameter | Type | Required | Default | Description | Example |
|---|---|---|---|---|---|
| facet | string | Yes | Facet enum: status, primary_industry, financing_status, ownership_status, hq_country, hq_state, run_id Allowed values: status, primary_industry, financing_status, ownership_status, hq_country, hq_state, run_id. | status | |
| q | string | No | Full-text query over name and description, max 256 characters | ||
| status | string | No | Exact status filter, max 128 characters | ||
| primary_industry | string | No | Exact primary industry filter, max 128 characters | ||
| financing_status | string | No | Exact financing status filter, max 128 characters | ||
| ownership_status | string | No | Exact ownership status filter, max 128 characters | ||
| hq_country | string | No | Exact headquarters country filter, max 128 characters | ||
| hq_state | string | No | Exact headquarters state/region filter, max 128 characters | ||
| run_id | string | No | Exact crawl run-id filter, max 128 characters | ||
| min_year_founded | integer | No | Minimum founding year | ||
| max_year_founded | integer | No | Maximum founding year | ||
| min_investor_count | integer | No | Minimum number of investors | ||
| x-api-key (header) | string | Yes | API key required |
curl -X GET "https://api.crawlora.net/api/v1/datasets/pitchbook-companies/facets?facet=status&q=coffee" \ -H "x-api-key: $CRAWLORA_API_KEY"
{
"code": 200,
"msg": "OK",
"data": {
"dataset": "pitchbook-companies",
"facet": "status",
"items": [
{
"value": "Private",
"count": 8412
},
{
"value": "Public",
"count": 193
}
]
}
}Request schema
No body schema
Response schema
#/definitions/datasets.pitchbookCompaniesFacetResponseDoc
| Field | Type | Required | Enum | Bounds | Example | Description |
|---|---|---|---|---|---|---|
| code | integer | No | 200 | |||
| data | datasets.PitchbookCompaniesFacetResponse | No | ||||
| data.dataset | string | No | ||||
| data.facet | string | No | ||||
| data.items | array | No | ||||
| data.items[].count | integer | No | Number of records with this value. | |||
| data.items[].value | string | No | Facet value being counted. | |||
| msg | string | No | OK |
| Status | Description | Schema |
|---|---|---|
| 400 | Bad Request | #/definitions/app.Response |
| 429 | Too Many Requests | #/definitions/app.Response |
| 500 | Internal Server Error | #/definitions/app.Response |
Use environment variables for secrets and keep Crawlora API keys server-side.
curl -X GET "https://api.crawlora.net/api/v1/datasets/pitchbook-companies/facets?facet=status&q=coffee" \
-H "x-api-key: $CRAWLORA_API_KEY"