Skip to content
Developers
Get an API token

Delete a plan

Deletes a plan: revokes its shares, deletes its attached saved documents, then drops the plan and its results.

Delete a plan

DELETE/plans/{id}

Deletes a plan: revokes its shares, deletes its attached saved documents, then drops the plan and its results. A running plan stops after its chunks in flight. It doesn't wait for a restarted server to finish reading its stored plans.

Send a Novi API token as a bearer token on every request. Authentication
Exports

Exports of the plan aren't cancelled: each keeps the plan until its file is written, and the file stays until it expires.

Errors
  • 409 with details.saved and details.shares: unless=saved on a saved or shared plan.
  • 409, which can be retried: a plan running on another server, or one that keeps changing while it is deleted.
  • 409 conflict with details.reason plan_read_only: a Legacy Forecast (origin.engine fe), which is never deleted.

Parameters

Path parameters

Query parameters

  • unlessstringOptional

    saved: delete the plan only if it isn't saved and has no active share link; otherwise answer 409 conflict with details {id, saved, shares} and leave the plan, its shares and its documents as they were.

    shares counts active share links; no other 409 here carries saved. Use it to drop a plan you believe is unsaved without losing a save or share made meanwhile, as from another tab: the plan is marked deleting only if its metadata hasn't changed since the check, so a save or share that lands first wins. Without a state store no plan is saved, so it deletes as without it. Another value, an empty one or unless twice is a 400.

    "saved"
  • model_setstringOptional

    pattern ^[a-z0-9][a-z0-9-]{0,62}$

    The model set to answer from, an id from GET /model-sets. Absent: the set GET /model-sets names as default, the base dataset unless the server answers from a published set.

    • model_set=default reaches the base dataset; once the server retires it, a 400 naming the set answering instead.
    • An unknown id, or a set scoped to other tenants, is a 400 listing the ids the caller may use in details.allowed (published sets only once default is retired); a set that can't load, a 503 with the reason.
    • Plans and exports stay in their set: a call naming them (by path, plan, ids, source.plan, a scenario's plan.id, or a comparison's a.plan and b.plan, also under source.comparison) reaches it without model_set.
    • An explicit model_set wins; naming resources of two sets in one request is a 400.

Responses

200 OK

Deleted.

  • idstringRequired

    Format uuid

    Plan id.

  • deletedanyRequired

    Always true

    Always true.

Errors

StatusWhen
404

No such well, grid, plan or route.

409

The request conflicts with the state of the plan or resource it names, and message says how: for example a plan still running or failed, a stale If-Match, an Idempotency-Key reused with another body, or a server without a state store.

Shared errors400401403500503What they mean