From d879072b0cc89ba120a5186d2f70b928e8378d09 Mon Sep 17 00:00:00 2001 From: Patrik Oldsberg Date: Tue, 4 Jan 2022 23:31:50 +0100 Subject: [PATCH] core-plugin-api: remove deprecated id field from BackstageIdentityResponse Signed-off-by: Patrik Oldsberg --- .changeset/poor-peaches-happen.md | 7 +++++++ packages/core-plugin-api/api-report.md | 1 - packages/core-plugin-api/src/apis/definitions/auth.ts | 7 ------- 3 files changed, 7 insertions(+), 8 deletions(-) create mode 100644 .changeset/poor-peaches-happen.md diff --git a/.changeset/poor-peaches-happen.md b/.changeset/poor-peaches-happen.md new file mode 100644 index 0000000000..db5dac5093 --- /dev/null +++ b/.changeset/poor-peaches-happen.md @@ -0,0 +1,7 @@ +--- +'@backstage/core-plugin-api': minor +--- + +Removed the deprecated `id` field of `BackstageIdentityResponse`. + +Existing usage can be replaced by parsing the `name` of the `identity.userEntityRef` with `parseEntityRef` from `@backstage/catalog-model`, although note that it is recommended to consume the entire `userEntityRef` in order to support namespaces. diff --git a/packages/core-plugin-api/api-report.md b/packages/core-plugin-api/api-report.md index e55004ba35..5ac07e195c 100644 --- a/packages/core-plugin-api/api-report.md +++ b/packages/core-plugin-api/api-report.md @@ -216,7 +216,6 @@ export type BackstageIdentityApi = { // @public export type BackstageIdentityResponse = { - id: string; token: string; identity: BackstageUserIdentity; }; diff --git a/packages/core-plugin-api/src/apis/definitions/auth.ts b/packages/core-plugin-api/src/apis/definitions/auth.ts index e5a41d8973..ed5a7a3264 100644 --- a/packages/core-plugin-api/src/apis/definitions/auth.ts +++ b/packages/core-plugin-api/src/apis/definitions/auth.ts @@ -221,13 +221,6 @@ export type BackstageUserIdentity = { * @public */ export type BackstageIdentityResponse = { - /** - * The backstage user ID. - * - * @deprecated The identity is now provided via the `identity` field instead. - */ - id: string; - /** * The token used to authenticate the user within Backstage. */