Customers
List legacy invoice due dates
/a/Customer_getValidInvoiceDueDates
Return the fixed legacy list of allowed customer invoice due-day overrides.
When to use this endpoint
Use Customer_getValidInvoiceDueDates only for the legacy customer editor that stores a simple number-of-days override.
Newer mapped customer fields also support due-date modes and values beyond this short list; validate those through the mapped create/update contract.
Authentication and permissions
The handler does not require login or tenant context and reads no tenant data.
Parameters
This endpoint has no operation-specific parameters.
Example request
$options = FM_api('Customer_getValidInvoiceDueDates', []);
Example response
{
"valid_dates": [0, 7, 14, 21, 28, 30, 45, 60, 90]
}
Errors and unusual responses
| Response | Condition |
|---|
The handler has no validation or application-level error branch.
Behaviour and edge cases
- The array is hard-coded and is not affected by tenant invoice settings.
0is a valid explicit override and is distinct from removing the customer override to inherit the global setting.- There is no pagination or side effect.
See it in Fieldmotion
CRM1
The customer edit page loads this route to populate the legacy invoice due-date selector.
CRM2
No direct production CRM2 caller was found. CRM2 exposes the mapped due-date mode/value fields in configurable layouts.
Related endpoints
Customer_editacceptsdefault_invoice_due_dateand checks it against this list.Customer_updateDatavalidates the newer mapped due-date mode/value pair.