Creates the server; FakeServer.start opens the listener.
Clock, timings, DPoP, billing mode and tool class.
ReadonlyclockThe clock shared with the SDK under test.
ReadonlycredentialsLotse's API token and, with dpop, its key.
http://127.0.0.1:<port> after the start; empty before.
ReadonlysdkSettings an adapter under test should use (short waits, a leeway within auth.clock_leeway).
ReadonlytimingsThe server keys in effect: durations in milliseconds, agent.max_inflight_events a count.
Lotse's principal ID, the agent under test.
The REST base URL, origin + "/api/v1".
The registered commands by ID.
The htu of a gateway proof: always HTTPS with the server's host and port.
The gateway's WebSocket URL.
The heartbeat bodies received (REST and the gateway member agent), in order.
The instance (iss of every token).
The stored createMessage bodies (with client_msg_id), in order.
Texter's principal ID, a second agent.
Stops the server at the end of an await using block.
A promise that resolves when the server stopped.
Returns what the adapter answered before expires_at, if anything.
The request.
The choices, or undefined when no answer arrived in time.
Lets a person cancel the run: run.cancel_requested.
A queued run ends cancelled at once; an active run waits agent.cancel_grace for the
adapter's cancelled and then ends with cancel_timeout.
The run.
The payload's reason.
Closes every gateway connection with code.
A close code of docs/api/asyncapi.yaml.
Returns the consumer's stored acknowledgement and the head.
The consumer name.
The view.
Lets Alex post a follow-up to the run: agent.followup.
The run.
The message content.
The follow-up message ID.
Lets Alex operate a component of the run: interaction.created.
The run.
The component's custom ID (created on a card of the run if missing).
The submitted values.
The interaction ID.
Delivers an existing event's payload again under a new event ID with token.
The replay case of AZ-P6: the same token on a second event.
The ID of an event in the log.
The token the new delivery carries (not recorded on the run).
The new event ID.
Marks an operation deprecated: its answers carry Deprecation: true and Sunset.
The operation.
The HTTP date of the Sunset header.
Returns a forged token for the run, built from its newest delivered token.
A run without a delivery yet gets the claims its agent.invocation would carry; nothing is
recorded on the run, so it stays as it is (AG-08 sends these to a queued run).
The run.
bad_signature, alg_hs256, typ_access or aud_other_agent.
The forged token.
Returns the op of every gateway frame received from a client, in order.
Copies of the records.
Lets the next times calls of target fail with fault.
TypeError when fault is not a Fault, RangeError on a bad times.
Lets Alex run Lotse's command name (registered first if missing): command.invoked.
The command name.
The run of the thread (its thread is used) or a thread without a run.
The invocation ID of the payload.
Moves the shared clock forward (FakeClock.advance).
How far, in milliseconds.
Delivers every unacknowledged event again now, with fresh tokens and redelivered.
Optionalconsumer: stringOnly this consumer; every consumer when absent.
Registers a command of Lotse in the channel (as registerCommand would).
The command name.
The command ID.
Sends command.autocomplete_requested to a live gateway connection of Lotse.
A registered command.
What Alex has typed so far.
expiresInMs until expires_at; command.autocomplete_timeout when absent.
The request ID.
Returns every REST request received, in order: method, path and status only.
Copies of the records.
Restarts the server process and keeps its data.
Every gateway connection closes with 4013 (as the server's shutdown does), sessions and
delivery windows in memory are forgotten, and one consumer's cursor may be set; the next
delivery of every unacknowledged event carries a new token (AG-28).
Optionalconsumer: stringThe consumer whose cursor is set.
OptionalackedSeq: numberThe cursor value (for example the seq before an event, AG-28).
Starts a new DPoP nonce window now; the previous nonce stays valid one window.
Returns the run's state, reason, version and start count.
The run.
The view.
Posts a webhook signed with the FakeServer's own key (see getWebhookKeys) and the given
HMAC secrets (webhooks.md 2): webhook-id is the envelope's id, webhook-timestamp the
clock's Unix seconds, webhook-signature the v1a entry first and then the v1 entries.
The receiver.
The event envelope; its id is the webhook-id.
The HMAC secrets of the v1 entries.
The receiver's response.
Opens the listener on 127.0.0.1 with a free port.
A promise that resolves when the server listens.
Closes every connection and the listener.
A promise that resolves when everything is closed.
Lets Alex post text in a new thread: a queued run and its agent.invocation.
The message content.
The run, thread and message.
The in-process server the SDK's tests and an adapter's tests run against.
Create it with
new FakeServer(options), open it with FakeServer.start and close it with FakeServer.stop (the shape of the Python FakeServer). Members that depend on the port (FakeServer.origin, FakeServer.baseUrl, FakeServer.gatewayUrl) hold their value after the start.