---
title: "Count the approval queue"
method: GET
path: "/outreach-tasks/length/"
tags: ["outreach"]
---

# Count the approval queue

`GET /outreach-tasks/length/`

## Request

- Base URL: `https://api.getoneprofile.ai` (the document declares no server; this is the origin it was published from)
- URL: `https://api.getoneprofile.ai/outreach-tasks/length/`
- Auth: one of:
  - API key in header `X-API-Key`
  - HTTP bearer

How many tasks the list's filters select, for the Tasks page's total, and the reasons the tasks every other filter selects wait for a person, for its Held because filter. Takes exactly the list's filters.

## Query parameters

- `status` TaskStatus[]: Only these statuses; repeat the parameter for several. Defaults to pending.
- `channel` TaskChannel[], nullable: Only these channels; omit for every channel.
- `kind` string[], nullable: Only these kinds: a LinkedIn action slug (`profile_view`, `connection_request`, …) or `email`. Omit for every kind.
- `sender_profile_id` string[], nullable: Only these senders; omit for everyone.
- `sequence_id` string[], nullable: Only these sequences; omit for all of them.
- `enrolment_id` string[], nullable: Only the tasks of these contacts, by their enrolment in a sequence; omit for everyone.
- `waiting_since_before` string, date-time, nullable: Only tasks that entered the queue before this instant, which is 'waiting longer than'. Read off when the task was created, not when its channel would run it. Omit for however long they have been here.
- `outcome` string[], nullable: Only tasks that ended with one of these words (repeatable): `failed`, `skipped`, `stopped`, `succeeded` and the like. The tasks that failed are `status=cancelled` with `outcome=failed`. Omit for however they ended.
- `ask_reason` AskReason[], nullable: Only tasks held for a person for one of these reasons (repeatable): the Tasks page's Held because. Omit for every reason.
- `search` string, nullable: Words that must each appear in the contact's name, address or LinkedIn profile, or in the subject.
- `background_checks` 'hide' | 'include' | 'only': Whether a reading of Activity lists our own LinkedIn reads of the sender's account. The reads (``BACKGROUND_CHECK_KINDS``: the inbox, the sent invitations, the newest connections, one conversation) act on nobody, so every Activity page hides them unless a person turns them on (Utku, 2026-10-19: behind a filter, so a customer worried about their LinkedIn account can see every time we touched it). ``HIDE`` leaves them out, ``INCLUDE`` lists them with everything else, ``ONLY`` lists them alone.

## Response `200`

Successful Response

- OutreachTaskLengthSchema: How many tasks the queue's filters select, and why they wait: the footer and Held because.
  - `ask_reasons` AskReason[], required: Why the tasks every other filter selects are held for a person, the reasons Held because can narrow them to: `ask_reason` itself is left out of this read, so picking one never hides the others. Empty when none of them carries a reason.
  - `count` integer, required: How many tasks match the filters.

## Other responses

- `401`: Unauthorized
- `403`: Forbidden
- `422`: Invalid request made to the API.
- `500`: Internal server error.
- `502`: Bad gateway error.
- `503`: Service unavailable.

## Changes

- **2026-10-20** `dc5ac3c84444`: 1 info
  - added the new optional `query` request parameter `background_checks`

[Operation history](https://skmtc.dev/getoneprofile/apis/api-reference-oneprofile/changes/outreach-tasks/length/get.md)

---

[API](https://skmtc.dev/getoneprofile/apis/api-reference-oneprofile.md) · [All operations](https://skmtc.dev/getoneprofile/apis/api-reference-oneprofile/llms.txt) · [OpenAPI document](https://skmtc.dev/getoneprofile/apis/api-reference-oneprofile/revisions/dc5ac3c84444?raw)
