From 46eb6556505244147807a185b67fa2ebd8bdbd2c Mon Sep 17 00:00:00 2001 From: Manuel Scurti Date: Wed, 18 May 2022 18:14:03 +0200 Subject: [PATCH] fixed api reports Signed-off-by: Manuel Scurti --- plugins/auth-node/api-report.md | 12 ++++++++---- plugins/auth-node/src/IdentityClient.ts | 6 ++++++ plugins/auth-node/src/index.ts | 1 + 3 files changed, 15 insertions(+), 4 deletions(-) diff --git a/plugins/auth-node/api-report.md b/plugins/auth-node/api-report.md index f7fdd6369b..80c00b43fc 100644 --- a/plugins/auth-node/api-report.md +++ b/plugins/auth-node/api-report.md @@ -30,9 +30,13 @@ export function getBearerTokenFromAuthorizationHeader( // @public export class IdentityClient { authenticate(token: string | undefined): Promise; - static create(options: { - discovery: PluginEndpointDiscovery; - issuer: string; - }): IdentityClient; + static create(options: IdentityClientOptions): IdentityClient; } + +// @public +export type IdentityClientOptions = { + discovery: PluginEndpointDiscovery; + issuer: string; + algorithms?: string[]; +}; ``` diff --git a/plugins/auth-node/src/IdentityClient.ts b/plugins/auth-node/src/IdentityClient.ts index 2da6ae31f1..3799222447 100644 --- a/plugins/auth-node/src/IdentityClient.ts +++ b/plugins/auth-node/src/IdentityClient.ts @@ -29,6 +29,12 @@ import { BackstageIdentityResponse } from './types'; const CLOCK_MARGIN_S = 10; +/** + * An identity client options object which allows extra configurations + * + * @experimental This is not a stable API yet + * @public + */ export type IdentityClientOptions = { discovery: PluginEndpointDiscovery; issuer: string; diff --git a/plugins/auth-node/src/index.ts b/plugins/auth-node/src/index.ts index 5551f2c85d..cfb7275abd 100644 --- a/plugins/auth-node/src/index.ts +++ b/plugins/auth-node/src/index.ts @@ -22,6 +22,7 @@ export { getBearerTokenFromAuthorizationHeader } from './getBearerTokenFromAuthorizationHeader'; export { IdentityClient } from './IdentityClient'; +export type { IdentityClientOptions } from './IdentityClient'; export type { BackstageIdentityResponse, BackstageSignInResult,