Skip to content

Workspace API

Search Accounts

Search the accounts you have saved in your workspace with POST /workspace/accounts/search.

Endpoint
POST https://api.parcelengineering.com/api/v1/workspace/accounts/search

This endpoint searches only the accounts you have saved and annotated in your workspace (your book), not the global Parcel dataset. It does not accept view_id. For Dynamic or Static View execution over the broader Accounts browse base, use POST /workspace/views/{id}/records/search. To find new accounts to track, use the Data API accounts search first, then upsert them into your workspace.

Query parameters

ParameterDescription
workspace_idAttribution. Required when authenticating with a user JWT (for example, via the MCP server). Optional for API keys. Omitting it on a user-token request returns 400 bad_request.

Request body

All fields are optional. An empty body returns the first 25 accounts sorted by updated_at descending.

FieldTypeDefaultDescription
querystring (min 1)(none)Full-text search term matched against account name and aliases.
whereobject(none)The condition: rules of { field, operator, value } in and / or groups. See Filtering with where and the fields for accounts. A body with the old filters key is a 400.
sort.fieldstringupdated_atSort field. Must be a valid sort key (see below). Required when sort is present.
sort.orderasc | descdescSort direction.
limitinteger 1..10025Records per page.
offsetinteger 0..100000Zero-based record offset for pagination.
search_afterstring(none)Opaque keyset cursor from the previous response’s metadata.search_after. Pass it to fetch the next page.

Sort keys

Valid sort fieldsDefault
updated_at, icp_score, name, created_at, projects_countupdated_at (desc)

Unscored accounts sort last under icp_score, and a search_after cursor stops where they begin; page on with offset, or sort by another key.

Example

Search workspace accounts
curl -X POST https://api.parcelengineering.com/api/v1/workspace/accounts/search \
-H "Authorization: Bearer pcl_your_api_key" \
-H "Content-Type: application/json" \
-d '{
"where": {
"combinator": "and",
"rules": [
{ "field": "type", "operator": "in", "value": ["developer"] },
{ "field": "project.city", "operator": "in", "value": ["Boston"] },
{ "field": "project.use", "operator": "in", "value": ["multifamily"] },
{ "field": "score", "operator": "between", "value": [75, 100] }
]
},
"sort": { "field": "icp_score", "order": "desc" },
"limit": 25
}'

Response

Response
{
"data": [
{
"id": "8a1f3c2e-0001-4b7d-9e5a-000000000001",
"name": "Acme Development Group",
"account_types": ["developer"],
"domains": ["acmedev.com"],
"website": "https://acmedev.com",
"workspace_status": "active",
"notes": "Met at BuildBoston 2025",
"tags": ["boston", "developer"],
"projects_count": 12,
"contacts_count": 4,
"icp_score": 83,
"scores": {
"icp": { "score": 83, "bucket": "tier_1", "matched": ["stakeholder", "in_market", "in_sector"] }
}
}
],
"metadata": {
"total": 4,
"total_is_capped": false,
"limit": 25,
"offset": 0,
"search_after": null,
"credits": 0.4
}
}

The data array is trimmed to one record above. scores.icp is null for an unscored account; matched lists the ids of the criteria it matched. A page returning 4 accounts costs up to 0.40 credits.

Metadata fields

FieldDescription
totalMatch count, capped at 1,000. When more than 1,000 accounts match, total reports 1000 and total_is_capped is true.
total_is_cappedtrue when the actual count exceeds the cap.
limitPage size, echoed back from the request.
offsetEchoed back from the request, or 0 when paging with search_after.
search_afterOpaque cursor for the next page, or null on the last page.
creditsCredits this request charged: the records in it your workspace had not taken out in the last 30 days.