ITracer
●cart · /core·interface
Minimal tracing interface accepted by the middleware and
optionally supplied on . Mirrors the OTel Tracer shape
without a direct dependency so hosts can bridge any tracing backend.
Properties
PROPTYPEDESCRIPTION
startSpan
unknown
Example
const tracer: ITracer = {
startSpan: async (name, attrs, fn) => {
const span = openTelemetry.tracer.startSpan(name, { attributes: attrs });
return fn({ recordException: (e) => span.recordException(e as Error), setAttribute: (k, v) => span.setAttribute(k, String(v)) });
},
};Related
RunCartAdapterContractOpts runCartAdapterContract CartCapabilityUnsupportedError CartError CartNotFoundError CartProviderError CartUserError CartAdapter
MetadataOpen in GitHub ↗
ILogger
Minimal structuredlogging interface threaded through . Adapters and middleware log to this sink rather than console directly so hosts can route output to their
IdempotencyStore
Backing store contract for the middleware. Implementations persist successful mutation results keyed by idempotency token so that duplicate requests within the