Type Alias: IdempotentAnswer
@kortexya/reasoninglayer / IdempotentAnswer
Type Alias: IdempotentAnswer<T>
Section titled “Type Alias: IdempotentAnswer<T>”IdempotentAnswer<
T> =T&object
Defined in: src/types/common.ts:275
The answer of a route that holds its request under an Idempotency-Key
and states the replay only in the Idempotency-Replayed response header,
because its body schema has no replay flag (the attribute-exploration
transitions: confirm, refute, advance). The SDK adds replayed from that
header.
Type Declaration
Section titled “Type Declaration”replayed
Section titled “replayed”replayed:
boolean
Whether this answer replays an earlier identical request (Idempotency-Replayed: true).
Type Parameters
Section titled “Type Parameters”T
Remarks
Section titled “Remarks”replayed is true when the engine answered a repeat of a committed
request from its receipt (nothing applied again), false on a first
answer. Every other keyed route carries replayed in its body, and its own
answer type declares it (engine #981, one replay contract).
Example
Section titled “Example”const next = await client.analysis.confirmImplication(sessionId, { questionId, idempotencyKey });if (next.replayed) console.log('already confirmed under this key');