Admin Customers
Export customers as csv, xls or xlsx
Changed onDownloads the customers datagrid — the same columns the admin Export button produces (Channel, Customer ID, Customer Name, Email, Contact Number, Status, Gender, Group, Suspended, Order Count, Address Count). Honours the same filters as the listing and exports every matching row. Binary download, not JSON. Requires customers.customers.
get/customers/export
Request
- Base URLhttp://localhost:8000/api/admin
- AuthHTTP bearer
- TypeScriptA function with typed inputs. Its response is checked against the schema.
Query parameters
format'csv' | 'xls' | 'xlsx'
Export format: csv, xls or xlsx. Defaults to csv.
querystring
Quick search: matches email or full name (partial).
namestring
Partial first/last name match.
emailstring
Partial email match.
phonestring
Partial phone match.
customer_group_idinteger
Customer group ID.
statusinteger
Status (0/1).
channel_idinteger
Channel ID.
created_at_fromstring
Created on or after (YYYY-MM-DD).
created_at_tostring
Created on or before (YYYY-MM-DD).
Response
Export file downloaded as an attachment.
Changes
- info
endpoint added
- info