REST API · Webhooks · OpenAPI spec v1

Your AR system.
Our collection engine.

Simple REST API. Upload invoices, receive payment webhooks. No middleware. No agents. No friction.

Request API access See the docs
JSON REST Webhooks OAuth 2.0 OpenAPI 3.1
api.agentcollect.com — POST /v1/campaigns
$ curl -X POST https://api.agentcollect.com/v1/campaigns \
-H "Authorization: Bearer sk_live_..." \
-d '{"company":"Acme Corp","invoice_amount":15000}'
{
  "id": "cmp_9xQk4Fw2",
  "status": "active",
  "first_contact_at": "2026-03-17T15:00:00Z",
  "message": "Collection started. Webhook fires on payment."
}
$
Live in 5 minutes

Three API calls. Authenticate, upload your invoices, and start receiving payment webhooks.

Step 01
Authenticate
~30 seconds
Step 02
Upload invoices
~2 minutes
Step 03
Receive payment webhook
When debtor pays
bash — authenticate.sh
# Exchange your API key for a Bearer token
curl -X POST https://api.agentcollect.com/v1/auth \
  -H "Content-Type: application/json" \
  -d '{"api_key": "your_key_here"}'

# Response
{
  "access_token": "eyJhbGci...",
  "token_type": "Bearer",
  "expires_in": 3600,
  "scope": "campaigns:write payments:read"
}
API keys are scoped per environment. Use sk_test_... for sandbox and sk_live_... for production.
bash — create_campaign.sh
curl -X POST https://api.agentcollect.com/v1/campaigns \
  -H "Authorization: Bearer YOUR_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "company": "Your Company Inc.",
    "debtors": [{
      "company_name": "Acme Corp",
      "contact_email": "ap@acmecorp.com",
      "invoice_amount": 15000,
      "invoice_date": "2025-10-01",
      "invoice_number": "INV-2025-0847"
    }]
  }'

# Response
{
  "campaign_id": "cmp_9xQk4Fw2",
  "status": "active",
  "debtors_enrolled": 1,
  "total_amount": 15000,
  "first_contact_at": "2026-03-17T15:00:00Z"
}
You can enroll up to 500 debtors per campaign. Batch imports via CSV are also available — pass "source": "csv_url" with a signed S3 URL.
json — webhook payload (payment.received)
{
  "event": "payment.received",
  "id": "evt_Kp2mZxQ8",
  "created_at": "2026-03-17T14:22:00Z",
  "data": {
    "campaign_id": "cmp_9xQk4Fw2",
    "debtor": "Acme Corp",
    "invoice_number": "INV-2025-0847",
    "amount_collected": 15000,
    "method": "bank_transfer",
    "days_to_collect": 12,
    "timestamp": "2026-03-17T14:22:00Z"
  }
}
Webhooks are signed with HMAC-SHA256. Verify the X-AgentCollect-Signature header before processing.
Key endpoints

Every endpoint returns JSON. All timestamps are ISO 8601 UTC. Pagination via cursor.

Method Endpoint Description
POST /v1/campaigns Create a collection campaign and enroll debtors
GET /v1/campaigns/{id} Get campaign status, collected amount, and timeline
GET /v1/campaigns/{id}/contacts Get enriched contacts discovered for each debtor
GET /v1/payments List all received payments across campaigns
POST /v1/webhooks Register a webhook endpoint URL for event delivery
POST /v1/auth Exchange API key for a short-lived Bearer token
GET /v1/payments/{id} Get payment detail including method and breakdown
Webhooks

Register once, receive events in real time. No polling required.

campaign.started
AI collection sequence has begun. Expect first contact within 1–4 hours.
contact.enriched
New decision-maker contact found and verified for a debtor.
payment.received
Debtor made a payment. Includes amount, method, and invoice number.
case.escalated
Debtor non-responsive after AI outreach. Licensed attorney assigned.
campaign.completed
Mandate ended. Final summary payload includes recovery rate and timeline.
bash — register webhook
curl -X POST https://api.agentcollect.com/v1/webhooks \
  -H "Authorization: Bearer YOUR_TOKEN" \
  -d '{
    "url": "https://yourapp.com/webhooks/ac",
    "events": [
      "payment.received",
      "case.escalated",
      "campaign.completed"
    ]
  }'

# Response
{
  "webhook_id": "wh_7Lm3pRx1",
  "secret": "whsec_...",
  "status": "active"
}
Delivery: 3 retries with exponential backoff (1s, 5s, 30s). Failed events are visible in the dashboard for manual replay.
Brand it fully via API

Pass your brand in the campaign payload. Every email, phone call, and payment page carries your name — not ours.

json — brand object in campaign payload
{
  "company": "Your Company Inc.",
  "brand": {
    "name": "Your Company",
    "logo_url": "https://yourco.com/logo.png",
    "domain": "yourcompany.com",
    "from_email": "ar@yourcompany.com",
    "colors": {
      "primary": "#1E40AF",
      "accent": "#10B981"
    }
  },
  "debtors": [...]
}
What the debtor sees
From ar@yourcompany.com
Subject Invoice #2025-0847 — Your Company
Caller ID Your Company Collections
Payment page pay.yourcompany.com/inv-0847

AgentCollect is invisible. The debtor never knows we exist. Every touchpoint feels native to your brand.

Rate limits & SLA

Built for production workloads. Enterprise plans include dedicated infrastructure and custom rate limits.

1,000
Requests per minute
per API key
99.9%
Uptime SLA
monitored 24/7
<200ms
p99 response time
all endpoints
Webhook retries
exponential backoff
Rate limit headers
X-RateLimit-Limit: 1000
X-RateLimit-Remaining: 994
X-RateLimit-Reset: 1742221360
Error format
"error": "rate_limit_exceeded",
"retry_after": 42,
"status": 429
Test in sandbox first

Sandbox campaigns use fake money but real AI behavior. Same models, same outreach logic, same webhook events.

Sandbox API key format
sk_test_••••••••••••••••••••••••
Swap to sk_live_ when you're ready for production. No code changes needed.
Real AI agents, fake money
Live webhook delivery
Simulated payment events
Same API surface as prod
No credit card required
Instant onboarding
Get sandbox credentials
SOC 2 Type II
HTTPS + TLS 1.3
99.9% uptime SLA
HMAC webhook signing
FDCPA compliant

Request API access.

We'll send your credentials within 24 hours. Ship in your first sprint.

Request API access Security & Trust