OSS-first docs

These docs teach the open system first: contracts, generated surfaces, runtimes, governance, and incremental adoption. Studio shows up as the operating layer on top, not as the source of truth.

validate

Validate a contract spec file structure and optionally its implementation

  • Type: operation (command)
  • Version: 1.0.0
  • Stability: stable
  • Owners: @lssm/core
  • Tags: cli, validation
  • File: packages/bundles/workspace/src/contracts/operations/validate.operation.ts
  • field.key.label
    validate
    field.version.label
    1.0.0
    field.type.label
    operation (command)
    field.title.label
    validate
    field.description.label

    Validate a contract spec file structure and optionally its implementation

  • Type: operation (command)
  • Version: 1.0.0
  • Stability: stable
  • Owners: @lssm/core
  • Tags: cli, validation
  • File: packages/bundles/workspace/src/contracts/operations/validate.operation.ts
  • field.tags.label
    cli,validation
    field.owners.label
    @lssm/core
    field.stability.label
    stable

    Validate a contract spec file structure and optionally its implementation

    Goal

    Ensure spec validity and integrity

    Context

    Run via CLI or CI to check specs

    Source Definition

    export const validateOperation = defineCommand({
    	meta: {
    		key: 'validate',
    		title: 'Validate Spec',
    		description:
    			'Validate a contract spec file structure and optionally its implementation',
    		version: '1.0.0',
    		stability: 'stable',
    		tags: ['cli', 'validation'],
    		goal: 'Ensure spec validity and integrity',
    		context: 'Run via CLI or CI to check specs',
    		owners: ['@lssm/core'],
    	},
    	policy: {
    		auth: 'anonymous',
    	},
    	io: {
    		input: fromZod(
    			z.object({
    				spec: z.string().describe('Path to the spec file to validate'),
    				blueprint: z
    					.string()
    					.optional()
    					.describe('Validate against a blueprint spec'),
    				checkImplementation: z
    					.union([z.boolean(), z.literal('auto')])
    					.optional()
    					.describe('Validate implementation against spec (requires AI)'),
    			})
    		),
    		output: fromZod(
    			z.object({
    				valid: z.boolean(),
    				errors: z.array(z.string()),
    				warnings: z.array(z.string()),
    				structureResult: z.any().optional(), // Detailed structure result
    			})
    		),
    	},
    });