ts-jose
Version:
Wrap functions of JOSE in steady interface
14 lines (13 loc) • 510 B
TypeScript
import { JWK } from './jwk.js';
import { JWKAlgorithms, JWKSObject, KeyOptions, KeyUsages } from './types.js';
export declare class JWKS {
readonly keys: JWK[];
constructor(keys: JWK[]);
getKey(options?: KeyOptions): JWK;
getKeyByKid(kid: string): JWK | undefined;
getKeyByUse(use: KeyUsages, keys?: JWK[]): JWK[];
getKeyByAlg(alg: JWKAlgorithms, keys?: JWK[]): JWK[];
toObject(): JWKSObject;
toPublic(): Promise<JWKS>;
static fromObject(jwks: JWKSObject): Promise<JWKS>;
}