diff --git a/packages/backend/src/plugins/badges.ts b/packages/backend/src/plugins/badges.ts index 37529689f3..fa50731809 100644 --- a/packages/backend/src/plugins/badges.ts +++ b/packages/backend/src/plugins/badges.ts @@ -28,5 +28,8 @@ export default async function createPlugin( config: env.config, discovery: env.discovery, badgeFactories: createDefaultBadgeFactories(), + tokenManager: env.tokenManager, + logger: env.logger, + identity: env.identity, }); } diff --git a/plugins/badges-backend/api-report.md b/plugins/badges-backend/api-report.md index 8ca4b561a2..f43acf395f 100644 --- a/plugins/badges-backend/api-report.md +++ b/plugins/badges-backend/api-report.md @@ -7,7 +7,10 @@ import { CatalogApi } from '@backstage/catalog-client'; import { Config } from '@backstage/config'; import { Entity } from '@backstage/catalog-model'; import express from 'express'; +import { IdentityApi } from '@backstage/plugin-auth-node'; +import { Logger } from 'winston'; import { PluginEndpointDiscovery } from '@backstage/backend-common'; +import { TokenManager } from '@backstage/backend-common'; // @public (undocumented) export interface Badge { @@ -112,5 +115,11 @@ export interface RouterOptions { config: Config; // (undocumented) discovery: PluginEndpointDiscovery; + // (undocumented) + identity: IdentityApi; + // (undocumented) + logger: Logger; + // (undocumented) + tokenManager: TokenManager; } ``` diff --git a/plugins/badges-backend/package.json b/plugins/badges-backend/package.json index 2983b17eb4..29c824fd70 100644 --- a/plugins/badges-backend/package.json +++ b/plugins/badges-backend/package.json @@ -50,11 +50,11 @@ "yn": "^4.0.0" }, "devDependencies": { - "@backstage/catalog-client": "^1.3.1", + "@backstage/catalog-client": "workspace:^", "@backstage/cli": "workspace:^", - "@backstage/core-app-api": "^1.5.0", - "@backstage/dev-utils": "^1.0.12", - "@backstage/test-utils": "^1.2.5", + "@backstage/core-app-api": "workspace:^", + "@backstage/dev-utils": "workspace:^", + "@backstage/test-utils": "workspace:^", "@testing-library/jest-dom": "^5.10.1", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", diff --git a/yarn.lock b/yarn.lock index c2576e0795..213f03d6b1 100644 --- a/yarn.lock +++ b/yarn.lock @@ -3433,25 +3433,6 @@ __metadata: languageName: node linkType: hard -"@backstage/app-defaults@npm:^1.2.1": - version: 1.2.1 - resolution: "@backstage/app-defaults@npm:1.2.1" - dependencies: - "@backstage/core-app-api": ^1.6.0 - "@backstage/core-components": ^0.12.5 - "@backstage/core-plugin-api": ^1.5.0 - "@backstage/plugin-permission-react": ^0.4.11 - "@backstage/theme": ^0.2.18 - "@material-ui/core": ^4.12.2 - "@material-ui/icons": ^4.9.1 - peerDependencies: - react: ^16.13.1 || ^17.0.0 - react-dom: ^16.13.1 || ^17.0.0 - react-router-dom: 6.0.0-beta.0 || ^6.3.0 - checksum: 436a3708452aca4f9cb4c4cc6e8a9a41a8e2fe3831c01fe139bd3eb5b2eee9ee1a67f13244c5bee281927fe9ad12ea87ffb9d0c07587287b7a56ccce0f9043ec - languageName: node - linkType: hard - "@backstage/app-defaults@workspace:^, @backstage/app-defaults@workspace:packages/app-defaults": version: 0.0.0-use.local resolution: "@backstage/app-defaults@workspace:packages/app-defaults" @@ -3982,27 +3963,6 @@ __metadata: languageName: unknown linkType: soft -"@backstage/core-app-api@npm:^1.5.0, @backstage/core-app-api@npm:^1.6.0": - version: 1.6.0 - resolution: "@backstage/core-app-api@npm:1.6.0" - dependencies: - "@backstage/config": ^1.0.7 - "@backstage/core-plugin-api": ^1.5.0 - "@backstage/types": ^1.0.2 - "@backstage/version-bridge": ^1.0.3 - "@types/prop-types": ^15.7.3 - prop-types: ^15.7.2 - react-use: ^17.2.4 - zen-observable: ^0.10.0 - zod: ~3.18.0 - peerDependencies: - "@types/react": ^16.13.1 || ^17.0.0 - react: ^16.13.1 || ^17.0.0 - react-router-dom: 6.0.0-beta.0 || ^6.3.0 - checksum: 301a765f877a5573861faccd4256033457ab40cb46b96ecbeaad749684d98ab4a0502919df22b8ef582e7575fb9224c9d3f5b19ed61209f98cd06f22a87c0930 - languageName: node - linkType: hard - "@backstage/core-app-api@workspace:^, @backstage/core-app-api@workspace:packages/core-app-api": version: 0.0.0-use.local resolution: "@backstage/core-app-api@workspace:packages/core-app-api" @@ -4222,35 +4182,6 @@ __metadata: languageName: unknown linkType: soft -"@backstage/dev-utils@npm:^1.0.12": - version: 1.0.13 - resolution: "@backstage/dev-utils@npm:1.0.13" - dependencies: - "@backstage/app-defaults": ^1.2.1 - "@backstage/catalog-model": ^1.2.1 - "@backstage/core-app-api": ^1.6.0 - "@backstage/core-components": ^0.12.5 - "@backstage/core-plugin-api": ^1.5.0 - "@backstage/integration-react": ^1.1.11 - "@backstage/plugin-catalog-react": ^1.4.0 - "@backstage/test-utils": ^1.2.6 - "@backstage/theme": ^0.2.18 - "@material-ui/core": ^4.12.2 - "@material-ui/icons": ^4.9.1 - "@testing-library/jest-dom": ^5.10.1 - "@testing-library/react": ^12.1.3 - "@testing-library/user-event": ^14.0.0 - react-use: ^17.2.4 - zen-observable: ^0.10.0 - peerDependencies: - "@types/react": ^16.13.1 || ^17.0.0 - react: ^16.13.1 || ^17.0.0 - react-dom: ^16.13.1 || ^17.0.0 - react-router-dom: 6.0.0-beta.0 || ^6.3.0 - checksum: 37de3090b644b7c0c040cebb99fbd6b4e7249c4ca85bcfea658d202fe94dae6b70460ecb69e201ffee5f877a43bddef315b88e3716f0087d42bedf16fe741e91 - languageName: node - linkType: hard - "@backstage/dev-utils@workspace:^, @backstage/dev-utils@workspace:packages/dev-utils": version: 0.0.0-use.local resolution: "@backstage/dev-utils@workspace:packages/dev-utils" @@ -5002,15 +4933,15 @@ __metadata: resolution: "@backstage/plugin-badges-backend@workspace:plugins/badges-backend" dependencies: "@backstage/backend-common": "workspace:^" - "@backstage/catalog-client": ^1.3.1 + "@backstage/catalog-client": "workspace:^" "@backstage/catalog-model": "workspace:^" "@backstage/cli": "workspace:^" "@backstage/config": "workspace:^" - "@backstage/core-app-api": ^1.5.0 - "@backstage/dev-utils": ^1.0.12 + "@backstage/core-app-api": "workspace:^" + "@backstage/dev-utils": "workspace:^" "@backstage/errors": "workspace:^" "@backstage/plugin-auth-node": "workspace:^" - "@backstage/test-utils": ^1.2.5 + "@backstage/test-utils": "workspace:^" "@testing-library/jest-dom": ^5.10.1 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 @@ -9539,33 +9470,6 @@ __metadata: languageName: unknown linkType: soft -"@backstage/test-utils@npm:^1.2.5, @backstage/test-utils@npm:^1.2.6": - version: 1.2.6 - resolution: "@backstage/test-utils@npm:1.2.6" - dependencies: - "@backstage/config": ^1.0.7 - "@backstage/core-app-api": ^1.6.0 - "@backstage/core-plugin-api": ^1.5.0 - "@backstage/plugin-permission-common": ^0.7.4 - "@backstage/plugin-permission-react": ^0.4.11 - "@backstage/theme": ^0.2.18 - "@backstage/types": ^1.0.2 - "@material-ui/core": ^4.12.2 - "@material-ui/icons": ^4.9.1 - "@testing-library/jest-dom": ^5.10.1 - "@testing-library/react": ^12.1.3 - "@testing-library/user-event": ^14.0.0 - cross-fetch: ^3.1.5 - zen-observable: ^0.10.0 - peerDependencies: - "@types/react": ^16.13.1 || ^17.0.0 - react: ^16.13.1 || ^17.0.0 - react-dom: ^16.13.1 || ^17.0.0 - react-router-dom: 6.0.0-beta.0 || ^6.3.0 - checksum: 0ae8e0f9f2779cae0d0ba30622b5c4fc2f150685da94e63019cd3314ac5b3033c49c4ecf0bcf9815eeb4d74cfc573cea8f756626ed4aa933f8104e57e1c7e4a5 - languageName: node - linkType: hard - "@backstage/test-utils@workspace:^, @backstage/test-utils@workspace:packages/test-utils": version: 0.0.0-use.local resolution: "@backstage/test-utils@workspace:packages/test-utils"