Defines shared wire types and schemas for the authentication broker server and clients. Reuse when managing OAuth tokens and usage tracking.
// Source: https://github.com/can1357/oh-my-pi | License: MIT | Copyright 2025 Mario Zechner
// Provided via justclaw.it.com; keep this notice with the code.
/**
* Wire types shared between the auth-broker server and clients.
*
* The broker holds OAuth refresh tokens and exposes a redacted snapshot;
* clients use `access` tokens directly and call back to the broker when a
* credential expires or a 401 surfaces on a supposedly-fresh credential.
*/
import type {
AuthCredential,
AuthCredentialSnapshot,
AuthCredentialSnapshotEntry,
DisabledCredentialSummary,
StoredCredentialBlock,
} from "../auth-storage";
import type { ClientUsageClientSummary, ClientUsageReport, UsageHistoryEntry, UsageReport } from "../usage";
/** GET /v1/healthz response body. */
export interface HealthzRespon
... (truncated -- full source via MCP)
See the full source, get the GitHub permalink, and search for more like it.
Get a free API key