eve
Version:
Filesystem-first framework for durable backend AI agents that run anywhere.
17 lines (16 loc) • 828 B
TypeScript
import type { DeliverPayload } from "#channel/types.js";
import type { AuthorizationResult, PendingAuthorizationState } from "#harness/authorization.js";
import type { ConnectionAuthorizationChallenge } from "#connections/errors.js";
export interface MatchedAuthorizationCallback {
readonly authorization: ConnectionAuthorizationChallenge;
readonly candidateId?: string;
readonly result: {
readonly name: string;
readonly attemptId: string;
} & AuthorizationResult;
}
/** Matches each callback to exactly one pending authorization attempt. */
export declare function matchAuthorizationCallbacks(pending: PendingAuthorizationState, payloads: readonly DeliverPayload[]): {
readonly matches: readonly MatchedAuthorizationCallback[];
readonly remainingPayloads: readonly DeliverPayload[];
};