Skip to content

Save the current cash forecast configuration as a named version

POST/api/v1/businesses/{business_id}/cfo-portal/cash-forecast/versions

Snapshot the current cash forecast configuration + output.

The version captures the chosen budget, excluded ledgers, embedded one-time items, cell overrides and forecast switches, along with the full computed forecast JSON. The snapshot is what stays stable as live data drifts; the config is what's replayed on load.

Request Body: config.overrides omitted or null saves the working override set (the Reorder Cash Planner); [] saves none (the live Cash Flow Forecast tab, which ignores overrides). Duplicate cells or weeks outside 1-52 are refused with 400.

Operation ID: cfo_portal_create_version·View as markdown·OpenAPI slice

Authentication

Bearer token authentication. Pass your DayZero API token in the Authorization header and the target business UUID in x-business-id.

Parameters

Path

business_idstringrequired

Request body

namestringrequired
descriptionstring
configCashForecastVersionConfigCashForecastVersionConfig
8 fields
budget_idstring
excluded_budget_ledger_idsarray · string
weeksinteger
one_time_items_snapshotarray · CashForecastOneTimeItemBaseCashForecastOneTimeItemBase

Snapshot of the one-time items as they existed when the version was saved. Replays against live data don't re-load from the live cash_forecast_one_time_items table.

overridesarray · CashForecastOverrideInput

Cell overrides saved with the version. On save, omit (null) to capture the working override set, pass [] to save none (the live Cash Flow Forecast tab, which ignores overrides). On read, null means the version predates override capture.

include_projected_replenishmentboolean

Projected replenishment POs were in the forecast.

include_unapproved_apboolean

Bills awaiting approval were in the forecast.

net_bills_against_budgetboolean

Open bills were netted against their budget line.

Responses

201Successful Response

successboolean
messagestring
codestring
dataCashForecastVersionDetail

400Bad Request - Invalid input

errorstringrequired

Error category: validation_error, unauthorized, forbidden, not_found, conflict, rate_limited, server_error, or service_unavailable.

messagestringrequired

Human-readable explanation, safe to show to end users.

codestringrequired

Stable machine-readable code in CATEGORY_NNN form (e.g. NOT_FOUND_006, AUTH_010, GEN_002).

request_idstring

Correlation id for support requests. Echoes the x-request-id request header when one was supplied.

errorsobject

Field-level validation messages keyed by field name. Present on 400/422 validation failures only.

401Unauthorized - Missing or expired token, an MCP OAuth token used against the REST API, or no access to this business

errorstringrequired

Error category: validation_error, unauthorized, forbidden, not_found, conflict, rate_limited, server_error, or service_unavailable.

messagestringrequired

Human-readable explanation, safe to show to end users.

codestringrequired

Stable machine-readable code in CATEGORY_NNN form (e.g. NOT_FOUND_006, AUTH_010, GEN_002).

request_idstring

Correlation id for support requests. Echoes the x-request-id request header when one was supplied.

errorsobject

Field-level validation messages keyed by field name. Present on 400/422 validation failures only.

403Forbidden - Insufficient permissions

errorstringrequired

Error category: validation_error, unauthorized, forbidden, not_found, conflict, rate_limited, server_error, or service_unavailable.

messagestringrequired

Human-readable explanation, safe to show to end users.

codestringrequired

Stable machine-readable code in CATEGORY_NNN form (e.g. NOT_FOUND_006, AUTH_010, GEN_002).

request_idstring

Correlation id for support requests. Echoes the x-request-id request header when one was supplied.

errorsobject

Field-level validation messages keyed by field name. Present on 400/422 validation failures only.

404Not Found - Resource does not exist

errorstringrequired

Error category: validation_error, unauthorized, forbidden, not_found, conflict, rate_limited, server_error, or service_unavailable.

messagestringrequired

Human-readable explanation, safe to show to end users.

codestringrequired

Stable machine-readable code in CATEGORY_NNN form (e.g. NOT_FOUND_006, AUTH_010, GEN_002).

request_idstring

Correlation id for support requests. Echoes the x-request-id request header when one was supplied.

errorsobject

Field-level validation messages keyed by field name. Present on 400/422 validation failures only.

422Validation Error

errorstringrequired

Error category: validation_error, unauthorized, forbidden, not_found, conflict, rate_limited, server_error, or service_unavailable.

messagestringrequired

Human-readable explanation, safe to show to end users.

codestringrequired

Stable machine-readable code in CATEGORY_NNN form (e.g. NOT_FOUND_006, AUTH_010, GEN_002).

request_idstring

Correlation id for support requests. Echoes the x-request-id request header when one was supplied.

errorsobject

Field-level validation messages keyed by field name. Present on 400/422 validation failures only.