Search
Search runs a single query across your account and returns matches grouped by record type. One request looks across environments, tasks, sessions, handbook pages, and pipelines, so you can find something without knowing where it lives.
curl -s "$WALLFACER_API/accounts/$ACCOUNT_ID/search?q=login" \
-H "Authorization: Bearer $WALLFACER_TOKEN" \
| jq ".data"Every record is matched across its text: names, titles, descriptions, and bodies. Results stay inside the account, honor environment visibility, and exclude deleted records.
Query Parameters
| Parameter | Meaning |
|---|---|
q | The search query. Required and cannot be blank. |
types | Comma-separated list limiting which record types to search. Any of environments, tasks, sessions, pages, pipelines. Defaults to all of them. |
per_type | Maximum results per type, from 1 to 25. Defaults to 10. |
cursor | Per-type pagination cursors, keyed by type. Pass cursor[tasks] to continue the tasks results from a previous response. |
Narrow a search to the types you care about with types:
curl -s "$WALLFACER_API/accounts/$ACCOUNT_ID/search?q=login&types=tasks,pages" \
-H "Authorization: Bearer $WALLFACER_TOKEN" \
| jq ".data"Response Shape
The data object always has a key for each requested type, holding an array of results ordered by relevance, highest first. A type with no matches comes back as an empty array.
{
"data": {
"environments": [
{
"id": "019d78bd-4bd3-7173-b53b-8894b6b952b3",
"type": "environment",
"title": "Production API",
"snippet": "Node API with a login service and Postgres",
"score": 0.607927,
"task_id": null
}
],
"tasks": [],
"sessions": [
{
"id": "019e0a1c-1111-7222-8333-444455556666",
"type": "session",
"title": "Fix the login redirect",
"snippet": "the login redirect loops on expired tokens",
"score": 0.303964,
"task_id": "019e0a1b-9999-7000-8111-222233334444"
}
],
"pages": [],
"pipelines": []
},
"meta": {
"per_type": 10,
"next_cursor": {
"environments": null,
"tasks": null,
"sessions": "eyJzIjowLjMwMzk2NCwiaSI6IjAxOWUwYTFjLTExMTEtNzIyMi04MzMzLTQ0NDQ1NTU1NjY2NiJ9",
"pages": null,
"pipelines": null
}
}
}Each result carries an id, a type (one of environment, task, session, page, pipeline), a display title, a snippet of the matched text, a numeric score, and task_id (set only on session results, so you can open the session under its task).
Paginating Results
Each type paginates on its own. When more results of a type exist, meta.next_cursor carries a cursor for that type; a null cursor means the type is exhausted. Pass a cursor back as cursor[<type>], and narrow types to the type you are paging:
curl -s "$WALLFACER_API/accounts/$ACCOUNT_ID/search?q=login&types=sessions&cursor[sessions]=$NEXT_CURSOR" \
-H "Authorization: Bearer $WALLFACER_TOKEN" \
| jq ".data.sessions"For complete parameters and response schemas, see the API Reference.