Skip to main content
Koru
Get started
API reference sections

Schema

WorkspaceMigrationOutcome

What the migration actually did, in the order it did it.

The same shape whether it succeeded, for [WorkspaceLifecycleOutcome]'s reason: a caller reporting a partial failure needs the body it would have read on success.

Type object

Shape

FieldTypeDescription
workspacerequiredstring
fromrequiredstring

The owner the operation found. On a retry after the move already committed this is already the destination.

torequiredstring
terminated_sessionsrequiredarray of string

The sessions this call closed. Empty on a retry, and empty when the workspace was already where it was being sent.

sessions_closedrequiredboolean

Whether the terminals closed. false means nothing after it ran.

mutation_appliedrequiredboolean

Whether the Store reassignment committed. false with sessions_closed: true is the partial failure, and the retry is the same request with a fresh confirmation.

replacementReplacement or null
projects_rescopedarray of string or null

The projects whose typed scope now names the new owner, or None when the session host could not be asked.

Three-valued on purpose, and the third value is the one that matters. Some([]) is "the host was asked and had nothing to repair" - the ordinary answer for a workspace with no projects, and for a retry. None is "nobody has repaired them yet": the move committed, and until a repair lands those projects name a profile that no longer owns the workspace, so the terminal draws them in its missing-workspace area rather than lying about where they live. Sending the same request again is what repairs them.

A repair that could not run is deliberately not a failed migration. The workspace has moved, the fact is published, and every other reader is right; treating an unreachable session host as a failure would invite a caller to retry the whole operation as though nothing had happened.

Example
{
  "workspace": "string",
  "from": "string",
  "to": "string",
  "terminated_sessions": [
    "string"
  ],
  "sessions_closed": false,
  "mutation_applied": false,
  "replacement": {
    "state": "created",
    "workspace": {
      "id": "00000000-0000-4000-8000-000000000000",
      "owner": {},
      "name": "string",
      "created_at": 0,
      "last_opened_at": 0,
      "icon": "string",
      "color": "string",
      "pinned": false,
      "archived": false,
      "deleted_at": 0,
      "position": 0
    }
  },
  "projects_rescoped": [
    "string"
  ]
}

The contract has no example values, so example bodies are generated from each schema: every field is shown with a placeholder of its type.

Used by

Generated from contract version 1. Last updated .

Privacy choices

Choose which optional tools Koru may use on this site. Your choice is saved in a cookie in this browser for 12 months. Privacy policy

Privacy choices

Keep you signed in, protect forms and remember your language and this choice.

Always on

PostHog and Google Analytics 4 measure page views and actions such as downloads, using cookies or local storage.

PostHog records how pages are used, with form inputs masked and private pages excluded. Needs Analytics.

Ahrefs Web Analytics measures visits and where they come from, and Google Ads measures whether our ads led to a visit or download.