Class AuthRecording

Namespace
Kuestenlogik.Bowire.Mocking
Assembly
Kuestenlogik.Bowire.dll

A captured authentication credential, addressable by id (#563). A schema mock's AuthRecordingId references one of these; the mock's config-apply path resolves it into the #562 gate's accepted credential, so an operator picks a recording instead of pasting a token.

public sealed class AuthRecording
Inheritance
AuthRecording
Inherited Members

Remarks

This slice stores a STATIC captured credential — the low-friction fit for #562's exact-match gate. Re-running an AuthFlowDefinition on resolve (an outbound call, opt-in) and the interactive capture UI are the remaining #sec-04 / #190 follow-ups. Persisted per workspace at workspaces/<wsId>/auth-recordings/<id>.json by AuthRecordingStore as plaintext JSON — the same at-rest posture as the mock-config sidecar's own Credential.

Constructors

AuthRecording()

public AuthRecording()

Properties

CapturedAt

Unix-ms capture time, for a staleness hint in the UI. 0 when unknown.

[JsonPropertyName("capturedAt")]
public long CapturedAt { get; set; }

Property Value

long

Credential

The captured credential value the gate accepts (bearer/basic token or api-key).

[JsonPropertyName("credential")]
public string Credential { get; set; }

Property Value

string

Header

Header the credential is presented in (default Authorization). Populates the gate's header.

[JsonPropertyName("header")]
public string? Header { get; set; }

Property Value

string

Id

Stable id the mock config references via authRecordingId; also the on-disk filename.

[JsonPropertyName("id")]
public string Id { get; set; }

Property Value

string

Name

Human label shown in the picker. Falls back to the id when absent.

[JsonPropertyName("name")]
public string? Name { get; set; }

Property Value

string

Scheme

Credential scheme — bearer / apikey / basic (default bearer). Populates the gate's scheme.

[JsonPropertyName("scheme")]
public string? Scheme { get; set; }

Property Value

string

Methods

Parse(string?)

Parse a recording document. An empty / whitespace document yields a default (empty) recording; throws JsonException when the payload is not a JSON object of the expected shape.

public static AuthRecording Parse(string? json)

Parameters

json string

Returns

AuthRecording

ToJson()

Serialize to the canonical on-disk / wire JSON shape.

public string ToJson()

Returns

string