Skip to main content
GET
List calls
Every call this workspace has placed or answered, newest first — phone and browser alike. Required scope: calls:read. This is the end of every journey: you placed a call with POST /calls, ran a campaign, or let a number take an inbound call, and this is where the outcome, the recording and the matched lead come back.
Any other query parameter is 400 CALLS_QUERY_INVALID: a filter this list cannot apply is refused rather than dropped, because a dropped filter comes back as the whole workspace’s calls with an unchanged pagination.total. A filter this list does know, sent with nothing in it — ?agent_id= — is refused the same way and for the same reason. Leave the parameter out rather than sending it empty. Filters combine with AND. Counting prior attempts to one contact today is one request: ?agent_id=…&callee=+9725…&from=<midnight> and read pagination.total.

Response

Fields that are absent rather than null

recording_url, disposition, lead, shared_link_id, sip_endpoint_id, failure and ab_variant are omitted from a row that has none, rather than sent as null. Read them with a presence check, not a null check. disposition and lead are full objects, so a list of calls never needs a follow-up request to label the outcome or identify the contact. lead is the full object for a key that also holds leads:read; without it the row carries { "id" } only — the rest is what Get Lead needs that scope for.
  • from and to are empty strings on a browser call — a web_call has no phone leg on either side.
  • A call that arrived on a SIP endpoint is source: phone_inbound with to: null and carries sip_endpoint_id. A SIP address endpoint’s address is its credential, so this API does not return it; what a call on a username-and-password trunk dialled (a number or an extension) shows in the dashboard’s call log instead. Its from is whatever your phone system sent as the caller, which may not be a phone number, and null when the caller ID was only a username-and-password trunk’s own username.
  • metadata is the object you attached — on POST /calls, phone or web — exactly as Get call returns it, so a sync can match its own ids from the list without one request per call. Internal bookkeeping (retry counters, carrier ids, error text and when it was recorded, the browser session) is removed. Some keys the platform adds do stay, and this is not an exhaustive list: ab_variant and ab_variant_fallback when a split picked the agent, share_link_id on a call from a share link, agent_id on a test call started from the dashboard, queued, queue_id and queue_wait_seconds on a call that waited for a free line, and workflow_request_id on a call started from a call request, and, on a call that spoke, timezone, timezone_source and timezone_unconfirmed (the zone the agent’s clock ran in; see Get call). A timezone key you attach yourself is never replaced. Name your own keys so they cannot collide with these.
  • agent is the agent behind agent_id — {id, name, archived_at}, read with the call, so an archived agent’s name is still in the list (GET /agents/{id} answers 404 for it). archived_at is null while the agent is not archived. Every key gets these three members; Get call embeds the whole agent for a key with agents:read. null on a call with no agent.
  • ended_by is who hung up: caller, agent, system, operator, unknown when the carrier did not say, or null when nothing recorded it — a call still running, or one no producer attributed, which many older calls are. It is written once and never overwritten by a later, vaguer answer. The dashboard shows it as Ended by on the call details and in its Export CSV; GET /calls/export writes it in its Ended by column.
  • disconnect_reason is a display label, not a branch key. Branch on status and ended_by; show disconnect_reason to a person.
  • duration_seconds is the connected duration, read as Get call reads it: null while a call is still in progress and on every call that was never answered (nobody picked up, or no browser connected, and no answer was recorded), a whole number on every call that was — including a connected call whose voice server recorded no answer, which is counted from the earliest evidence that it connected, as Get call’s answered_at reads it. ended_at is never before started_at. It never exceeds the agent’s max_call_duration_secs plus 60 seconds (4 hours with no cap, or after a transfer to a person), and neither does the charge.
  • recording_url is a signed URL that opens in a browser or audio player with no further authentication. It appears once the recording is stored, which is shortly after the call ends — a completed call fetched immediately may not carry one yet. It is left out for a call whose recording can no longer be fetched, so a link you are handed opens. It lasts 7 to 8 days and can be revoked; read the call again for a current one (how links work).
  • source is where the call came from, and is the answer to “what did my own testing cost, versus the link I sent out”. test is a rehearsal you started yourself — the agent’s Test tab, or a test phone call from the dashboard. shared_link is a call someone made through a shared link, and those rows also carry shared_link_id, so spend can be attributed to the link you handed out. api is a browser session this API minted. phone_inbound and phone_outbound are the two phone legs — real calls only: a test call you dial from the dashboard reads test and is counted there, not here, which is the separation the filter exists for. A call recorded before any of this was written reads unknown, which is the one value ?source= will not accept: asking for it would be asking for whatever was never written down.
  • provider is whose carrier the phone side ran on: external — your own Telnyx account, which billed you for the phone minutes, so cost_cents is Yappr’s charge beside that bill; telnyx — a number bought from Yappr or a SIP endpoint, the word GET /phone-numbers uses for such a number; null on a browser call. carrier_account (id, name, provider, status) is the account an external call ran on, and null on every other call and for a key without carrier_accounts:read. carrier_call_id, on an external call only, is the id Telnyx gave the call on your account, to find it in your Telnyx records (null for a key without carrier_accounts:read). Get call has the detail.
  • cost_cents is what this one call consumed, in credits, and is the same number Get call returns. cost_status says whether it is final: charged (the charge), not_charged (0 — the call failed, was not answered, was blocked, or completed with no connected time) or pending (null — still running, or the charge is not recorded yet). Only pending rows are worth coming back for, and none stays pending more than 24 hours after its call ended: a charge not recorded by then is not coming, and the row reads 0 / not_charged from then on. That one change is read off the clock rather than written to the row, so it does not move updated_at — re-read the pending rows you hold rather than waiting for updated_since to return them. A month’s spend is this list summed, not one request per call; workspace-level aggregates live in GET /billing/consumption.
  • failure says why a call did not complete: a stable code to branch on, one reason sentence to show a person, the stage it reached (dialing, connecting or conversation) and at. It is the same object Get call returns, and it is absent on a call that completed. disconnect_reason only repeats the status on a failure; failure.code is the cause.
  • updated_at is when the row last changed, and is what an incremental sync must window on. Almost everything worth coming back for settles after the call row is created — status, ended_at, duration_seconds, cost_cents, the matched lead, the disposition and the whole analysis object — so a sync windowed on created_at reads each call exactly once, at its youngest and emptiest, and never learns that any of it landed. Every change to analysis moves it too, including a pass that never landed: that failed / analysis_unavailable is written onto the call within five minutes of the ten-minute mark, not only read off the clock. So do revoking the call’s recording links (a new recording_url) and deleting its lead (lead becomes null). A change to the lead itself — its name, email or tags — moves the lead’s own updated_at, not the call’s. Calls recorded before this field existed carry the last moment they can be proved to have changed. Get call answers with the same field, so a loop that pages this list and then follows a call by id keeps the timestamp it windows on.
  • analysis says where the call’s post-call pass stands — pending, done, skipped or failed, with a reason for which case it is. It is on every row, so a sync can page this list and act on each call without a second request per call: rows reading done have whatever the pass produced waiting on Get call, rows reading pending are worth coming back for, and skipped rows never will be. It is the same object Get call returns, and that page carries the reason table and how long to wait.
  • recording_started_at is when the call’s recording began, as Get call reads it: the transcript’s start and end are milliseconds from here. null on a browser call, on a call whose recording is not saved yet, and on older calls recorded before the field was added.
  • The list does not carry the call’s transcript; read that from Get call.
  • summary and answered_at are not on list rows: read them from Get call.

Paging

Two ways, and they are not interchangeable. offset is the default and is fine for a person looking at a page of results. It counts from the top of a list that moves while you read it: this workspace’s pagination.total went from 935 to 937 between two requests, and every row that arrived in between pushed one row off page 1 and onto page 2, where it was read a second time. cursor is the one to build a job on. pagination.next_cursor is the last row of the page you just read, so the next page continues from exactly there whatever has been written since. Follow it until has_more is false:
next_cursor is on every page, including the first one you asked for with no paging parameter at all, so switching costs nothing. Sending cursor and offset together is 400 CALLS_QUERY_INVALID, and a cursor this endpoint did not issue — built by hand, edited, or taken from GET /deliveries — is 400 CALLS_CURSOR_INVALID rather than a silent first page: cursors are signed, so only one this endpoint cut decodes. A cursor also carries the filters of the page that returned it: send it with exactly those filters (limit may change). With other filters — a different updated_since, or none — it is 400 CALLS_CURSOR_INVALID too, saying so, instead of silently continuing a different list. While you are paging by cursor, pagination.total counts the calls still ahead of you rather than the size of the whole list.

Keeping a copy in step

updated_at is stamped when a change starts being written, and the change is readable only once the write finishes — and your clock is not ours. So a window that starts exactly where the last one ended can skip a change for good: it becomes visible after you have read past the moment it carries. Overlap the windows and de-duplicate instead:
  1. Record the time before the run starts.
  2. Ask for updated_since = the last run’s recorded time minus five minutes, and page it by cursor to exhaustion.
  3. Upsert each call by id, keeping whichever copy has the newer updated_at. The overlap hands you some calls twice; that is the point of it.
  4. Store the time from step 1 for the next run.
A call that changes while you are paging keeps its place — the cursor walks by when a call was created, which a change never moves — and the next run reads it again, because its new updated_at falls inside that run’s window. Five minutes covers a slow write and ordinary clock drift; widen it if the machine running the sync does not keep its clock in step.

A call in flight

A call that is still running is listed with status: "in_progress" and no ended_at. Poll Get call for one call rather than re-listing the page. A browser session you minted with POST /calls {"type":"web"} is listed from the moment the mint answers, under the call_id it returned, with status: "pending_connection" — minted, nobody connected yet. It turns ringing when the browser connects, and if nobody does it settles no_answer with failure.code: "session_expired" and ended_by: "system" as soon as its token has expired unused: this list, GET /calls/{id} and the export settle it when they read it after expires_at, before they count, so ?status=pending_connection never lists one whose token is gone. Unread, it settles at the next five-minute sweep. A token a browser spent on a connection that never came up settles a minute after expires_at. POST /calls/{id}/end ends one at once.

Errors

Every answer from this list carries a Server-Timing header — auth, filters, page, settle, enrich and total, each in milliseconds — so a slow read says where its time went. Read it when you report one to support; do not build on the step names.

Authorizations

Authorization
string
header
required

Your Yappr API key (e.g. ypr_live_...). Generate one in the dashboard under Settings → API Keys. No key is 401 MISSING_KEY; a key that is not one of ours, or is revoked, is 401 INVALID_KEY; an expired one is 401 EXPIRED_KEY. A valid key without the scope an operation needs is 403 INSUFFICIENT_SCOPE on every operation, and the message names the scope. Every response, a 401 included, carries X-RateLimit-Limit, X-RateLimit-Remaining and X-RateLimit-Reset: the budget is 60 requests a minute per API key. Every 429, whatever its code, carries Retry-After (whole seconds, never zero): the per-key budget's RATE_LIMIT asks for what is left of the minute, a route's daily cap (RATE_LIMITED) for the time until that cap resets. All four headers are listed in Access-Control-Expose-Headers, so a browser can read them. A path the API does not serve (an unknown sub-path, an id left empty) is 404 ROUTE_NOT_FOUND, and a method a served path does not take is 405 METHOD_NOT_ALLOWED with an Allow header; both are answered before any scope check, and nothing is read or changed. A trailing slash is ignored where it cannot be an id left empty (POST /calls/ is POST /calls) and refused where it can (GET /calls/). A doubled slash inside a path is merged into one before the request reaches the API (GET //calls is GET /calls).

Query Parameters

limit
integer
default:20
Required range: x <= 100
offset
integer
default:0

Count from the top of the list. Send this or cursor, not both - both together is 400 CALLS_QUERY_INVALID, because applying one of them silently is how a paging loop reads the same rows twice.

cursor
string

Continue exactly where the last page stopped. Opaque; take it from pagination.next_cursor, which every page carries. This list grows while it is being read, so an offset silently repeats or skips rows and a cursor does not. A cursor this endpoint did not issue - one built by hand, edited, or taken from GET /deliveries - is 400 CALLS_CURSOR_INVALID rather than a silent first page: cursors are signed. While paging by cursor, pagination.total counts the calls still ahead.

agent_id
string<uuid>

Only calls this agent took or placed, by the id GET /agents returns. Anything that is not an id is 400 CALLS_QUERY_INVALID naming the parameter, rather than reaching the uuid column unchecked, and an id that is not an agent in this workspace is 404 AGENT_NOT_FOUND (it was CALL_AGENT_UNKNOWN) rather than an empty page that reads as "no calls".

status
enum<string>

Filter by call status. pending_connection is a browser session minted with POST /calls {type: web} that nobody has connected to yet. Anything outside the list is 400 CALLS_QUERY_INVALID naming the statuses calls really have, rather than reaching the enum column unchecked.

Available options:
pending_connection,
ringing,
in_progress,
completed,
failed,
no_answer,
transferred,
dnc_blocked
direction
enum<string>
Available options:
inbound,
outbound,
web_call
callee
string

Filter by callee (destination) phone number, matched in E.164 when written with its country code (a bare + included); an Israeli number written +972…, 972… or 05… finds the same calls, and other digits (an extension, a number without its country code) are matched exactly as sent. Useful for counting prior attempts to a specific lead — e.g. retry-throttle logic: ?agent_id=X&callee=+972Y&from=TODAY then read data.length directly.

caller
string

Filter by caller (source) phone number, read the same way as callee.

ab_variant
enum<string>

Return only calls answered or placed by one side of a number's A/B test. a is the number's own agent, b the second agent. Calls on a number with no split carry no variant and are excluded by this filter.

Available options:
a,
b
disposition
string

Only calls that ended with this outcome, by the disposition's label exactly as GET /dispositions returns it. A label no disposition in this workspace carries is 404 CALL_DISPOSITION_UNKNOWN rather than an empty page.

disposition_id
string<uuid>

The same outcome filter by id. Send this or disposition, not both. An id that is not a disposition in this workspace is 404 CALL_DISPOSITION_UNKNOWN rather than an empty page.

source
enum<string>

Only calls that came from here. test is a rehearsal you started yourself (the agent's Test tab, or a test phone call from the dashboard); shared_link is a call made through a shared link; api is a browser session this API minted; phone_inbound and phone_outbound are the two phone legs, real calls only - a test call dialled from the dashboard is returned by source=test and not by source=phone_outbound. Anything else is 400 CALLS_QUERY_INVALID. A call recorded before its origin was written reads "unknown" and cannot be filtered for.

Available options:
test,
shared_link,
api,
phone_inbound,
phone_outbound
carrier_account_id
string<uuid>

Only calls on this carrier account - your own Telnyx account, as GET /carrier-accounts returns it: every call it signed for, placed from or answered on one of its numbers, outbound and inbound alike (a refused dial included). Needs carrier_accounts:read, like the carrier_account on each call - 403 INSUFFICIENT_SCOPE without it. Anything that is not an id is 400 CALLS_QUERY_INVALID; an account that is not in this workspace is 404 CARRIER_ACCOUNT_NOT_FOUND rather than an empty page.

provider
enum<string>

Only calls on this carrier, as each call's provider says: external - your own Telnyx account (signed for a carrier account, or placed from one of its numbers); telnyx - a number bought from Yappr, or a SIP endpoint; none - a browser call, which has no phone side (provider null). Needs no scope beyond calls:read, like provider itself. Anything else is 400 CALLS_QUERY_INVALID.

Available options:
external,
telnyx,
none

What the dashboard's Call Logs search box takes, in one parameter. The start of a call id - 8 or more of its hex characters, with dashes where an id has them, so the 8 the dashboard shows are enough - finds the calls whose id starts with it. A phone number finds the calls with it at either end, read the way callee and caller read it. Anything else is part of an agent's or a lead's name, case-insensitive; a lead deleted since does not count. A lead's name is searched only for a key with leads:read, the scope that reads it; for any other key a name matches agents alone. Digits that could be both (0501234567) are searched both ways. A name more than 300 agents and leads share (agents alone, without leads:read) is 400 CALLS_QUERY_INVALID, as is a search under 2 or over 100 characters.

Required string length: 2 - 100
lead_id
string<uuid>

Only calls with this lead, by the id GET /leads returns - the one way to find a browser call attached to a lead, which has no number at either end. Anything that is not an id is 400 CALLS_QUERY_INVALID; a lead that is not in this workspace, or was deleted, is 404 NOT_FOUND rather than an empty page.

from
string<date-time>

Return calls created on or after this ISO 8601 timestamp - a date, or a date and time with Z or an offset. Any other shape (2026, Sep 1, 2026/09/01) and a day its month does not have - 2026-09-31, the month-end a report script guesses - is 400 CALLS_QUERY_INVALID rather than a failed read or a window silently rolled forward to October 1. URL-encode a positive offset's + as %2B: a query string reads a bare + as a space, and the refusal says so when that is what happened.

to
string<date-time>

Return calls created on or before this timestamp. Validated the same way as from. A date-only value covers that whole day (UTC): to=2026-08-31 ends at 2026-08-31T23:59:59.999999Z, so from=2026-08-01&to=2026-08-31 is all of August.

updated_since
string<date-time>

Every call that has CHANGED at or after this timestamp, whatever its created_at. This is the filter an incremental sync wants: status, ended_at, duration_seconds, cost_cents, the matched lead, the disposition and the whole analysis object all settle after the row is created - an analysis that never landed included, which is written onto the call as failed / analysis_unavailable within five minutes of the ten-minute mark (for a workflow agent's call, once no retry is still due) - so a sync windowed on created_at reads each call once, at its youngest and emptiest, and never learns that any of it landed. Record the time before a run starts, ask the next run from a few minutes before it, and upsert by id keeping the newer updated_at: a change is stamped when its write starts and readable only once it finishes, so windows that merely touch can skip one.

Response

List of calls

data
object[]
pagination
object