release-2021-06-01 packages/core-plugin-api/src/apis/system/ApiRef.ts:27
Signed-off-by: Colton Padden <colton.padden@fastmail.com>
This commit is contained in:
@@ -23,10 +23,6 @@ import type { ApiRef } from './types';
|
||||
*/
|
||||
export type ApiRefConfig = {
|
||||
id: string;
|
||||
/**
|
||||
* @deprecated Will be removed in the future
|
||||
*/
|
||||
description?: string;
|
||||
};
|
||||
|
||||
class ApiRefImpl<T> implements ApiRef<T> {
|
||||
@@ -46,12 +42,6 @@ class ApiRefImpl<T> implements ApiRef<T> {
|
||||
return this.config.id;
|
||||
}
|
||||
|
||||
get description() {
|
||||
// eslint-disable-next-line no-console
|
||||
console.warn('Deprecated use of ApiRef.description');
|
||||
return this.config.description;
|
||||
}
|
||||
|
||||
// Utility for getting type of an api, using `typeof apiRef.T`
|
||||
get T(): T {
|
||||
throw new Error(`tried to read ApiRef.T of ${this}`);
|
||||
|
||||
@@ -45,5 +45,4 @@ export class ScmIntegrationsApi {
|
||||
export const scmIntegrationsApiRef: ApiRef<ScmIntegrationRegistry> =
|
||||
createApiRef({
|
||||
id: 'integration.scmintegrations',
|
||||
description: 'All of the registered SCM integrations of your config',
|
||||
});
|
||||
|
||||
@@ -19,7 +19,6 @@ import { Dag, InstanceStatus, InstanceVersion } from './types';
|
||||
|
||||
export const apacheAirflowApiRef = createApiRef<ApacheAirflowApi>({
|
||||
id: 'plugin.apacheairflow.service',
|
||||
description: 'Used by the Apache Airflow plugin to make requests',
|
||||
});
|
||||
|
||||
export type ApacheAirflowApi = {
|
||||
|
||||
@@ -20,7 +20,6 @@ import { createApiRef } from '@backstage/core-plugin-api';
|
||||
|
||||
export const apiDocsConfigRef = createApiRef<ApiDocsConfig>({
|
||||
id: 'plugin.api-docs.config',
|
||||
description: 'Used to configure api-docs widgets',
|
||||
});
|
||||
|
||||
export interface ApiDocsConfig {
|
||||
|
||||
@@ -27,8 +27,6 @@ import { createApiRef } from '@backstage/core-plugin-api';
|
||||
|
||||
export const azureDevOpsApiRef = createApiRef<AzureDevOpsApi>({
|
||||
id: 'plugin.azure-devops.service',
|
||||
description:
|
||||
'Used by the Azure DevOps plugin to make requests to accompanying backend',
|
||||
});
|
||||
|
||||
export interface AzureDevOpsApi {
|
||||
|
||||
@@ -19,7 +19,6 @@ import { createApiRef } from '@backstage/core-plugin-api';
|
||||
|
||||
export const badgesApiRef = createApiRef<BadgesApi>({
|
||||
id: 'plugin.badges.client',
|
||||
description: 'Used to make requests to the badges backend',
|
||||
});
|
||||
|
||||
export type BadgeStyle =
|
||||
|
||||
@@ -24,7 +24,6 @@ import { BazaarProject } from './types';
|
||||
|
||||
export const bazaarApiRef = createApiRef<BazaarApi>({
|
||||
id: 'bazaar',
|
||||
description: 'Used to make requests towards the bazaar backend',
|
||||
});
|
||||
|
||||
export interface BazaarApi {
|
||||
|
||||
@@ -26,8 +26,6 @@ import {
|
||||
|
||||
export const bitriseApiRef = createApiRef<BitriseApi>({
|
||||
id: 'plugin.bitrise.service',
|
||||
description:
|
||||
'Used by the BitriseCI plugin to retrieve information about builds.',
|
||||
});
|
||||
|
||||
export const bitrisePlugin = createPlugin({
|
||||
|
||||
@@ -20,7 +20,6 @@ import { PartialEntity } from '../types';
|
||||
|
||||
export const catalogImportApiRef = createApiRef<CatalogImportApi>({
|
||||
id: 'plugin.catalog-import.service',
|
||||
description: 'Used by the catalog import plugin to make requests',
|
||||
});
|
||||
|
||||
// result of the analyze state
|
||||
|
||||
@@ -33,7 +33,6 @@ export type { BuildWithSteps, BuildStepAction, BuildSummary };
|
||||
|
||||
export const circleCIApiRef = createApiRef<CircleCIApi>({
|
||||
id: 'plugin.circleci.service',
|
||||
description: 'Used by the CircleCI plugin to make requests',
|
||||
});
|
||||
|
||||
const DEFAULT_PROXY_PATH = '/circleci/api';
|
||||
|
||||
@@ -22,7 +22,6 @@ import { createApiRef } from '@backstage/core-plugin-api';
|
||||
|
||||
export const cloudbuildApiRef = createApiRef<CloudbuildApi>({
|
||||
id: 'plugin.cloudbuild.service',
|
||||
description: 'Used by the Cloudbuild plugin to make requests',
|
||||
});
|
||||
|
||||
export type CloudbuildApi = {
|
||||
|
||||
@@ -34,7 +34,6 @@ export type CodeCoverageApi = {
|
||||
|
||||
export const codeCoverageApiRef = createApiRef<CodeCoverageApi>({
|
||||
id: 'plugin.code-coverage.service',
|
||||
description: 'Used by the code coverage plugin to make requests',
|
||||
});
|
||||
|
||||
export class CodeCoverageRestApi implements CodeCoverageApi {
|
||||
|
||||
@@ -148,5 +148,4 @@ export type CostInsightsApi = {
|
||||
|
||||
export const costInsightsApiRef = createApiRef<CostInsightsApi>({
|
||||
id: 'plugin.costinsights.service',
|
||||
description: 'Provides cost data and alerts for the cost-insights plugin',
|
||||
});
|
||||
|
||||
@@ -18,7 +18,6 @@ import { createApiRef } from '@backstage/core-plugin-api';
|
||||
|
||||
export const exploreToolsConfigRef = createApiRef<ExploreToolsConfig>({
|
||||
id: 'plugin.explore.toolsconfig',
|
||||
description: 'Used to configure tools displayed in the explore plugin',
|
||||
});
|
||||
|
||||
export type ExploreTool = {
|
||||
|
||||
@@ -39,7 +39,6 @@ export interface FireHydrantAPI {
|
||||
|
||||
export const fireHydrantApiRef = createApiRef<FireHydrantAPI>({
|
||||
id: 'plugin.firehydrant.service',
|
||||
description: 'Used by FireHydrant plugin for requests',
|
||||
});
|
||||
|
||||
export type Options = {
|
||||
|
||||
@@ -26,7 +26,6 @@ export interface FindingSummary {
|
||||
|
||||
export const fossaApiRef = createApiRef<FossaApi>({
|
||||
id: 'plugin.fossa.service',
|
||||
description: 'Used by the Fossa plugin to make requests',
|
||||
});
|
||||
|
||||
export type FossaApi = {
|
||||
|
||||
@@ -19,7 +19,6 @@ import { createApiRef } from '@backstage/core-plugin-api';
|
||||
|
||||
export const gcpApiRef = createApiRef<GcpApi>({
|
||||
id: 'plugin.gcpprojects.service',
|
||||
description: 'Used by the GCP Projects plugin to make requests',
|
||||
});
|
||||
|
||||
export type GcpApi = {
|
||||
|
||||
@@ -20,5 +20,4 @@ import { createApiRef } from '@backstage/core-plugin-api';
|
||||
|
||||
export const gitReleaseManagerApiRef = createApiRef<GitReleaseApi>({
|
||||
id: 'plugin.git-release-manager.service',
|
||||
description: 'Used by the Git Release Manager plugin to make requests',
|
||||
});
|
||||
|
||||
@@ -19,7 +19,6 @@ import { createApiRef } from '@backstage/core-plugin-api';
|
||||
|
||||
export const githubActionsApiRef = createApiRef<GithubActionsApi>({
|
||||
id: 'plugin.githubactions.service',
|
||||
description: 'Used by the GitHub Actions plugin to make requests',
|
||||
});
|
||||
|
||||
export type GithubActionsApi = {
|
||||
|
||||
@@ -91,7 +91,6 @@ export interface GithubDeploymentsApi {
|
||||
|
||||
export const githubDeploymentsApiRef = createApiRef<GithubDeploymentsApi>({
|
||||
id: 'plugin.github-deployments.service',
|
||||
description: 'Used by the GitHub Deployments plugin to make requests',
|
||||
});
|
||||
|
||||
export type Options = {
|
||||
|
||||
@@ -113,7 +113,6 @@ export type GitOpsApi = {
|
||||
|
||||
export const gitOpsApiRef = createApiRef<GitOpsApi>({
|
||||
id: 'plugin.gitops.service',
|
||||
description: 'Used by the GitOps profiles plugin to make requests',
|
||||
});
|
||||
|
||||
export class GitOpsRestApi implements GitOpsApi {
|
||||
|
||||
@@ -41,7 +41,6 @@ import {
|
||||
|
||||
export const ilertApiRef = createApiRef<ILertApi>({
|
||||
id: 'plugin.ilert.service',
|
||||
description: 'Used to make requests towards iLert API',
|
||||
});
|
||||
|
||||
const DEFAULT_PROXY_PATH = '/ilert';
|
||||
|
||||
@@ -23,7 +23,6 @@ import { EntityName, EntityRef } from '@backstage/catalog-model';
|
||||
|
||||
export const jenkinsApiRef = createApiRef<JenkinsApi>({
|
||||
id: 'plugin.jenkins.service2',
|
||||
description: 'Used by the Jenkins plugin to make requests',
|
||||
});
|
||||
|
||||
export interface Build {
|
||||
|
||||
@@ -18,8 +18,6 @@ import { createApiRef } from '@backstage/core-plugin-api';
|
||||
|
||||
export const kafkaApiRef = createApiRef<KafkaApi>({
|
||||
id: 'plugin.kafka.service',
|
||||
description:
|
||||
'Used by the Kafka plugin to make requests to accompanying backend',
|
||||
});
|
||||
|
||||
export type ConsumerGroupOffsetsResponse = {
|
||||
|
||||
@@ -22,8 +22,6 @@ import { createApiRef } from '@backstage/core-plugin-api';
|
||||
|
||||
export const kubernetesApiRef = createApiRef<KubernetesApi>({
|
||||
id: 'plugin.kubernetes.service',
|
||||
description:
|
||||
'Used by the Kubernetes plugin to make requests to accompanying backend',
|
||||
});
|
||||
|
||||
export interface KubernetesApi {
|
||||
|
||||
@@ -26,8 +26,6 @@ export interface KubernetesAuthProvider {
|
||||
export const kubernetesAuthProvidersApiRef =
|
||||
createApiRef<KubernetesAuthProvidersApi>({
|
||||
id: 'plugin.kubernetes-auth-providers.service',
|
||||
description:
|
||||
'Used by the Kubernetes plugin to fetch KubernetesAuthProviders',
|
||||
});
|
||||
|
||||
export interface KubernetesAuthProvidersApi {
|
||||
|
||||
@@ -109,7 +109,6 @@ export type LighthouseApi = {
|
||||
|
||||
export const lighthouseApiRef = createApiRef<LighthouseApi>({
|
||||
id: 'plugin.lighthouse.service',
|
||||
description: 'Used by the Lighthouse plugin to make requests',
|
||||
});
|
||||
|
||||
export class LighthouseRestApi implements LighthouseApi {
|
||||
|
||||
@@ -55,7 +55,6 @@ export type NewRelicApplications = {
|
||||
|
||||
export const newRelicApiRef = createApiRef<NewRelicApi>({
|
||||
id: 'plugin.newrelic.service',
|
||||
description: 'Used by the NewRelic plugin to make requests',
|
||||
});
|
||||
|
||||
const DEFAULT_PROXY_PATH_BASE = '/newrelic';
|
||||
|
||||
@@ -35,7 +35,6 @@ export class UnauthorizedError extends Error {}
|
||||
|
||||
export const pagerDutyApiRef = createApiRef<PagerDutyApi>({
|
||||
id: 'plugin.pagerduty.api',
|
||||
description: 'Used to fetch data from PagerDuty API',
|
||||
});
|
||||
|
||||
export class PagerDutyClient implements PagerDutyApi {
|
||||
|
||||
@@ -23,8 +23,6 @@ import { createApiRef } from '@backstage/core-plugin-api';
|
||||
|
||||
export const rollbarApiRef = createApiRef<RollbarApi>({
|
||||
id: 'plugin.rollbar.service',
|
||||
description:
|
||||
'Used by the Rollbar plugin to make requests to accompanying backend',
|
||||
});
|
||||
|
||||
export interface RollbarApi {
|
||||
|
||||
@@ -30,7 +30,6 @@ import { ListActionsResponse, ScaffolderTask, Status } from './types';
|
||||
|
||||
export const scaffolderApiRef = createApiRef<ScaffolderApi>({
|
||||
id: 'plugin.scaffolder.service',
|
||||
description: 'Used to make requests towards the scaffolder backend',
|
||||
});
|
||||
|
||||
type TemplateParameterSchema = {
|
||||
|
||||
@@ -25,7 +25,6 @@ import qs from 'qs';
|
||||
|
||||
export const searchApiRef = createApiRef<SearchApi>({
|
||||
id: 'plugin.search.queryservice',
|
||||
description: 'Used to make requests against the search API',
|
||||
});
|
||||
|
||||
export interface SearchApi {
|
||||
|
||||
@@ -19,7 +19,6 @@ import { createApiRef } from '@backstage/core-plugin-api';
|
||||
|
||||
export const sentryApiRef = createApiRef<SentryApi>({
|
||||
id: 'plugin.sentry.service',
|
||||
description: 'Used by the Sentry plugin to make requests',
|
||||
});
|
||||
|
||||
export interface SentryApi {
|
||||
|
||||
@@ -20,7 +20,6 @@ import { Observable } from '@backstage/types';
|
||||
|
||||
export const shortcutsApiRef = createApiRef<ShortcutApi>({
|
||||
id: 'plugin.shortcuts.api',
|
||||
description: 'API to handle shortcuts in a Backstage Sidebar',
|
||||
});
|
||||
|
||||
export interface ShortcutApi {
|
||||
|
||||
@@ -35,7 +35,6 @@ export interface FindingSummary {
|
||||
|
||||
export const sonarQubeApiRef = createApiRef<SonarQubeApi>({
|
||||
id: 'plugin.sonarqube.service',
|
||||
description: 'Used by the SonarQube plugin to make requests',
|
||||
});
|
||||
|
||||
export type SonarQubeApi = {
|
||||
|
||||
@@ -41,7 +41,6 @@ export class UnauthorizedError extends Error {}
|
||||
|
||||
export const splunkOnCallApiRef = createApiRef<SplunkOnCallApi>({
|
||||
id: 'plugin.splunk-on-call.api',
|
||||
description: 'Used to fetch data from Splunk On-Call API',
|
||||
});
|
||||
|
||||
export class SplunkOnCallClient implements SplunkOnCallApi {
|
||||
|
||||
@@ -22,7 +22,6 @@ import { EntityName } from '@backstage/catalog-model';
|
||||
|
||||
export const techInsightsApiRef = createApiRef<TechInsightsApi>({
|
||||
id: 'plugin.techinsights.service',
|
||||
description: 'Used by the tech insights plugin to make requests',
|
||||
});
|
||||
|
||||
export interface TechInsightsApi {
|
||||
|
||||
@@ -21,7 +21,6 @@ import { ApiRef, createApiRef } from '@backstage/core-plugin-api';
|
||||
export const techRadarApiRef: ApiRef<TechRadarApi> = createApiRef<TechRadarApi>(
|
||||
{
|
||||
id: 'plugin.techradar.service',
|
||||
description: 'Used to populate data in the TechRadar plugin',
|
||||
},
|
||||
);
|
||||
|
||||
|
||||
@@ -20,12 +20,10 @@ import { createApiRef } from '@backstage/core-plugin-api';
|
||||
|
||||
export const techdocsStorageApiRef = createApiRef<TechDocsStorageApi>({
|
||||
id: 'plugin.techdocs.storageservice',
|
||||
description: 'Used to make requests towards the techdocs storage',
|
||||
});
|
||||
|
||||
export const techdocsApiRef = createApiRef<TechDocsApi>({
|
||||
id: 'plugin.techdocs.service',
|
||||
description: 'Used to make requests towards techdocs API',
|
||||
});
|
||||
|
||||
export type SyncResult = 'cached' | 'updated';
|
||||
|
||||
@@ -107,5 +107,4 @@ export interface TodoApi {
|
||||
*/
|
||||
export const todoApiRef = createApiRef<TodoApi>({
|
||||
id: 'plugin.todo.api',
|
||||
description: 'Lists TODOs',
|
||||
});
|
||||
|
||||
@@ -193,5 +193,4 @@ export interface XcmetricsApi {
|
||||
|
||||
export const xcmetricsApiRef = createApiRef<XcmetricsApi>({
|
||||
id: 'plugin.xcmetrics.api',
|
||||
description: 'Used by the XCMetrics plugin to make requests',
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user