Drop companyId from company-scoped store wrappers and routes, add GET /entity/next-number plus optional number on entity create/update, and document dashdbschema API.md lookup in sibling-repos.
666 B
666 B
GET /entity/next-number
Protected. Requires a valid session cookie (credentials: 'include').
Peek next customer number
Returns the next customer number that would be allocated (type entity)
without consuming it. Use on the customer add form.
Response 200
Next number
{
"number": "…"
}
Errors
| Status | Description |
|---|---|
| 400 | No company selected — {"error":"…"} |
| 401 | Unauthorized — {"error":"…"} |
| 403 | Not authorized — {"error":"…"} |
| 404 | Company not found — {"error":"…"} |
Generated from @openapi JSDoc. Do not edit by hand — run npm run docs:api.