post
https://api.lodgestory.com/api/wp-crm/reports/
Request generation of a CRM report for your organisation.
Supported report types:
| Type | Description |
|---|---|
CHAT | All chats with filters for assignees, labels, priority, bot status, date range, etc. |
CONTACT | Contact records with filters for search, channels, creation date, custom fields |
TICKET | Tickets with filters for resolution status, priority, assignees, date range |
CALL_LOG | Call logs with filters for direction, status, agents, duration, date range |
GOAL | Goal events with filters for date range, goal IDs, channels, tracker values |
Required steps before calling:
- Obtain a JWT via
POST /api/wp-crm/token - Choose a
reportTypeand optionally add filter fields to narrow the report scope
Security:
- The
organisationIdin the URL path must match the organisation your JWT was issued for. The token is cryptographically bound to a specific organisation — requests targeting a different organisation will fail with 401 Unauthorized. - Only users with
CRM_ADMINorACCOUNT_OWNERrole in the organisation can request reports. Other roles will receive a 403 Forbidden.
Rate limiting: Only one report per type per organisation can be generated every 5 minutes. If a report is already being generated or was recently completed, you'll receive a 409 Conflict.
Returns a report record with status PENDING. Poll GET /api/wp-crm/reports/:organisationId to check when it completes, then use the download endpoint.
Recent Requests
Log in to see full request history
| Time | Status | User Agent | |
|---|---|---|---|
Retrieving recent requests… | |||
Loading…
401Unauthorized — invalid/expired JWT or organisation ID does not match the token
403Forbidden — user does not have CRM_ADMIN or ACCOUNT_OWNER role
409A report of this type is already being generated or was recently completed. Wait 5 minutes between requests of the same type.
