← All types
Ob Object

Workspace

An instance-served workspace: the container record joined with the relevant version's definition (the published version when published, else the open draft). A workspace is the standing surface a role works in — panels of live data plus one-tap actions that run mutations as the signed-in user. For a technical team's own monitoring board, with no actions, use a Dashboard instead.

Fields

id

WorkspaceID!Non-null

TypeID of the workspace container record (prefix wks, e.g. "wks_01K…"). Stable across versions.

handle

String!Non-null

Stable, tenant-unique handle, derived from the definition's id — never supplied separately. Used for deep links and anchored launches.

Computed lifecycle status: PUBLISHED when a live published version exists, else DRAFT.

Possible values (2)
DRAFT

An unpublished version; ordinary drafts are editable while IaC source snapshots are fixed. Never served to runners. On the workspace record it means no published version exists yet.

PUBLISHED

An immutable, live version — the only status runners fetch. On the workspace record it means a live published version exists, even when a newer draft is open beside it.

version

Int!Non-null

Version number of the version definition came from: the published version when published, else the open draft. Starts at 1 and increments per authored draft.

TypeID of the live published version (prefix wsv); null while the workspace only has drafts. The same fact as version when published, as a reference — a version number is server-assigned, so only the id can be pointed at by configuration written before the version exists.

Permission domains the definition declares it needs (mirrored out of the latest version so unauthorised workspaces can be filtered server-side). Empty when the definition declares none.

Distribution scope, which drives authorization: PERSONAL (owner-only, self-service via workspace:personal), TEAM / INSTANCE (require workspace:write to author).

Possible values (3)
PERSONAL

Owned by one user and visible only to them. Self-service: authoring it needs workspace:personal rather than workspace:write, and workspace:write is not a backdoor into someone else's personal workspace.

TEAM

Offered to the members of the teams it is assigned to; at least one team is required. Authoring it needs workspace:write.

INSTANCE

Offered to everyone in the tenant whose permissions cover its requiredDomains. The default scope when none is given; authoring it needs workspace:write.

Owner of a PERSONAL workspace; null for TEAM / INSTANCE.

teamIds

[TeamID!]!Non-null

Teams a TEAM-scoped workspace is assigned to.

Internal compiled rendering contract. Never submit this field as authored source.

source

StringNullable

Author-only cococo-workspace-source/1 envelope with exact sourceXML and serverLua. Latest authored version, including an open draft; null for non-authors.

Revision of the complete authoring snapshot. Empty for runtime-only readers; a non-empty observed revision is required for IaC updates.

True when an unpublished draft exists for this workspace.

ISO-8601 timestamp when the workspace was first created (its first version authored).

ISO-8601 timestamp of the last change to the workspace container — a new draft, an edit, a scope/team change, or a publish.

Referenced by (4)
Exact type SDL
"""
An instance-served workspace: the container record joined with the relevant version's definition (the published version when published, else the open draft). A workspace is the standing surface a role works in — panels of live data plus one-tap actions that run mutations as the signed-in user. For a technical team's own monitoring board, with no actions, use a Dashboard instead.
"""
type Workspace @iac_resource(name: "workspace") @iac_precondition(field: "revision", input: "expectedRevision") @iac_guide(ref: "workspace-authoring-guide") @iac_ops(create: "createWorkspace", read: "getWorkspace", update: "updateWorkspaceSource", delete: "deleteWorkspace") @iac_replace(strategy: DESTROY_BEFORE_CREATE) {
  """
  TypeID of the workspace container record (prefix `wks`, e.g. "wks_01K…"). Stable across versions.
  """
  id: WorkspaceID! @iac_identity(assignedBy: SERVER) @iac_computed
  """
  Stable, tenant-unique handle, derived from the definition's `id` — never supplied separately. Used for deep links and anchored launches.
  """
  handle: String! @iac_computed
  """
  Computed lifecycle status: PUBLISHED when a live published version exists, else DRAFT.
  """
  status: WorkspaceStatus! @iac_computed
  """
  Version number of the version `definition` came from: the published version when published, else the open draft. Starts at 1 and increments per authored draft.
  """
  version: Int! @iac_computed
  """
  TypeID of the live published version (prefix `wsv`); null while the workspace only has drafts. The same fact as `version` when published, as a reference — a version number is server-assigned, so only the id can be pointed at by configuration written before the version exists.
  """
  publishedVersionId: WorkspaceVersionID @iac_ref(resource: "workspace_version") @iac_writtenBy(operation: "publishWorkspace", argument: "versionId")
  """
  Permission domains the definition declares it needs (mirrored out of the latest version so unauthorised workspaces can be filtered server-side). Empty when the definition declares none.
  """
  requiredDomains: [String!]! @iac_computed
  """
  Distribution scope, which drives authorization: PERSONAL (owner-only, self-service via workspace:personal), TEAM / INSTANCE (require workspace:write to author).
  """
  scope: WorkspaceScope!
  """Owner of a PERSONAL workspace; null for TEAM / INSTANCE."""
  ownerUserId: UserID @iac_ref(resource: "service_account") @iac_computed
  """Teams a TEAM-scoped workspace is assigned to."""
  teamIds: [TeamID!]! @iac_ref(resource: "team")
  """
  Internal compiled rendering contract. Never submit this field as authored source.
  """
  definition: String! @iac_computed
  """
  Author-only cococo-workspace-source/1 envelope with exact sourceXML and serverLua. Latest authored version, including an open draft; null for non-authors.
  """
  source: String @iac_artifact(language: JSON, validators: ["workspace-source", "workspace-source-structure"], models: ["workspace_document"], modelPath: "/sourceXML", description: "Workspace source, including its document and server Lua.") @iac_guide(ref: "workspace-authoring-guide")
  """
  Revision of the complete authoring snapshot. Empty for runtime-only readers; a non-empty observed revision is required for IaC updates.
  """
  revision: String! @iac_computed
  """True when an unpublished draft exists for this workspace."""
  hasDraft: Boolean! @iac_computed
  """
  ISO-8601 timestamp when the workspace was first created (its first version authored).
  """
  createdAt: ISO8601! @iac_computed
  """
  ISO-8601 timestamp of the last change to the workspace container — a new draft, an edit, a scope/team change, or a publish.
  """
  updatedAt: ISO8601! @iac_computed
}