Powered by Official WhatsApp APIs, Meta Ads & AI ⚡
Developer API

REST API reference

Every Leadnator feature is an HTTP API. Authenticate with a JWT, call a dozen endpoints, ship production integrations. Docs below are grouped by module and include request payloads, response shapes, auth requirements and copy-paste curl snippets.

Base URLhttps://api.leadnator.com
AuthAuthorization: Bearer <JWT>
Content-Typeapplication/json
API versionv1 (implied)

Authentication

JWT-based auth. Every request needs an Authorization: Bearer <token> header after login, or ?token= as a query fallback for download/media URLs.

POST/api/auth/signup
Public

Create a new user and return a 7-day JWT.

Request body
{
  "name": "Alice",
  "email": "alice@example.com",
  "password": "minimum-6-chars"
}
Response 200 OK
{
  "token": "eyJhbGciOi…",
  "user": {
    "id": "u_123",
    "name": "Alice",
    "email": "alice@example.com",
    "role": "user",
    "plan": "Starter",
    "status": "active"
  }
}
Errors
  • 400 Missing fields
  • 409 Email already in use
curl example
curl 'https://api.leadnator.com/api/auth/signup' \
  -X POST \
  -H 'Content-Type: application/json' \
  -d '{"name":"Alice","email":"alice@example.com","password":"minimum-6-chars"}'
POST/api/auth/login
Public

Exchange email + password for a JWT.

Request body
{
  "email": "alice@example.com",
  "password": "…"
}
Response 200 OK
{
  "token": "eyJhbGciOi…",
  "user": {
    "id": "u_123",
    "name": "Alice",
    "role": "user"
  }
}
Errors
  • 401 Invalid credentials
curl example
curl 'https://api.leadnator.com/api/auth/login' \
  -X POST \
  -H 'Content-Type: application/json' \
  -d '{"email":"alice@example.com","password":"…"}'
GET/api/auth/me
Auth required

Return the logged-in user. Use to verify a stored token is still valid.

Response 200 OK
{
  "user": {
    "id": "u_123",
    "name": "Alice",
    "email": "alice@example.com",
    "role": "user",
    "plan": "Growth"
  }
}
curl example
curl 'https://api.leadnator.com/api/auth/me' \
  -H 'Authorization: Bearer YOUR_JWT'
POST/api/auth/forgot-password
Public

Email a password-reset link (via system SMTP).

Request body
{
  "email": "alice@example.com"
}
Response 200 OK
{
  "ok": true
}
curl example
curl 'https://api.leadnator.com/api/auth/forgot-password' \
  -X POST \
  -H 'Content-Type: application/json' \
  -d '{"email":"alice@example.com"}'
POST/api/auth/reset-password
Public

Apply a new password given a valid reset token.

Request body
{
  "token": "reset_xyz…",
  "password": "new-password"
}
Response 200 OK
{
  "ok": true
}
curl example
curl 'https://api.leadnator.com/api/auth/reset-password' \
  -X POST \
  -H 'Content-Type: application/json' \
  -d '{"token":"reset_xyz…","password":"new-password"}'