Skip to content

List leads​

GET
/leads

Returns a paginated list of leads with optional filters. Requires leads:read scope. With format=flat each item is a FlatLead.

Authorizations​

BearerAuth

API key in format lm_xxxxxxxxxxxxxxxx. Get your key at app.looma.chat/integrations.

Type
HTTP (bearer)

Parameters​

Query Parameters

site_id

Filter by site ID

Type
integer
status

Filter by lead status

Type
string
Valid values
"new""in_progress""done""rejected"
search

Search in lead text, email, phone

Type
string
assigned_to

Filter by assigned operator ID

Type
integer
channel_id

Filter by channel ID

Type
integer
format

Response shape. flat returns every lead as a flat record (the same object the lead.created webhook sends) — contacts, products and site as top-level fields. Omit for the default shape. Any other value returns 422.

Type
string
Valid values
"flat"
date_from

Start date (YYYY-MM-DD)

Type
string
Format
"date"
date_to

End date (YYYY-MM-DD)

Type
string
Format
"date"
page

Page number

Type
integer
Minimum
1
Default
1
per_page

Items per page (max 100)

Type
integer
Minimum
1
Maximum
100
Default
30

Responses​

List of leads

application/json
JSON
{
"success": true,
"data": [
{
"id": 456,
"site_id": 12,
"site_name": "My Shop",
"site_favicon_url": "string",
"session_id": "session_abc123",
"visitor_id": "client_xyz",
"channel_id": 0,
"status": "string",
"lead_text": "Customer interested in Nike Air Max, size 42",
"collected_fields": {
"additionalProperties": "string"
},
"client_name": "John Doe",
"visitor_avatar": "string",
"source": "string",
"channel_name": "string",
"assigned_operator_name": "string",
"assigned_operator_avatar": "string",
"comments_count": 3,
"is_unread": 0,
"created_at": "string",
"updated_at": "string"
}
],
"meta": {
"total": 128,
"total_pages": 5,
"current_page": 1,
"per_page": 30
}
}

Playground​

Server
Authorization
Variables
Key
Value

Samples​

Powered by VitePress OpenAPI

Looma.chat — AI-powered e-commerce search & chat