Record

interface-binding

One interface instance the workload matched on this plugin — e.g. the store interface of acme:kv@0.1.0, labeled cache, with its manifest config.

record interface-binding {
  namespace: string,
  package: string,
  interfaces: list​<string>,
  version: option​<version>,
  name: option​<string>,
  external-id: option​<string>,
  config: list​<tuple​<string, string>>,
}

Fields

NameTypeDescription
namespacestring

Interface namespace (e.g. acme).

packagestring

Package within the namespace (e.g. kv).

interfaceslist​<string>

The matched interface names within the package (e.g. store).

versionoption​<version>

Version of the instance, if one was requested.

nameoption​<string>

Instance label when the workload names multiple instances of the same namespace:package, if any. Component-facing: what the component calls this import.

Two gaps for a wasm host component plugin specifically (a Rust built-in plugin doesn't have either): a workload with more than one named binding on the same namespace:package is rejected before bind unless the plugin implements supports_named_instances() — no wasm plugin can opt into that today, so this field only ever arrives as at most one populated name per namespace:package per workload in practice. And even where it is populated, it reaches on-workload-bind but is not threaded through to the capability call itself — nothing on a later store.get-style call says which binding it's for, only wasmcloud:host/identity's workload/component id. A plugin that needs to serve two unnamed bindings of the same namespace:package differently has no way to disambiguate them at all today.

external-idoption​<string>

Platform-facing id the binding was declared with, if any — what the platform's configuration calls the same instance.

Two names, one contract: name above and external-id here are the two names an instance can carry, and both refer to the one interface contract described by the rest of this record. An external-id is not an identity — it carries no uniqueness requirement, and a binding may declare either name, both, or neither.

configlist​<tuple​<string, string>>

Interface-level configuration from the workload manifest, as key/value pairs sorted by key.