kubernetes: export API types
Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
This commit is contained in:
@@ -0,0 +1,5 @@
|
||||
---
|
||||
'@backstage/plugin-kubernetes': patch
|
||||
---
|
||||
|
||||
Exported `KubernetesApi`, `kubernetesApiRef`, and `KubernetesAuthProvidersApi`.
|
||||
@@ -10,6 +10,7 @@ import { BackstagePlugin } from '@backstage/core-plugin-api';
|
||||
import { Entity } from '@backstage/catalog-model';
|
||||
import { KubernetesRequestBody } from '@backstage/plugin-kubernetes-common';
|
||||
import { OAuthApi } from '@backstage/core-plugin-api';
|
||||
import { ObjectsByEntityResponse } from '@backstage/plugin-kubernetes-common';
|
||||
import { RouteRef } from '@backstage/core-plugin-api';
|
||||
|
||||
// Warning: (ae-forgotten-export) The symbol "ClusterLinksFormatter" needs to be exported by the entry point index.d.ts
|
||||
@@ -38,7 +39,28 @@ export function formatClusterLink(
|
||||
// @public (undocumented)
|
||||
export const isKubernetesAvailable: (entity: Entity) => boolean;
|
||||
|
||||
// Warning: (ae-forgotten-export) The symbol "KubernetesAuthProvidersApi" needs to be exported by the entry point index.d.ts
|
||||
// Warning: (ae-missing-release-tag) "KubernetesApi" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal)
|
||||
//
|
||||
// @public (undocumented)
|
||||
export interface KubernetesApi {
|
||||
// (undocumented)
|
||||
getClusters(): Promise<
|
||||
{
|
||||
name: string;
|
||||
authProvider: string;
|
||||
}[]
|
||||
>;
|
||||
// (undocumented)
|
||||
getObjectsByEntity(
|
||||
requestBody: KubernetesRequestBody,
|
||||
): Promise<ObjectsByEntityResponse>;
|
||||
}
|
||||
|
||||
// Warning: (ae-missing-release-tag) "kubernetesApiRef" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal)
|
||||
//
|
||||
// @public (undocumented)
|
||||
export const kubernetesApiRef: ApiRef<KubernetesApi>;
|
||||
|
||||
// Warning: (ae-missing-release-tag) "KubernetesAuthProviders" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal)
|
||||
//
|
||||
// @public (undocumented)
|
||||
@@ -51,6 +73,17 @@ export class KubernetesAuthProviders implements KubernetesAuthProvidersApi {
|
||||
): Promise<KubernetesRequestBody>;
|
||||
}
|
||||
|
||||
// Warning: (ae-missing-release-tag) "KubernetesAuthProvidersApi" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal)
|
||||
//
|
||||
// @public (undocumented)
|
||||
export interface KubernetesAuthProvidersApi {
|
||||
// (undocumented)
|
||||
decorateRequestBodyForAuth(
|
||||
authProvider: string,
|
||||
requestBody: KubernetesRequestBody,
|
||||
): Promise<KubernetesRequestBody>;
|
||||
}
|
||||
|
||||
// Warning: (ae-missing-release-tag) "kubernetesAuthProvidersApiRef" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal)
|
||||
//
|
||||
// @public (undocumented)
|
||||
|
||||
@@ -0,0 +1,18 @@
|
||||
/*
|
||||
* Copyright 2021 The Backstage Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
export { kubernetesApiRef } from './types';
|
||||
export type { KubernetesApi } from './types';
|
||||
@@ -26,5 +26,6 @@ export {
|
||||
EntityKubernetesContent,
|
||||
} from './plugin';
|
||||
export { Router, isKubernetesAvailable } from './Router';
|
||||
export * from './api';
|
||||
export * from './kubernetes-auth-provider';
|
||||
export * from './utils/clusterLinks';
|
||||
|
||||
@@ -15,4 +15,5 @@
|
||||
*/
|
||||
|
||||
export { kubernetesAuthProvidersApiRef } from './types';
|
||||
export type { KubernetesAuthProvidersApi } from './types';
|
||||
export { KubernetesAuthProviders } from './KubernetesAuthProviders';
|
||||
|
||||
Reference in New Issue
Block a user