Skip to main content

Workspace Config Reference

event-spec.yaml is the root configuration file for a project. See Getting Started — Workspace for an introduction.

Fields

FieldTypeRequiredDefaultDescription
versionintegerYesConfig schema version. Always 1.
workspacestringYesLogical workspace name. Used in generated package/module names and registry grouping.
registry.modestringNolocalRegistry backend: local | git | server.
registry.urlstringConditionalGit repo URL (git mode) or server base URL (server mode).
registry.refstringNomainGit branch/tag/commit (git mode only).
registry.cache_dirstringNo~/.event-spec/cache/<hash>Local clone path for git mode. Override for CI or monorepo layouts.
registry.api_keystringConditionalAPI key for server mode. Supports ${ENV_VAR} expansion.
specs_dirstringNo./specsPath to event spec YAML directory tree.
sources_dirstringNo./sourcesPath to source definition directory.
destinations_dirstringNo./destinationsPath to destination definition directory.
audit.pathstringNo.Default scan path for event-spec audit.
audit.coverage_minnumberNo0Default minimum coverage percentage.
audit.reportstringNotextDefault audit report format.

Examples

Local mode (simplest)

version: 1
workspace: "my-company"
registry:
mode: local
specs_dir: ./specs
sources_dir: ./sources
destinations_dir: ./destinations

Git mode

version: 1
workspace: "my-company"
registry:
mode: git
url: https://github.com/my-org/analytics-specs.git
ref: main

Server mode

version: 1
workspace: "my-company"
registry:
mode: server
url: https://registry.example.com
api_key: "${REGISTRY_API_KEY}"

With audit defaults

version: 1
workspace: "my-company"
registry:
mode: local
specs_dir: ./specs
sources_dir: ./sources
destinations_dir: ./destinations
audit:
path: ./src
coverage_min: 80
report: json