API Documentation
Retrieve leads, calls, and analytics from your AgentIzzy account. All endpoints use Bearer token authentication and return JSON.
Requires Pro or Enterprise plan. Generate an API key in your portal under Settings > Integrations.
Base URL
Authentication
All requests require a Bearer token in the Authorization header. API keys start with aiz_.
Generating a key: Log into portal.agentizzy.com, go to Settings > Integrations, and click Generate API Key. Copy the key immediately — it will not be shown again.
Security: Keys are hashed before storage. You can revoke a key at any time from the Integrations page. All requests are served over HTTPS.
Error Responses
| Status | Meaning |
|---|---|
| 401 | Invalid or missing API key, or account not on Pro/Enterprise plan |
| 500 | Server error |
{ "error": "Invalid or missing API key. Pro or Enterprise plan required." }
/v1/leads
Retrieve all leads captured by your AI phone agent. Returns leads sorted by most recent first.
Query Parameters
| Parameter | Type | Description |
|---|---|---|
| status | string (optional) | Filter by status: new, contacted, follow_up, converted, lost |
Example Request
-H "Authorization: Bearer aiz_your_key"
Response
{
"facilityId": "fac-12345",
"statusCounts": {
"new": 5,
"contacted": 2,
"follow_up": 1,
"converted": 3,
"lost": 0
},
"total": 11,
"leads": [
{
"id": "lead-001",
"firstName": "Sarah",
"lastName": "Johnson",
"phone": "+14155551234",
"email": "sarah@example.com",
"callerPhone": "+14155551234",
"moveIn": "2026-05-01",
"unitSize": null,
"status": "new",
"capturedAt": "2026-04-04T10:30:00Z"
}
]
} Response Fields
| Field | Type | Description |
|---|---|---|
| id | string | Unique lead identifier |
| firstName | string? | Lead's first name (if captured) |
| lastName | string? | Lead's last name (if captured) |
| phone | string? | Lead's contact phone number |
| string? | Lead's email address | |
| callerPhone | string | Phone number the lead called from |
| moveIn | string? | Requested move-in or service date (ISO 8601) |
| unitSize | string? | Requested unit size (storage) or service type |
| status | string | Lead status: new, contacted, follow_up, converted, lost |
| capturedAt | string | When the lead was captured (ISO 8601) |
/v1/calls
Retrieve call history with AI summaries and sentiment analysis. Returns calls sorted by most recent first.
Query Parameters
| Parameter | Type | Description |
|---|---|---|
| limit | integer (optional) | Number of calls to return. Default: 50, max: 100 |
Example Request
-H "Authorization: Bearer aiz_your_key"
Response
{
"facilityId": "fac-12345",
"stats": {
"totalCalls": 42,
"leadsCaptures": 8,
"avgDuration": 180
},
"calls": [
{
"id": "call-001",
"callSid": "CA-abc123",
"callerNumber": "+14155551234",
"startedAt": "2026-04-04T10:28:00Z",
"endedAt": "2026-04-04T10:32:15Z",
"durationSeconds": 255,
"tag": "new_lead",
"aiSummary": "Caller asked about emergency plumbing repair...",
"sentiment": "positive"
}
]
} Response Fields
| Field | Type | Description |
|---|---|---|
| id | string | Unique call identifier |
| callSid | string | Twilio Call SID |
| callerNumber | string | Phone number of the caller |
| startedAt | string | Call start time (ISO 8601) |
| endedAt | string? | Call end time (ISO 8601) |
| durationSeconds | integer | Call duration in seconds |
| tag | string | Call classification: new_lead, general, missed, spam |
| aiSummary | string? | AI-generated summary of the call |
| sentiment | string? | Call sentiment: positive, neutral, negative |
/v1/analytics
Retrieve aggregated analytics including call volume trends, lead conversion rates, busiest hours, and performance comparisons across time periods.
Query Parameters
| Parameter | Type | Description |
|---|---|---|
| days | integer (optional) | Number of days to analyze. Default: 30, max: 90 |
Example Request
-H "Authorization: Bearer aiz_your_key"
Response
{
"facilityId": "fac-12345",
"period": { "days": 7 },
"current": {
"totalCalls": 42,
"leadsCaptures": 8,
"avgDuration": 180,
"captureRate": 19
},
"previous": {
"totalCalls": 38,
"leadsCaptures": 6,
"avgDuration": 165
},
"callsPerDay": [ ... ],
"callsByTag": { "new_lead": 8, "general": 30, "spam": 4 },
"callsByHour": [ ... ],
"callsByDayOfWeek": [ ... ],
"leadsByStatus": { "new": 5, "contacted": 2, "converted": 3 }
} Response Fields
| Field | Type | Description |
|---|---|---|
| period.days | integer | Number of days in the analysis period |
| current | object | Stats for the current period (totalCalls, leadsCaptures, avgDuration, captureRate) |
| previous | object | Stats for the previous equivalent period (for comparison) |
| callsPerDay | array | Daily call counts for the period |
| callsByTag | object | Call counts by tag (new_lead, general, missed, spam) |
| callsByHour | array | Call distribution by hour of day (0-23) |
| callsByDayOfWeek | array | Call distribution by day of week |
| leadsByStatus | object | Lead counts by status |
Rate Limits
API requests are rate-limited to prevent abuse. Current limits are generous for typical use cases. If you encounter rate limiting, reduce your request frequency or contact support.
Zapier Integration
Don't want to build against the API directly? Use our Zapier integration to connect AgentIzzy to 9,000+ apps with no code. Available triggers:
- New Lead — triggers when a lead is captured from a call
- New Call — triggers when a call is completed
Ready to get started?
Generate your API key and start building integrations in minutes.