Customers
List customer quotes for a data table
/a/Customer_quotesGetDT
Return a paged customer quote table with linked jobs, file count, email state, and optional direct-subsidiary inclusion.
When to use this endpoint
Use Customer_quotesGetDT to reproduce the customer Quotes panel, including its date, search, and direct-subsidiary controls.
The endpoint returns positional UI rows rather than stable named quote objects; use a dedicated quote endpoint for general quote integration when one is available.
Authentication and permissions
The request must authenticate with signed API-key fields or a logged-in CRM session. The handler performs no additional page or role-permission check.
The lookup and any write use the authenticated tenant; an ID from another tenant cannot be addressed through this call.
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
customer_id | Integer string | Yes | Customer ID. Presence is validated, but positivity and customer existence are not. |
start | Integer string | No | Zero-based offset; defaults to 0. |
length | Integer string | No | Page size; defaults to 10. |
draw | Integer string | No | DataTables counter copied to the response; defaults to 0. |
order[0][column] | Integer string | Yes | 0 sorts by quote ID, 1 by creation date; other values fall back to quote ID. |
order[0][dir] | String | Yes | Exact desc selects descending; all other values select ascending. |
search[value] | String | Yes | May be blank. A nonblank value performs a substring match on net total, gross total, notes, or quote number. |
showSubsidiaries | Integer string | No | A non-zero value adds quotes for non-deleted direct children of the requested customer. It does not traverse grandchildren. |
dateFrom | Date string | No | Inclusive quote creation-date lower bound. When present, dateTo is consumed as the upper date and must also be supplied. |
dateTo | Date string | With dateFrom | Inclusive upper date through 23:59:59. It is not used unless dateFrom is present. |
Example request
$quotes = FM_api('Customer_quotesGetDT', [
'customer_id' => '1088',
'start' => '0',
'length' => '25',
'draw' => '2',
'order' => [['column' => '1', 'dir' => 'desc']],
'search' => ['value' => 'Q-2026'],
'showSubsidiaries' => '1',
'dateFrom' => '2026-09-01',
'dateTo' => '2026-09-30',
]);
Example response
{
"draw": 2,
"recordsTotal": "4",
"recordsFiltered": "1",
"data": [
["604", "2026-09-18 14:20:00", "Aoife Murphy", "Annual service", "420.00", "516.60", "1", [7204], 2, "36", 1, "Q-2026-604", "Northwind Belfast"]
]
}
Row positions are quote ID, creation date, creator name, notes, net, gross, status, linked job-ID array, non-deleted file count, user ID, email-sent flag, quote number, and customer/site name.
Errors and unusual responses
| Response | Condition |
|---|---|
{"error":"not logged in"} | No authenticated tenant context is available. Invalid signed credentials can be rejected by the dispatcher before the handler runs. |
{"error":"missing or invalid parameter: customer_id"} | customer_id is absent. |
{"error":"missing or invalid parameter: [order][0][dir]"} | The sort direction is absent. |
{"error":"missing or invalid parameter: [order][0][column]"} | The sort column is absent. |
{"error":"missing or invalid parameter: [search][value]"} | The DataTables search value is absent; send a blank string when no search is wanted. |
Legacy application errors may be returned with HTTP 200. Check the decoded response for error, not only the HTTP status.
Behaviour and edge cases
- Soft-deleted quotes are excluded. Direct-subsidiary inclusion also excludes deleted child customers, but does not filter on child activity.
recordsTotalcounts only non-deleted quotes directly assigned to the requested customer. With subsidiaries enabled it can therefore be smaller thanrecordsFiltered.- Linked job IDs come from relationship type
2. The relationship query does not filter the linked jobs for deletion. - The file count includes non-deleted files of quote type
12. The email flag is1only when quote metadata contains integer-likeemail_sent=1.
See it in Fieldmotion
CRM1
Open a customer and select Quotes. Filter Network requests for Customer_quotesGetDT, then change the date, search, or “show sites” control. CRM1 hides the page from non-admin users whose CRM access mask includes 128; the handler does not perform that page-permission check itself.
CRM2
A source search found no CRM2 caller for this positional customer Quotes table.
Related endpoints
Customer_ordersGetDTincludes orders associated through customer quotes.Customer_getChildrenDTreturns all hierarchy depths; this endpoint includes direct children only.