Skip to main content

Module params

Module params 

Source
Expand description

Typed parameters for the sealed operations that take them.

§Why these are types and not Vec<(&str, String)>

The untyped form is still there — crate::core::CoreClient::call takes wire-named pairs, and always will, because that is what makes an operation this crate never named still reachable. But a pair list is checked against the contract at runtime: a misspelled payolad is refused when the call is made, which is late for a name that was wrong the moment it was typed. These structs move the spelling to compile time and leave the runtime check exactly where it was, as the backstop for the untyped route.

§Why a request enum is closed and a response string is not

super’s models keep status and kind as String because an added variant must never fail a decode. A request parameter is the opposite situation: the value is the client’s to choose, the contract declares the closed set the server accepts, and a value outside it is a 400 the client could have prevented. So where the document declares an enum, this module declares one too — and super::coverage holds the two together.

Structs§

ExportSessionParams
GET /v1/sessions/{id}/export — one session’s export stream.
ExportSessionsParams
GET /v1/sessions/export — every session in a window, streamed.
SearchSpansParams
GET /v1/search/spans — semantic search over span embeddings.
SessionListParams
GET /v1/sessions — the sessions listing.
SessionTracesParams
GET /v1/sessions/{id}/traces — the derived span read model.
SkillsListParams
GET /v1/skills — the skills listing.
StatsParams
GET /v1/stats — the aggregate rollups.
TraceListParams
GET /v1/traces — the trace summaries for one session.
TraceParams
GET /v1/traces/{trace_id} — one trace with its spans.

Enums§

ExportDetail
The grain an export is written at.
PayloadDetail
How much of a span’s payload a trace read should carry.
SkillScope
Whose skills a listing covers.
SkillSort
How a skills listing is ordered.
SortDirection
Which way a listing is ordered.

Traits§

ContractEnum
A parameter whose accepted values the contract closes with an enum.
ContractParams
One operation’s parameters, in the shape the contract declares them.