Configuration
The core is a codec, so there’s almost nothing to configure — the “wiring” is your own broker client plus a couple of optional behaviours.
Envelope options
EnvelopeCodec.Make takes the queue name (written to meta.queue) and an
optional inbound trace id to continue across a hop:
using BabelQueue;
var env = EnvelopeCodec.Make(
"urn:babel:orders:created",
new Dictionary<string, object?> { ["order_id"] = 1042L },
queue: "orders",
traceId: inbound.TraceId); // omit to mint a fresh trace_id
Dead-letter
On failure, wrap the envelope in an additive dead_letter block and publish the
copy to your dead-letter queue (e.g. orders.dlq):
var dlq = DeadLetters.Annotate(env, "failed", "orders", attempts: 3, error: "boom");
// publish EnvelopeCodec.Encode(dlq) to the "orders.dlq" queue
DeadLetters.Annotate returns a copy — the original envelope is preserved
unchanged inside the dead-lettered message, so any-language consumer can still
read it.
Unknown-URN strategy
For adapters routing inbound messages, UnknownUrnStrategy (Fail, Delete,
Release, DeadLetter) describes what to do with a URN you don’t handle.
Next: Producing messages.