diff --git a/.changeset/odd-hairs-remember.md b/.changeset/odd-hairs-remember.md new file mode 100644 index 0000000000..e43300bfbf --- /dev/null +++ b/.changeset/odd-hairs-remember.md @@ -0,0 +1,5 @@ +--- +'@backstage/catalog-client': minor +--- + +**BREAKING**: Removed the deprecated `presence` field in the `Location` and `AddLocationRequest` types. This field was already being ignored by the catalog backend and can be safely removed. diff --git a/.changeset/wild-lemons-pump.md b/.changeset/wild-lemons-pump.md new file mode 100644 index 0000000000..e869abe2ac --- /dev/null +++ b/.changeset/wild-lemons-pump.md @@ -0,0 +1,5 @@ +--- +'@backstage/plugin-catalog-backend': minor +--- + +**BREAKING**: Removed the deprecated `presence` field from `LocationInput`. diff --git a/packages/catalog-client/api-report.md b/packages/catalog-client/api-report.md index ac8f712e11..5fcae87dd5 100644 --- a/packages/catalog-client/api-report.md +++ b/packages/catalog-client/api-report.md @@ -11,7 +11,6 @@ export type AddLocationRequest = { type?: string; target: string; dryRun?: boolean; - presence?: 'optional' | 'required'; }; // @public @@ -79,7 +78,7 @@ export class CatalogClient implements CatalogApi { }; }); addLocation( - { type, target, dryRun, presence }: AddLocationRequest, + { type, target, dryRun }: AddLocationRequest, options?: CatalogRequestOptions, ): Promise; getEntities( @@ -195,7 +194,6 @@ type Location_2 = { id: string; type: string; target: string; - presence?: 'optional' | 'required'; }; export { Location_2 as Location }; ``` diff --git a/packages/catalog-client/src/CatalogClient.ts b/packages/catalog-client/src/CatalogClient.ts index 85aada616c..371ac55db4 100644 --- a/packages/catalog-client/src/CatalogClient.ts +++ b/packages/catalog-client/src/CatalogClient.ts @@ -272,7 +272,7 @@ export class CatalogClient implements CatalogApi { * {@inheritdoc CatalogApi.addLocation} */ async addLocation( - { type = 'url', target, dryRun, presence }: AddLocationRequest, + { type = 'url', target, dryRun }: AddLocationRequest, options?: CatalogRequestOptions, ): Promise { const response = await this.fetchApi.fetch( @@ -285,7 +285,7 @@ export class CatalogClient implements CatalogApi { ...(options?.token && { Authorization: `Bearer ${options?.token}` }), }, method: 'POST', - body: JSON.stringify({ type, target, presence }), + body: JSON.stringify({ type, target }), }, ); diff --git a/packages/catalog-client/src/types/api.ts b/packages/catalog-client/src/types/api.ts index ba0c5e9359..389b82c081 100644 --- a/packages/catalog-client/src/types/api.ts +++ b/packages/catalog-client/src/types/api.ts @@ -244,8 +244,6 @@ export type Location = { id: string; type: string; target: string; - /** @deprecated This field is is ignored */ - presence?: 'optional' | 'required'; }; /** @@ -257,8 +255,6 @@ export type AddLocationRequest = { type?: string; target: string; dryRun?: boolean; - /** @deprecated This field is is ignored */ - presence?: 'optional' | 'required'; }; /** diff --git a/plugins/catalog-backend/api-report.md b/plugins/catalog-backend/api-report.md index d880159a36..42e05722c4 100644 --- a/plugins/catalog-backend/api-report.md +++ b/plugins/catalog-backend/api-report.md @@ -595,8 +595,6 @@ export type LocationEntityProcessorOptions = { // @public export interface LocationInput { - // @deprecated (undocumented) - presence?: 'optional' | 'required'; // (undocumented) target: string; // (undocumented) diff --git a/plugins/catalog-backend/src/service/types.ts b/plugins/catalog-backend/src/service/types.ts index fc315b9d89..f6cfa2e783 100644 --- a/plugins/catalog-backend/src/service/types.ts +++ b/plugins/catalog-backend/src/service/types.ts @@ -25,8 +25,6 @@ import { Location } from '@backstage/catalog-client'; export interface LocationInput { type: string; target: string; - /** @deprecated This field is ignored and will be removed */ - presence?: 'optional' | 'required'; } /**