Skip to main content
GET
/
api
/
leads
List unified leads (v0)
curl --request GET \
  --url https://enterprise-api.avoca.ai/api/leads \
  --header 'Authorization: Bearer <token>'
{
  "data": [
    {
      "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
      "datetime": "2023-11-07T05:31:56Z",
      "customer_phone": "<string>",
      "customer_email": "<string>",
      "lead_content": {},
      "agent": "<string>",
      "referrer_url": "<string>",
      "attribution": {
        "utm_source": "<string>",
        "gclid": "<string>"
      }
    }
  ],
  "pagination": {
    "limit": 123,
    "offset": 123,
    "has_more": true
  }
}

Authorizations

Authorization
string
header
required

API key in the format avoca_<64 hex characters>

Headers

x-team-id
integer

Target team ID. Required for multi-team (enterprise_all_teams / portfolio_all_teams) keys on v0 endpoints; single-team keys are locked to their team and omit it.

Query Parameters

start_date
string<date-time>

Start of date range (ISO 8601; default 7 days ago)

end_date
string<date-time>

End of date range (ISO 8601; default now)

type
enum<string>

Filter by lead type

Available options:
call,
scheduling_widget,
web_chat,
text,
google_lsa
limit
integer
default:100

Results per page (default 100, max 1000)

Required range: x <= 1000
offset
integer
default:0

Pagination offset (default 0)

Response

Paginated list of unified leads

data
object[]
pagination
object