Bourse.WS.SpecConfig (bourse v0.1.0)

Copy Markdown View Source

Merges v4.1.0 websocket.* spec slices with hand-maintained WS overrides.

Resolved spec fields win; unresolved or absent fields fall back to hand config without guessing. Subscription channel templates remain T97-owned.

Summary

Functions

Builds the effective WS config map for an exchange, or nil when unsupported.

Hand-maintained bases keyed by exchange id (subscription + URL/auth detail).

Functions

build(exchange_id)

@spec build(String.t()) :: map() | nil
@spec build(Bourse.Exchange.t()) :: map() | nil

Builds the effective WS config map for an exchange, or nil when unsupported.

hand carries subscription patterns and hand-only URL/auth detail; spec slices override heartbeat and auth pattern selection when resolved.

build(exchange_id, spec, hand)

@spec build(String.t(), map() | nil, map() | nil) :: map() | nil

hand_bases()

@spec hand_bases() :: %{required(String.t()) => map()}

Hand-maintained bases keyed by exchange id (subscription + URL/auth detail).