Skip to content

Authentication & Quickstart Guide

The LeadPattern Public API enables you to send WhatsApp messages, manage contacts, trigger broadcasts, and automate customer conversations programmatically. All requests require authentication using your secret API key.

1

Generate API Key

Head to your project dashboard under API Keys to create a new key with its own rate limits. A key has access to every public API endpoint your plan includes — keep it secret and server-side.

Open API Keys →
2

Set Header

Pass your secret key in the Authorization header with every HTTP request. Do not include a Bearer prefix.

Snippet
Authorization: lp_your_api_key_here
3

Health Check

Verify connectivity to the LeadPattern Public API with the public health-check endpoint (no key required):

Snippet
curl https://public.leadpattern.com/health-check
Public Base URLhttps://public.leadpattern.com

Rate Limits & Concurrency

60
Requests / Minute
Default rate limit per API key
10
Concurrent Requests
Max parallel in-flight calls
300
Requests / Min / IP
Per-IP global safety throttle

The effective rate limit is the lower of your API key's configured limit and your plan's maximum. When rate limits or quotas are exceeded, the API responds with HTTP status 429 Too Many Requests with a Retry-After header.

HTTP Status Codes

400Malformed request payload, invalid JSON syntax, or missing mandatory fields.
401Unauthorized — missing, revoked, inactive, or malformed API key.
402Payment required — workspace subscription is inactive, blocked, or plan quota exceeded.
403Forbidden — IP address is not in whitelist, plan does not include this feature, or the workspace has been restricted by LeadPattern ("Project is suspended").
404Resource not found — the requested entity ID, template, or recipient does not exist.
409Conflict — the resource already exists or is in the wrong state (e.g. a webhook with this URL already exists, duplicate quick-reply shortcut / tag / group name, an export already running, or a test sent to an inactive webhook).
422Unprocessable entity — validation failed (e.g. phone number is not valid or WhatsApp account unlinked).
429Rate limit exceeded — too many requests, retry after 60 seconds.
500Internal server error — unexpected backend exception. Check status page.