import type { KeyObject } from "node:crypto"; import type { PublicJwkP256 } from "./keys.js"; export declare function signCompactJwt(payload: object, privateKey: KeyObject, kid: string): string; /** Verify + decode. Returns `undefined` on ANY failure — a caller must not tell them apart. */ export declare function verifyCompactJwt(token: string, publicJwk: PublicJwkP256): T | undefined; /** * Decode one base64url JSON segment — a JWS header or payload, a disclosure, a `transaction_data` * entry — WITHOUT verifying it. `undefined` when it is not JSON. The one decoder in this package: * read with it to route (which key, which claim), never to decide. */ export declare function peekJson>(segment: string | undefined): T | undefined; /** Decode WITHOUT verifying — only for reading a `kid` to decide which key to check against. */ export declare function peekJwtHeader(token: string): Record | undefined;