auth-node: deprecate getBearerTokenFromAuthorizationHeader

Co-authored-by: Fredrik Adelöw <freben@gmail.com>
Co-authored-by: Carl-Erik Bergström <cbergstrom@spotify.com>
Co-authored-by: blam <ben@blam.sh>
Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
This commit is contained in:
Patrik Oldsberg
2024-02-15 18:57:04 +01:00
parent 72572b2fe1
commit b4fc6e3164
3 changed files with 7 additions and 1 deletions
+5
View File
@@ -0,0 +1,5 @@
---
'@backstage/plugin-auth-node': patch
---
Deprecated the `getBearerTokenFromAuthorizationHeader` function, which is being replaced by the new `HttpAuthService`.
+1 -1
View File
@@ -223,7 +223,7 @@ export class DefaultIdentityClient implements IdentityApi {
// @public (undocumented)
export function encodeOAuthState(state: OAuthState): string;
// @public
// @public @deprecated
export function getBearerTokenFromAuthorizationHeader(
authorizationHeader: unknown,
): string | undefined;
@@ -24,6 +24,7 @@
* call it directly with e.g. the output of `req.header('authorization')`
* without first checking that it exists.
*
* @deprecated Use the `credentials` method of `HttpAuthService` from `@backstage/backend-plugin-api` instead
* @public
*/
export function getBearerTokenFromAuthorizationHeader(