From bb8ce88f2ea27d0cf4db945d0b662942976d8ed7 Mon Sep 17 00:00:00 2001 From: Brian Fletcher Date: Tue, 4 Jan 2022 15:57:07 +0000 Subject: [PATCH] api reports Signed-off-by: Brian Fletcher --- packages/integration/api-report.md | 9 +++------ plugins/catalog-backend/api-report.md | 19 ++++++++++++++----- plugins/scaffolder-backend/api-report.md | 10 +++++++++- 3 files changed, 26 insertions(+), 12 deletions(-) diff --git a/packages/integration/api-report.md b/packages/integration/api-report.md index ca24848db8..efcaa07c88 100644 --- a/packages/integration/api-report.md +++ b/packages/integration/api-report.md @@ -203,11 +203,6 @@ export interface GithubCredentialsProvider { getCredentials(opts: { url: string }): Promise; } -// @public -export type GithubCredentialsProviderFactory = ( - config: GitHubIntegrationConfig, -) => GithubCredentialsProvider; - // @public export type GithubCredentialType = 'app' | 'token'; @@ -432,7 +427,9 @@ export class SingleInstanceGithubCredentialsProvider implements GithubCredentialsProvider { // (undocumented) - static create: GithubCredentialsProviderFactory; + static create( + integrations: ScmIntegrations, + ): SingleInstanceGithubCredentialsProvider; getCredentials(opts: { url: string }): Promise; } diff --git a/plugins/catalog-backend/api-report.md b/plugins/catalog-backend/api-report.md index 13a7ec9a9e..1fe38051c9 100644 --- a/plugins/catalog-backend/api-report.md +++ b/plugins/catalog-backend/api-report.md @@ -16,7 +16,7 @@ import { EntityName } from '@backstage/catalog-model'; import { EntityPolicy } from '@backstage/catalog-model'; import { EntityRelationSpec } from '@backstage/catalog-model'; import express from 'express'; -import { GithubCredentialsProviderFactory } from '@backstage/integration'; +import { GithubCredentialsProvider } from '@backstage/integration'; import { GitHubIntegrationConfig } from '@backstage/integration'; import { IndexableDocument } from '@backstage/search-common'; import { JsonObject } from '@backstage/types'; @@ -1012,14 +1012,14 @@ export class GithubDiscoveryProcessor implements CatalogProcessor { constructor(options: { integrations: ScmIntegrations; logger: Logger_2; - githubCredentialsProviderFactory: GithubCredentialsProviderFactory; + githubCredentialsProvider: GithubCredentialsProvider; }); // (undocumented) static fromConfig( config: Config, options: { logger: Logger_2; - githubCredentialsProviderFactory?: GithubCredentialsProviderFactory; + githubCredentialsProvider: GithubCredentialsProvider; }, ): GithubDiscoveryProcessor; // (undocumented) @@ -1036,12 +1036,14 @@ export class GithubMultiOrgReaderProcessor implements CatalogProcessor { integrations: ScmIntegrations; logger: Logger_2; orgs: GithubMultiOrgConfig; + githubCredentialsProvider: GithubCredentialsProvider; }); // (undocumented) static fromConfig( config: Config, options: { logger: Logger_2; + githubCredentialsProvider: GithubCredentialsProvider; }, ): GithubMultiOrgReaderProcessor; // (undocumented) @@ -1061,6 +1063,7 @@ export class GitHubOrgEntityProvider implements EntityProvider { orgUrl: string; gitHubConfig: GitHubIntegrationConfig; logger: Logger_2; + githubCredentialsProvider: GithubCredentialsProvider; }); // (undocumented) connect(connection: EntityProviderConnection): Promise; @@ -1071,6 +1074,7 @@ export class GitHubOrgEntityProvider implements EntityProvider { id: string; orgUrl: string; logger: Logger_2; + githubCredentialsProvider: GithubCredentialsProvider; }, ): GitHubOrgEntityProvider; // (undocumented) @@ -1083,12 +1087,17 @@ export class GitHubOrgEntityProvider implements EntityProvider { // // @public export class GithubOrgReaderProcessor implements CatalogProcessor { - constructor(options: { integrations: ScmIntegrations; logger: Logger_2 }); + constructor(options: { + integrations: ScmIntegrations; + logger: Logger_2; + githubCredentialsProvider: GithubCredentialsProvider; + }); // (undocumented) static fromConfig( config: Config, options: { logger: Logger_2; + githubCredentialsProvider: GithubCredentialsProvider; }, ): GithubOrgReaderProcessor; // (undocumented) @@ -1577,7 +1586,7 @@ export class UrlReaderProcessor implements CatalogProcessor { // src/catalog/types.d.ts:94:8 - (tsdoc-param-tag-with-invalid-name) The @param block should be followed by a valid parameter name: The identifier cannot non-word characters // src/catalog/types.d.ts:95:8 - (tsdoc-param-tag-with-invalid-name) The @param block should be followed by a valid parameter name: The identifier cannot non-word characters // src/catalog/types.d.ts:96:8 - (tsdoc-param-tag-with-invalid-name) The @param block should be followed by a valid parameter name: The identifier cannot non-word characters -// src/ingestion/processors/GithubMultiOrgReaderProcessor.d.ts:23:9 - (ae-forgotten-export) The symbol "GithubMultiOrgConfig" needs to be exported by the entry point index.d.ts +// src/ingestion/processors/GithubMultiOrgReaderProcessor.d.ts:25:9 - (ae-forgotten-export) The symbol "GithubMultiOrgConfig" needs to be exported by the entry point index.d.ts // src/ingestion/types.d.ts:8:8 - (tsdoc-param-tag-missing-hyphen) The @param block should be followed by a parameter name and then a hyphen // src/legacy/database/types.d.ts:98:8 - (tsdoc-param-tag-missing-hyphen) The @param block should be followed by a parameter name and then a hyphen // src/legacy/database/types.d.ts:104:8 - (tsdoc-param-tag-missing-hyphen) The @param block should be followed by a parameter name and then a hyphen diff --git a/plugins/scaffolder-backend/api-report.md b/plugins/scaffolder-backend/api-report.md index b7c1a9146c..a292388909 100644 --- a/plugins/scaffolder-backend/api-report.md +++ b/plugins/scaffolder-backend/api-report.md @@ -14,6 +14,7 @@ import { createFetchCookiecutterAction } from '@backstage/plugin-scaffolder-back import { createPullRequest } from 'octokit-plugin-create-pull-request'; import { Entity } from '@backstage/catalog-model'; import express from 'express'; +import { GithubCredentialsProvider } from '@backstage/integration'; import { JsonObject } from '@backstage/types'; import { JsonValue } from '@backstage/types'; import { Knex } from 'knex'; @@ -123,6 +124,7 @@ export const createFilesystemRenameAction: () => TemplateAction; // @public (undocumented) export function createGithubActionsDispatchAction(options: { integrations: ScmIntegrationRegistry; + githubCredentialsProvider: GithubCredentialsProvider; }): TemplateAction; // Warning: (ae-missing-release-tag) "createGithubWebhookAction" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) @@ -131,6 +133,7 @@ export function createGithubActionsDispatchAction(options: { export function createGithubWebhookAction(options: { integrations: ScmIntegrationRegistry; defaultWebhookSecret?: string; + githubCredentialsProvider: GithubCredentialsProvider; }): TemplateAction; // Warning: (ae-missing-release-tag) "createPublishAzureAction" is exported by the package, but it is missing a release tag (@alpha, @beta, @public, or @internal) @@ -160,6 +163,7 @@ export function createPublishFileAction(): TemplateAction; export function createPublishGithubAction(options: { integrations: ScmIntegrationRegistry; config: Config; + githubCredentialsProvider: GithubCredentialsProvider; }): TemplateAction; // Warning: (ae-forgotten-export) The symbol "CreateGithubPullRequestActionOptions" needs to be exported by the entry point index.d.ts @@ -168,6 +172,7 @@ export function createPublishGithubAction(options: { // @public (undocumented) export const createPublishGithubPullRequestAction: ({ integrations, + githubCredentialsProvider, clientFactory, }: CreateGithubPullRequestActionOptions) => TemplateAction; @@ -281,7 +286,10 @@ export function fetchContents({ // // @public export class OctokitProvider { - constructor(integrations: ScmIntegrationRegistry); + constructor( + integrations: ScmIntegrationRegistry, + githubCredentialsProvider: GithubCredentialsProvider, + ); // Warning: (tsdoc-param-tag-missing-hyphen) The @param block should be followed by a parameter name and then a hyphen // Warning: (ae-forgotten-export) The symbol "OctokitIntegration" needs to be exported by the entry point index.d.ts getOctokit(repoUrl: string): Promise;