Skip to content

examples.yaml JSON Schema + examples-validate #4832

Description

@timotheeguerin

Part of the Unified Examples Format epic.

RFC: https://github.com/Azure/azure-rest-api-specs/blob/rfc/unified-examples-format/documentation/rfc/unified-examples-format.md

Publish the JSON Schema for examples.yaml (at the $schema URL) and build the examples-validate tool.

Validation rules (RFC §3)

  • $-prefixed file metadata ($schema, $namespace); bare top-level keys are always operations.
  • Response status codes are bare integer keys; default/2XX ranges are not allowed.
  • since values are quoted and must be a version listed in service.yaml.
  • Per lineage: at most one entry without since (the base) and unique since values.
  • An operation's full lineage lives in one file; split large services by interface (examples/<Interface>.yaml).
  • The only supported placeholder is {api-version}.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions