All contracts

Workspace operations / JSON Schema

Workspai Workspace Registry Summary

Defines the versioned workspace registry v1 boundary used by Workspai and its consumers.

Schema version
workspace-registry.v1
Contract path
contracts/workspace-registry.v1.json
Publication
synced-supporting-contract
Defined fields
23
Artifact bindings
1

Why this contract exists

Architecture role

Keeps workspace identity and discovery consistent across tools and machines.

Consumption boundary

  • Workspai CLI
  • Workspace Intelligence consumers
  • IDEs and agents

Related commands

Commands are linked only when the runtime contract identifies a direct production relationship. Supporting contracts may be consumed without having a single producer command.

Produced artifacts

These durable files are emitted by registered commands and validated against this contract.

Artifact pathSchemaProducer
.workspai/workspace-registry.v1.jsonworkspace-registry.v1
workspai workspace sync

Field reference

Every declared schema property or published capability path is listed here. Required means the contract declares or publishes that field at the shown boundary.

Field pathTypeRequiredMeaningConstraints
$defs.registrySourceSnapshot.existsbooleanYesDefines the exists value at this contract boundary.
$defs.registrySourceSnapshot.pathstringNoDefines the path value at this contract boundary.
$defs.registrySourceSnapshot.projectCountintegerYesDefines the projectcount value at this contract boundary.minimum: 0
authorityenumYesDefines the authority value at this contract boundary.enum: workspace.contract.json, global-registry, legacy-workspace.json, none
contractPathstringYesDefines the contractpath value at this contract boundary.minLength: 1
generatedAtstringYesDefines the generatedat value at this contract boundary.format: date-time
kindstringYesDefines the kind value at this contract boundary.const: "rapidkit.workspace.registry"
profilestringNoDefines the profile value at this contract boundary.
projectCountintegerYesDefines the projectcount value at this contract boundary.minimum: 0
projectsarrayYesDefines the projects value at this contract boundary.
projects[].frameworkstringNoDefines the framework value at this contract boundary.
projects[].kitstringNoDefines the kit value at this contract boundary.
projects[].relativePathstringYesDefines the relativepath value at this contract boundary.minLength: 1
projects[].slugstringYesDefines the slug value at this contract boundary.minLength: 1
projects[].sourcestringNoDefines the source value at this contract boundary.
registrySummaryPathstringYesDefines the registrysummarypath value at this contract boundary.minLength: 1
schemaVersionstringYesDefines the schemaversion value at this contract boundary.const: "workspace-registry.v1"
sourcesobjectYesDefines the sources value at this contract boundary.additionalProperties: false
sources.contractreferenceYesDefines the contract value at this contract boundary.ref: #/$defs/registrySourceSnapshot
sources.globalRegistryreferenceYesDefines the globalregistry value at this contract boundary.ref: #/$defs/registrySourceSnapshot
sources.legacyWorkspaceJsonreferenceYesDefines the legacyworkspacejson value at this contract boundary.ref: #/$defs/registrySourceSnapshot
workspaceNamestringYesDefines the workspacename value at this contract boundary.minLength: 1
workspacePathstringYesDefines the workspacepath value at this contract boundary.minLength: 1

Canonical machine-readable definition

The raw synchronized contract remains authoritative. The educational sections above are projections of this definition.

Show raw JSON
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://getrapidkit.com/schemas/workspace-registry.v1.json",
  "title": "Workspai Workspace Registry Summary",
  "type": "object",
  "required": [
    "schemaVersion",
    "kind",
    "generatedAt",
    "workspacePath",
    "workspaceName",
    "projectCount",
    "authority",
    "contractPath",
    "registrySummaryPath",
    "projects",
    "sources"
  ],
  "properties": {
    "schemaVersion": {
      "const": "workspace-registry.v1"
    },
    "kind": {
      "const": "rapidkit.workspace.registry"
    },
    "generatedAt": {
      "type": "string",
      "format": "date-time"
    },
    "workspacePath": {
      "type": "string",
      "minLength": 1
    },
    "workspaceName": {
      "type": "string",
      "minLength": 1
    },
    "profile": {
      "type": "string"
    },
    "projectCount": {
      "type": "integer",
      "minimum": 0
    },
    "authority": {
      "enum": [
        "workspace.contract.json",
        "global-registry",
        "legacy-workspace.json",
        "none"
      ]
    },
    "contractPath": {
      "type": "string",
      "minLength": 1
    },
    "registrySummaryPath": {
      "type": "string",
      "minLength": 1
    },
    "projects": {
      "type": "array",
      "items": {
        "type": "object",
        "required": [
          "slug",
          "relativePath"
        ],
        "properties": {
          "slug": {
            "type": "string",
            "minLength": 1
          },
          "relativePath": {
            "type": "string",
            "minLength": 1
          },
          "framework": {
            "type": "string"
          },
          "kit": {
            "type": "string"
          },
          "source": {
            "type": "string"
          }
        },
        "additionalProperties": true
      }
    },
    "sources": {
      "type": "object",
      "required": [
        "contract",
        "globalRegistry",
        "legacyWorkspaceJson"
      ],
      "properties": {
        "contract": {
          "$ref": "#/$defs/registrySourceSnapshot"
        },
        "globalRegistry": {
          "$ref": "#/$defs/registrySourceSnapshot"
        },
        "legacyWorkspaceJson": {
          "$ref": "#/$defs/registrySourceSnapshot"
        }
      },
      "additionalProperties": false
    }
  },
  "additionalProperties": false,
  "$defs": {
    "registrySourceSnapshot": {
      "type": "object",
      "required": [
        "exists",
        "projectCount"
      ],
      "properties": {
        "exists": {
          "type": "boolean"
        },
        "projectCount": {
          "type": "integer",
          "minimum": 0
        },
        "path": {
          "type": "string"
        }
      },
      "additionalProperties": false
    }
  }
}