Skip to content

OutboundWrapper

OutboundWrapper = (publish, metadata) => (message, overrides?) => Promise<any>

Defined in: packages/hoppity/src/interceptors/types.ts:63

Wraps a publish function. Receives the inner publish and metadata about the contract being published to. Returns a replacement publish with the same signature.

The wrapper can modify the message, inject headers into overrides, create spans, record metrics, or short-circuit the publish.

Composition: for interceptors [A, B], the call chain is A → B → rascal publish.

(message, overrides?) => Promise<any>

OutboundMetadata

(message, overrides?): Promise<any>

any

PublicationConfig

Promise<any>