Reference / component

Musher Component Document

A reusable, versioned definition of one graph node: a workload this platform runs (its source, lifecycle, endpoints, storage and health) or an external node it does not, and the configuration contract either consumes and publishes.

JSON Schema · Specification · Examples · Source

This reference is generated from the schema bundle and is informative. Where it differs from the specification, the specification governs. A documented default is an annotation: no validator inserts it.

Structural and type validation only — cross-document reference resolution, slug/directory agreement, and platform capability checks are separate validation layers. See spec.md.

Contents

component document

A reusable, versioned definition of one graph node: a workload this platform runs (its source, lifecycle, endpoints, storage and health) or an external node it does not, and the configuration contract either consumes and publishes.

Authoring note

Structural and type validation only — cross-document reference resolution, slug/directory agreement, and platform capability checks are separate validation layers. See spec.md.

kind required

string — always COMPONENT

Document kind discriminator. Must be COMPONENT.

metadata required

ComponentMetadata

spec required

ComponentSpec

specVersion required

string — one of v1

Version of the Musher specification this document is written against.

ComponentBasicAuth

password required

ComponentProbeCredential

Password; a sensitive input, never a literal.

username required

ComponentProbeCredential

User name, literal or from an input.

ComponentBearerAuth

token required

ComponentProbeCredential

Token; a sensitive input, never a literal.

ComponentBuild

Authoring note

spec.md §5.1. Exactly one of dockerfile and buildpacks says how the source is built; arguments apply to either.

Forms

Exactly one of dockerfile or buildpacks is present. The key present selects the form.

arguments optional

mapping, keyed by argumentName matching ^[A-Z_][A-Z0-9_]*$, to string

Build arguments keyed by argument name, injected into the image build context (Docker ARG). Build-time configuration only; runtime configuration rides on inputs.

buildpacks optional

ComponentBuildpacks

Build with Cloud Native Buildpacks.

dockerfile optional

string

Build with a Dockerfile, at this path relative to the repository root.

minLength 1

ComponentBuildpacks

builderImage required

string

Buildpacks builder image.

minLength 1

ComponentConnection

The atomic connection this input stands for: an endpoint, a credential and a model acquired together.

Authoring note

spec.md §6.4 COMP-CONNECTION-002 / ADR 0033 §2. The protocol fixes the members (baseURL, apiKey and model, all strings, apiKey sensitive), so a connection input carries no schema of its own.

capabilities optional

array of string — one of STREAMING, TOOL_CALLS

Required protocol features. Omission requires no optional capabilities.

uniqueItems true

protocol required

string — one of OPENAI_CHAT_COMPLETIONS, ANTHROPIC_MESSAGES

Required client protocol, independent of upstream vendor.

ComponentContract

inputs optional

mapping, keyed by inputName matching ^[a-z][a-zA-Z0-9]{0,63}$, to ComponentInput

Typed input declarations keyed by input name.

outputs optional

mapping, keyed by outputName matching ^[a-z][a-zA-Z0-9]{0,63}$, to ComponentOutput

Typed output declarations keyed by output name.

ComponentEndpoint

Used as a map value, keyed by endpointName.

Conditional rules

spec.md §5.2 COMP-EP-005. Only HTTPS is TLS on the hop to the workload in v1, so only an HTTPS endpoint carries a trust policy.

Under the condition above, tls must not be present.

protocol required

string — one of HTTP, HTTPS, WS, GRPC, TCP, UDP

Protocol the platform speaks to the workload on the port: HTTP, HTTPS, WS, GRPC, TCP, or UDP.

targetPort required

integer

Port the workload listens on, where traffic for this endpoint is forwarded. Never the public port, which the platform allocates. A port below 1024 is structurally valid; admission may reject it as a capability check.

minimum 1 · maximum 65535

tls optional

ComponentEndpointTls

How the platform trusts the workload's certificate. Only on an HTTPS endpoint; omitted, the certificate is verified against publicly trusted roots.

ComponentEndpointTls

Authoring note

spec.md §5.2 COMP-EP-005 / COMP-EP-007. One policy for every connection the platform makes to the endpoint, routing and probes alike. BUNDLE names its roots and the name to verify; the other modes carry no bundle. serverName is a DNS name, never an IP literal: its last label starts with a letter.

Conditional rules

When verify is BUNDLE, serverName is required.

When verify is BUNDLE, trustBundle is required.

Otherwise, trustBundle must not be present.

serverName optional

string

Name sent in SNI and matched against the certificate. Never changes the address connected to or the HTTP Host header. Omitted, the certificate must be valid for the host the platform connects to. Required with BUNDLE.

maxLength 253 · pattern "^(?:[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?\\.)*[a-z](?:[a-z0-9-]{0,61}[a-z0-9])?$"

trustBundle optional

ComponentInputReference

Own string input holding the PEM certificates that are the only trusted roots. Required with BUNDLE, and forbidden otherwise.

verify optional

string — one of SYSTEM, BUNDLE, NONE

How the certificate is verified: SYSTEM (publicly trusted roots), BUNDLE (the roots in trustBundle), or NONE (no chain or name verification; an explicit exception for this endpoint).

documented default "SYSTEM"

ComponentGitRef

Authoring note

spec.md §5.1. Exactly one of branch and commit.

Forms

Exactly one of branch or commit is present. The key present selects the form.

branch optional

string

Branch to build from. A request, not a pin: the branch moves.

minLength 1

commit optional

string

Commit to build from. Identifies source, not every build input.

minLength 1

ComponentGitSource

build required

ComponentBuild

How the repository is built into an image. Required: a Git source has no image until something builds one, and leaving the strategy implicit makes the resulting image depend on the builder rather than on this document.

ref optional

ComponentGitRef

Branch or commit to build from. Omitted, the repository default branch.

repositoryURL required

string

Git repository URL the platform builds into an image.

minLength 1

ComponentHealthProbes

Staged health probes: startup, readiness, liveness.

liveness optional

ComponentProbe

Aliveness gate; failure restarts the workload. Optional.

readiness optional

ComponentProbe

Traffic gate; failure pulls the replica from routing without a restart. Required for a SERVICE exposing a public endpoint.

startup optional

ComponentProbe

Initialization gate; failure means not-yet-started. Optional.

ComponentHttpProbe

An HTTP GET the platform sends over the endpoint's protocol and TLS policy; a 200 to 399 status succeeds unless expectedStatuses says otherwise. Redirects are never followed.

auth optional

ComponentProbeAuth

Credentials sent on the probe request only, never on forwarded traffic.

endpoint required

string

Named endpoint serving HTTP or HTTPS.

pattern "^[a-z][a-z0-9]{0,19}$"

expectedStatuses optional

array of integer

HTTP statuses that count as success, replacing the 200 to 399 default for this probe.

minItems 1 · uniqueItems true

Authoring note

spec.md §5.4 COMP-EP-008. A final status is 200 to 599; a 1xx is never the answer to a probe.

path required

string

Absolute HTTP path the platform requests.

pattern "^/"

ComponentImageReference

OCI image reference the workload runs from. A bare name means the tag latest, as in Docker. A tag is a request; only an @sha256 digest identifies content.

Authoring note

Lookahead-free so it compiles under RE2 as well as ECMA-262. The tag colon is the one after the final slash, which is what keeps a registry port (localhost:5000/nginx) from reading as a tag. See spec.md §5.1.

ComponentInput

Used as a map value, keyed by inputName.

Authoring note

spec.md §6.1 / ADR 0033 §2. The key that is present says what kind of input this is: schema for a value input, connection for a connection input. Exactly one.

Forms

Exactly one of schema or connection is present. The key present selects the form.

Conditional rules

spec.md §6.4 COMP-CONNECTION-002. A connection input carries none of the value fields: its protocol fixes its members, and it is always required.

Under the condition above, default must not be present.

Under the condition above, presentationHint must not be present.

Under the condition above, required must not be present.

Under the condition above, schema must not be present.

Under the condition above, sensitive must not be present.

Under the condition above, target must not be present.

connection optional

ComponentConnection

The connection this input stands for. Only an EXTERNAL component declares one.

default optional

any value

Logical fallback used only when no binding is declared.

description optional

string

What this input means.

minLength 1

Authoring note

spec.md §6 COMP-DESC-001 and COMP-DESC-004. A published component describes every input (COMP-DESC-004, capability), and the component is its only home: a blueprint parameter carries no description of its own and shows this one, so a value is described once, by the document that needs it. Absent is a draft still being written; present and empty is never valid.

presentationHint optional

string — one of EMAIL, URI, ENDPOINT_URL, CONNECTION_STRING, HOSTNAME, TIMEZONE

Optional presentation annotation, not a value constraint.

required optional

boolean

Whether absence is forbidden; defaults to true.

documented default true

schema optional

ComponentValueSchema

Logical JSON value contract.

sensitive optional

boolean

True when the value is secret material: handled as a secret reference, masked in UIs, never echoed back.

documented default false

target optional

ComponentInputTarget

Environment destination; required on workload inputs.

ComponentInputReference

Authoring note

spec.md §5.2 COMP-EP-006 / ADR 0033. A value the workload configuration reads enters through one of the component's own inputs.

input required

string

Own input supplying the value.

maxLength 64 · pattern "^[a-z][a-zA-Z0-9]{0,63}$"

ComponentInputTarget

envVarKey required

string

Environment variable the resolved value is bound into at runtime materialisation (e.g. ADMIN_EMAIL). Uppercase letters, digits, and underscores; must not start with a digit.

minLength 1 · maxLength 128 · pattern "^[A-Z_][A-Z0-9_]*$"

ComponentMetadata

Identity and description of a component document. The name is the file stem.

description optional

string

What this component is, in one or two plain-text sentences. Required to publish.

minLength 1 · maxLength 280

Authoring note

spec.md §4 COMP-DESC-002. Plain text, never rendered as Markdown, and bounded like a listing summary: it is one or two sentences a composer reads beside a node, not documentation. Structurally optional so a component can be stored while it is being written; COMP-DESC-003 requires it of a published one.

revision required

integer

Lineage revision of this component. Required (never defaulted) so the component's content is a pure function of this file, and it is the revision the item's blueprint nodes pin.

minimum 1

ComponentOutput

Used as a map value, keyed by outputName.

description optional

string

What this output means.

minLength 1

from required

ComponentOutputFrom

presentationHint optional

string — one of EMAIL, URI, ENDPOINT_URL, CONNECTION_STRING, HOSTNAME, TIMEZONE

Optional presentation annotation.

schema required

ComponentValueSchema

Logical JSON value contract.

sensitive optional

boolean

True when the value is secret material: handled as a secret reference, masked in UIs, never echoed back.

documented default false

ComponentOutputFrom

Where the output value comes from.

Authoring note

spec.md §6.2 / ADR 0031 §1 / ADR 0033 §2. Where the output value comes from is the key that is present: a literal value, one of this component’s own inputs (with the member read, when the input is a connection input), a property of one of its endpoints, or a template over its own endpoints. Exactly one; endpoint and property are one origin, and each requires the other, and member requires input.

Forms

Exactly one of value, input, endpoint with property, or template is present. The key present selects the form.

endpoint requires property.

member requires input.

property requires endpoint.

endpoint optional

string

Own endpoint whose allocated address property is read.

pattern "^[a-z][a-z0-9]{0,19}$"

input optional

string

Own input forwarded as this output, keeping its sensitivity.

maxLength 64 · pattern "^[a-z][a-zA-Z0-9]{0,63}$"

member optional

string — one of baseURL, apiKey, model

Member of a connection input to forward. Required when the input is a connection input, and forbidden otherwise.

property optional

string — one of publicURL, publicHostname, publicAddress, publicPort, privateHostname, privatePort, privateAddress

Address property of the named endpoint.

template optional

string

String with ${{ self.endpoints.. }} references, substituted once.

maxLength 65536

value optional

any value

Logical non-secret literal value.

ComponentProbe

Authoring note

spec.md §5.4. The mechanism is the key that is present, as in a Kubernetes probe. HTTP is the only mechanism in v1; another is added as a sibling key.

failureThreshold optional

integer

Consecutive failures required to consider the probe failing.

minimum 1 · documented default 3

http required

ComponentHttpProbe

initialDelaySeconds optional

integer

Seconds to wait after start before the first probe.

minimum 0 · documented default 10

periodSeconds optional

integer

Seconds between consecutive probe attempts.

minimum 1 · documented default 10

successThreshold optional

integer

Consecutive successes required to consider the probe passing.

minimum 1 · documented default 1

timeoutSeconds optional

integer

Seconds to wait for a probe response.

minimum 1 · documented default 5

ComponentProbeAuth

Credentials the probe request carries.

Authoring note

spec.md §5.4 COMP-EP-009 / ADR 0031 §1. The mechanism is the key that is present. Exactly one.

Forms

Exactly one of basic or bearer is present. The key present selects the form.

basic optional

ComponentBasicAuth

HTTP Basic credentials.

bearer optional

ComponentBearerAuth

Bearer token credentials.

ComponentProbeCredential

Where one credential comes from.

Authoring note

spec.md §5.4 COMP-EP-010 / ADR 0031 §1. Where the credential comes from is the key that is present, as in an output's from. A password or token is a sensitive destination, so a value there is ERR_SECRET_LITERAL, semantic.

Forms

Exactly one of value or input is present. The key present selects the form.

input optional

string

Own input supplying the credential.

maxLength 64 · pattern "^[a-z][a-zA-Z0-9]{0,63}$"

value optional

string

Literal non-secret value.

minLength 1

ComponentSchedule

cron required

string

Five-field cron expression, evaluated in UTC, on which the JOB recurs.

maxLength 128 · pattern "^[^ \\t]+(?:[ \\t]+[^ \\t]+){4}$"

Authoring note

spec.md §5.7. Five fields (minute, hour, day of month, month, day of week) separated by one or more spaces or tabs, evaluated in UTC. The field count is structural so a seconds field or an @-macro is rejected rather than read two ways. The grammar and range of each field are a semantic rule of spec.md §5.7 (ERR_INVALID_SCHEDULE).

ComponentSource

Authoring note

spec.md §5.1 / ADR 0031 §1. The key that is present says where the image comes from; there is no tag. Exactly one of the two is REQUIRED: neither is a missing field and both an invalid value.

Forms

Exactly one of image or git is present. The key present selects the form.

git optional

ComponentGitSource

A Git repository the platform builds into an image.

image optional

ComponentImageReference

ComponentSpec

Conditional rules

When type is EXTERNAL, contract is constrained by properties.

When type is EXTERNAL, workload must not be present.

Otherwise, contract is constrained by properties.

When type is JOB, workload is constrained by properties.

Otherwise, workload is constrained by properties.

contract optional

ComponentContract

The composition contract: typed inputs the component needs and outputs it publishes.

type required

string — one of SERVICE, WORKER, JOB, EXTERNAL

Category of the node: SERVICE (long-running, request-driven, at least one endpoint), WORKER (long-running, not request-driven; endpoints optional and never public), JOB (runs to completion, once per rollout or on a schedule), or EXTERNAL (not run by this platform).

workload optional

ComponentWorkload

How the platform runs the component: source, command, endpoints, environment, storage and health. A published SERVICE, WORKER or JOB carries one; forbidden when type is EXTERNAL.

ComponentValueSchema

Conditional rules

When type is array, items is required.

When type is object, additionalProperties is required.

When type is object, properties is required.

When type is string, additionalProperties must not be present.

When type is string, exclusiveMaximum must not be present.

When type is string, exclusiveMinimum must not be present.

When type is string, items must not be present.

When type is string, maxItems must not be present.

When type is string, maximum must not be present.

When type is string, minItems must not be present.

When type is string, minimum must not be present.

When type is string, properties must not be present.

When type is string, required must not be present.

When type is string, uniqueItems must not be present.

When type is number, additionalProperties must not be present.

When type is number, items must not be present.

When type is number, maxItems must not be present.

When type is number, maxLength must not be present.

When type is number, minItems must not be present.

When type is number, minLength must not be present.

When type is number, pattern must not be present.

When type is number, properties must not be present.

When type is number, required must not be present.

When type is number, uniqueItems must not be present.

When type is integer, additionalProperties must not be present.

When type is integer, items must not be present.

When type is integer, maxItems must not be present.

When type is integer, maxLength must not be present.

When type is integer, minItems must not be present.

When type is integer, minLength must not be present.

When type is integer, pattern must not be present.

When type is integer, properties must not be present.

When type is integer, required must not be present.

When type is integer, uniqueItems must not be present.

When type is boolean, additionalProperties must not be present.

When type is boolean, exclusiveMaximum must not be present.

When type is boolean, exclusiveMinimum must not be present.

When type is boolean, items must not be present.

When type is boolean, maxItems must not be present.

When type is boolean, maxLength must not be present.

When type is boolean, maximum must not be present.

When type is boolean, minItems must not be present.

When type is boolean, minLength must not be present.

When type is boolean, minimum must not be present.

When type is boolean, pattern must not be present.

When type is boolean, properties must not be present.

When type is boolean, required must not be present.

When type is boolean, uniqueItems must not be present.

When type is null, additionalProperties must not be present.

When type is null, exclusiveMaximum must not be present.

When type is null, exclusiveMinimum must not be present.

When type is null, items must not be present.

When type is null, maxItems must not be present.

When type is null, maxLength must not be present.

When type is null, maximum must not be present.

When type is null, minItems must not be present.

When type is null, minLength must not be present.

When type is null, minimum must not be present.

When type is null, pattern must not be present.

When type is null, properties must not be present.

When type is null, required must not be present.

When type is null, uniqueItems must not be present.

When type is array, additionalProperties must not be present.

When type is array, exclusiveMaximum must not be present.

When type is array, exclusiveMinimum must not be present.

When type is array, maxLength must not be present.

When type is array, maximum must not be present.

When type is array, minLength must not be present.

When type is array, minimum must not be present.

When type is array, pattern must not be present.

When type is array, properties must not be present.

When type is array, required must not be present.

When type is object, exclusiveMaximum must not be present.

When type is object, exclusiveMinimum must not be present.

When type is object, items must not be present.

When type is object, maxItems must not be present.

When type is object, maxLength must not be present.

When type is object, maximum must not be present.

When type is object, minItems must not be present.

When type is object, minLength must not be present.

When type is object, minimum must not be present.

When type is object, pattern must not be present.

When type is object, uniqueItems must not be present.

additionalProperties optional

boolean — always false

enum optional

array

minItems 1 · uniqueItems true

exclusiveMaximum optional

number

exclusiveMinimum optional

number

items optional

ComponentValueSchema

maxItems optional

integer

minimum 0

maxLength optional

integer

minimum 0

maximum optional

number

minItems optional

integer

minimum 0

minLength optional

integer

minimum 0

minimum optional

number

pattern optional

string

maxLength 256

properties optional

mapping, keyed by propertyName, to ComponentValueSchema

required optional

array of string

uniqueItems true

type required

string — one of string, integer, number, boolean, null, array, object

uniqueItems optional

boolean

ComponentVolume

Used as a map value, keyed by volumeName.

minSizeGiB required

integer

Smallest allocation the component can run with. The blueprint allocates at least this.

minimum 1

mountPath required

string

Absolute path where the volume is mounted in the workload.

maxLength 512 · pattern "^/"

readOnly optional

boolean

True when the volume is mounted read-only.

documented default false

shared optional

boolean

True when every replica mounts the same volume at once. False, the volume attaches to one replica at a time.

documented default false

ComponentWorkload

command optional

array of string

Arguments the workload runs, as a list, with no shell. Replaces the image CMD and keeps its ENTRYPOINT. A published JOB carries one.

minItems 1

Authoring note

spec.md §5. Exec form: each item is one argument and no shell parses them. It replaces the image CMD and keeps its ENTRYPOINT, which is what command means in Docker and Compose.

endpoints optional

mapping, keyed by endpointName matching ^[a-z][a-z0-9]{0,19}$, to ComponentEndpoint

Named ports the workload listens on. A published SERVICE declares at least one; optional on a WORKER (never exposed publicly), forbidden on a JOB.

health optional

ComponentHealthProbes

Staged health probes (startup, readiness, liveness). Omitted when none are defined; forbidden on a JOB.

schedule optional

ComponentSchedule

Makes a JOB recur. Omitted, the job runs once per rollout. Forbidden on every other type.

source optional

ComponentSource

Where the workload image comes from: an image, or a Git repository the platform builds. A published workload carries one.

volumes optional

mapping, keyed by volumeName matching ^[a-z][a-z0-9-]{0,61}[a-z0-9]$, to ComponentVolume

Persistent storage the workload mounts, with the minimum size each needs.