Skip to main content

Get Customer CRM Summary

GET 

/api/crm/customers/:customer/summary

Get a customer's CRM header figures: last visit (with owner and outcome), days since that visit, next planned activity (with its trip), open and overdue task counts, the last sales order with its top lines, and whether the customer has an active buyer portal account.

Required scope: customers:read

Grant this scope to your token under Settings → Developer → Personal Access Tokens.

Authentication: Requires Bearer token with the customers scope and the crm_activities.index permission.

The CRM activities feature must be switched on for the account; otherwise every CRM endpoint returns 404.

Visibility: a user who may view all CRM activities sees every activity. Anyone else sees the activities they own plus every activity on a customer whose default sales rep is their own sales rep. An activity or customer outside that scope returns 404, never 403.

Fields: last_visit.at is the check-in time, else the start time, else the completion time. next_planned is the next planned activity with a start time. Task counts cover tasks you can see. last_order.lines[] lists the top lines by quantity with available (current available stock) and unit_price (today's price for this customer at that quantity from their pricing tier and quantity breaks; null when the tier has no price). route values are the record's path in the app. coverage is the customer's visit coverage (grade, visit frequency, next visit due date and coverage status), exactly as Get Customer Visit Coverage returns it.

segment: the customer's RFM segment and order stats (scores 1-5, previous segment and the date it changed, first and last order, orders and revenue in the lookback window, average order value, average days between order dates when there are at least three), or null when the customer has no qualifying order. segment.order_status (on_track, due, late, very_late, or null without a usual interval), segment.expected_by and segment.late_by_days say where the customer stands against their usual interval between orders.

Request​

Responses​

OK

Response Headers
    Content-Type