@gitkraken/provider-apis 0.19.1 → 0.21.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +62 -0
- package/dist/defaults.d.ts +1 -1
- package/dist/fetchWrapper.d.ts +1 -1
- package/dist/index.d.ts +14 -14
- package/dist/index.js +153 -184
- package/dist/providerUtils/azureDevops.d.ts +2 -2
- package/dist/providerUtils/bitbucket.d.ts +2 -2
- package/dist/providerUtils/bitbucketServer.d.ts +2 -2
- package/dist/providerUtils/entityIdentifiers/entityIdentifier.d.ts +5 -0
- package/dist/providerUtils/entityIdentifiers/providerEntityIdentifiers/azureDevopsIssueEntityIdentifier.d.ts +9 -0
- package/dist/providerUtils/entityIdentifiers/providerEntityIdentifiers/azureDevopsPullRequestEntityIdentifier.d.ts +9 -0
- package/dist/providerUtils/entityIdentifiers/providerEntityIdentifiers/bitbucketIssueEntityIdentifier.d.ts +9 -0
- package/dist/providerUtils/entityIdentifiers/providerEntityIdentifiers/bitbucketPullRequestEntityIdentifier.d.ts +9 -0
- package/dist/providerUtils/entityIdentifiers/providerEntityIdentifiers/githubIssueEntityIdentifier.d.ts +9 -0
- package/dist/providerUtils/entityIdentifiers/providerEntityIdentifiers/githubPullRequestEntityIdentifier.d.ts +9 -0
- package/dist/providerUtils/entityIdentifiers/providerEntityIdentifiers/gitlabIssueEntityIdentifier.d.ts +9 -0
- package/dist/providerUtils/entityIdentifiers/providerEntityIdentifiers/gitlabPullRequestEntityIdentifier.d.ts +9 -0
- package/dist/providerUtils/entityIdentifiers/providerEntityIdentifiers/jiraIssueEntityIdentifier.d.ts +9 -0
- package/dist/providerUtils/entityIdentifiers/providerEntityIdentifiers/trelloIssueEntityIdentifier.d.ts +9 -0
- package/dist/providerUtils/gitProvider.d.ts +20 -3
- package/dist/providerUtils/github.d.ts +0 -2
- package/dist/providerUtils/gitlab.d.ts +2 -2
- package/dist/providerUtils/jira.d.ts +2 -2
- package/dist/providerUtils/shared.d.ts +1 -1
- package/dist/providerUtils/trello.d.ts +2 -1
- package/dist/providers/azureDevops/azureDevOps.d.ts +7 -53
- package/dist/providers/azureDevops/azureDevOpsHelpers.d.ts +3 -3
- package/dist/providers/bitbucket/bitbucket.d.ts +4 -11
- package/dist/providers/bitbucket/bitbucketHelpers.d.ts +2 -2
- package/dist/providers/bitbucketServer/bitbucketServer.d.ts +4 -4
- package/dist/providers/gitProvider.d.ts +3 -306
- package/dist/providers/github/github.d.ts +5 -3
- package/dist/providers/github/githubHelpers.d.ts +3 -3
- package/dist/providers/gitlab/gitlab.d.ts +6 -15
- package/dist/providers/gitlab/gitlabHelpers.d.ts +3 -3
- package/dist/providers/issueProvider.d.ts +3 -91
- package/dist/providers/jira/jira.d.ts +9 -24
- package/dist/providers/jira/{sharedHelpers.d.ts → jiraHelpers.d.ts} +5 -4
- package/dist/providers/{jiraServer → jira}/jiraServer.d.ts +8 -11
- package/dist/providers/provider.d.ts +1 -1
- package/dist/providers/trello/trello.d.ts +5 -26
- package/dist/types/exportedTypes/azureDevOps.d.ts +100 -0
- package/dist/types/exportedTypes/bitbucket.d.ts +15 -0
- package/dist/types/exportedTypes/gitProvider.d.ts +301 -0
- package/dist/types/exportedTypes/github.d.ts +23 -0
- package/dist/types/exportedTypes/gitlab.d.ts +7 -0
- package/dist/types/exportedTypes/issueProvider.d.ts +90 -0
- package/dist/types/exportedTypes/jira.d.ts +58 -0
- package/dist/types/exportedTypes/trello.d.ts +22 -0
- package/dist/{types.d.ts → types/exportedTypes/types.d.ts} +81 -3
- package/dist/{providers/azureDevops/azureDevOpsTypes.d.ts → types/internalTypes/azureDevOps.d.ts} +0 -51
- package/dist/{providers/bitbucketServer/bitbucketServerTypes.d.ts → types/internalTypes/bitbucketServer.d.ts} +0 -7
- package/dist/{providers/github/githubTypes.d.ts → types/internalTypes/github.d.ts} +0 -23
- package/dist/{providers/jira/sharedTypes.d.ts → types/internalTypes/jira.d.ts} +1 -38
- package/dist/utils.d.ts +3 -3
- package/package.json +1 -1
- /package/dist/{providers/bitbucket/bitbucketTypes.d.ts → types/internalTypes/bitbucket.d.ts} +0 -0
- /package/dist/{providers/gitlab/gitlabTypes.d.ts → types/internalTypes/gitlab.d.ts} +0 -0
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
/// <reference types="node" />
|
|
2
|
-
import { Account, CreateCommitInput, CursorPageInput, EnterpriseOptions, GetRepoErrorData, GetRepoInput, GitLabel, GitMergeStrategy, GitMilestone,
|
|
3
|
-
import {
|
|
2
|
+
import { Account, CreateCommitInput, CursorPageInput, EnterpriseOptions, GetRepoErrorData, GetRepoInput, GitLabel, GitMergeStrategy, GitMilestone, GitPullRequest, GitPullRequestReviewComment, GitPullRequestReviewState, GitRepository, Organization, SetAccountInput, SetLabelInput, SetMilestoneInput, SetPullRequestInput } from '../../types/exportedTypes/gitProvider';
|
|
3
|
+
import { FetchIssuesData, FetchPullRequestsData, GitHubIssueCloseReason } from '../../types/exportedTypes/github';
|
|
4
|
+
import { Issue, SetIssueInput } from '../../types/exportedTypes/issueProvider';
|
|
5
|
+
import { GitProvider } from '../gitProvider';
|
|
6
|
+
import { IssueProvider } from '../issueProvider';
|
|
4
7
|
import { EnterpriseProvider } from '../provider';
|
|
5
|
-
import { FetchIssuesData, FetchPullRequestsData, GitHubIssueCloseReason } from './githubTypes';
|
|
6
8
|
export declare class GitHub extends EnterpriseProvider implements GitProvider, IssueProvider {
|
|
7
9
|
private _scopesCache;
|
|
8
10
|
private _enterpriseVersionsCache;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
1
|
+
import { Account, EnterpriseOptions, GitDiffLineType } from '../../types/exportedTypes/gitProvider';
|
|
2
|
+
import { FieldMap, GraphQLBody, GraphQLError, GraphQLResponse, ProviderConfig } from '../../types/exportedTypes/types';
|
|
3
3
|
export declare const minimumFeatureVersions: {
|
|
4
4
|
AS_CODE_OWNER: number[];
|
|
5
5
|
CHECK_RUN: number[];
|
|
@@ -14,7 +14,7 @@ export declare const GRAPHQL_MILESTONE_FIELDS = "\ndescription\ndueOn\nid\nnumbe
|
|
|
14
14
|
export declare const GRAPHQL_LABEL_FIELDS = "\ncolor\ndescription\nid\nname\n";
|
|
15
15
|
export declare const getGraphQLEndpoint: (config: ProviderConfig, options: EnterpriseOptions) => string;
|
|
16
16
|
export declare const getRESTBaseUrl: (config: ProviderConfig, options: EnterpriseOptions) => string;
|
|
17
|
-
export declare const makeGitHubGraphQLRequest: <T>(config: ProviderConfig, data: GraphQLBody, options: EnterpriseOptions) => Promise<import("../../types").Response<GraphQLResponse<T>>>;
|
|
17
|
+
export declare const makeGitHubGraphQLRequest: <T>(config: ProviderConfig, data: GraphQLBody, options: EnterpriseOptions) => Promise<import("../../types/exportedTypes/types").Response<GraphQLResponse<T>>>;
|
|
18
18
|
export declare const hasEmailScope: (scopes: string[]) => boolean;
|
|
19
19
|
export declare const getAccountFields: (withAvatarSizeVar?: boolean, includeEmail?: boolean, fields?: FieldMap<Account>) => string;
|
|
20
20
|
export declare const getBotFields: (withAvatarSizeVar?: boolean) => string;
|
|
@@ -1,13 +1,9 @@
|
|
|
1
|
-
import { Account, CursorPageInput, EnterpriseOptions, GetRepoErrorData, GetRepoInput, GitLabel, GitMergeStrategy,
|
|
2
|
-
import {
|
|
1
|
+
import { Account, CursorPageInput, EnterpriseOptions, GetRepoErrorData, GetRepoInput, GetReposInput, GitLabel, GitMergeStrategy, GitPullRequest, GitRepository, NumberedPageInput, SetAccountInput, SetLabelInput, SetMilestoneInput, SetPullRequestInput } from '../../types/exportedTypes/gitProvider';
|
|
2
|
+
import { GitLabGetIssueInput, PullRequestAssociation } from '../../types/exportedTypes/gitlab';
|
|
3
|
+
import { Issue, SetIssueInput } from '../../types/exportedTypes/issueProvider';
|
|
4
|
+
import { GitProvider } from '../gitProvider';
|
|
5
|
+
import { IssueProvider } from '../issueProvider';
|
|
3
6
|
import { EnterpriseProvider } from '../provider';
|
|
4
|
-
export interface GitLabGetIssueInput {
|
|
5
|
-
namespace: string;
|
|
6
|
-
name: string;
|
|
7
|
-
number: string;
|
|
8
|
-
}
|
|
9
|
-
export type PullRequestState = 'opened' | 'merged' | 'closed';
|
|
10
|
-
export type PullRequestAssociation = 'assigned' | 'authored' | 'reviewRequested';
|
|
11
7
|
export declare class GitLab extends EnterpriseProvider implements GitProvider, IssueProvider {
|
|
12
8
|
private getIsSelfHosted;
|
|
13
9
|
getCurrentUser(input?: Record<string, never>, options?: EnterpriseOptions): Promise<{
|
|
@@ -159,17 +155,12 @@ export declare class GitLab extends EnterpriseProvider implements GitProvider, I
|
|
|
159
155
|
data: GitPullRequest[];
|
|
160
156
|
}>;
|
|
161
157
|
getPullRequestsForRepos(input: {
|
|
162
|
-
repoIds: (string | number)[];
|
|
163
158
|
assigneeLogins?: string[];
|
|
164
159
|
updatedBefore?: string;
|
|
165
160
|
authorLogin?: string;
|
|
166
161
|
isDraft?: boolean;
|
|
167
162
|
reviewRequestedLogin?: string;
|
|
168
|
-
} & CursorPageInput, options?: EnterpriseOptions): Promise<{
|
|
169
|
-
pageInfo: {
|
|
170
|
-
endCursor: string | null;
|
|
171
|
-
hasNextPage: boolean;
|
|
172
|
-
} | undefined;
|
|
163
|
+
} & GetReposInput & CursorPageInput, options?: EnterpriseOptions): Promise<{
|
|
173
164
|
data: GitPullRequest[];
|
|
174
165
|
}>;
|
|
175
166
|
closePullRequest(input: {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
1
|
+
import { EnterpriseOptions } from '../../types/exportedTypes/gitProvider';
|
|
2
|
+
import { GraphQLBody, GraphQLResponse, ProviderConfig } from '../../types/exportedTypes/types';
|
|
3
3
|
export declare const GITLAB_API_URL = "https://gitlab.com/api/v4";
|
|
4
4
|
export declare const GITLAB_GRAPHQL_API_URL = "https://gitlab.com/api/graphql";
|
|
5
5
|
export declare const getRESTBaseUrl: (config: ProviderConfig, options: EnterpriseOptions) => string;
|
|
6
6
|
export declare const getGraphQLEndpoint: (config: ProviderConfig, options: EnterpriseOptions) => string;
|
|
7
|
-
export declare const makeGitLabGraphQLRequest: <T>(config: ProviderConfig, data: GraphQLBody, options: EnterpriseOptions) => Promise<import("../../types").Response<GraphQLResponse<T>>>;
|
|
7
|
+
export declare const makeGitLabGraphQLRequest: <T>(config: ProviderConfig, data: GraphQLBody, options: EnterpriseOptions) => Promise<import("../../types/exportedTypes/types").Response<GraphQLResponse<T>>>;
|
|
@@ -1,94 +1,6 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
|
|
4
|
-
Open = "OPEN",
|
|
5
|
-
Closed = "CLOSED"
|
|
6
|
-
}
|
|
7
|
-
export interface GetIssueInput {
|
|
8
|
-
resourceId?: string;
|
|
9
|
-
namespace?: string;
|
|
10
|
-
project?: string;
|
|
11
|
-
name?: string;
|
|
12
|
-
number: string;
|
|
13
|
-
}
|
|
14
|
-
export type GetIssuesForReposInput = GetReposInput | {
|
|
15
|
-
repoIds: (string | number)[];
|
|
16
|
-
};
|
|
17
|
-
export interface IssueTransition {
|
|
18
|
-
id: string;
|
|
19
|
-
name: string;
|
|
20
|
-
to: {
|
|
21
|
-
id: string;
|
|
22
|
-
name: string;
|
|
23
|
-
color: string;
|
|
24
|
-
category: IssueStatusCategory;
|
|
25
|
-
};
|
|
26
|
-
}
|
|
27
|
-
export interface IssueComponent {
|
|
28
|
-
description: string | null;
|
|
29
|
-
id: string;
|
|
30
|
-
name: string;
|
|
31
|
-
}
|
|
32
|
-
export type IssueStatusCategory = 'TO_DO' | 'IN_PROGRESS' | 'DONE';
|
|
33
|
-
export interface Issue {
|
|
34
|
-
author: Account | null;
|
|
35
|
-
assignees: Account[];
|
|
36
|
-
commentCount: number | null;
|
|
37
|
-
closedDate: Date | null;
|
|
38
|
-
createdDate: Date;
|
|
39
|
-
description: string | null;
|
|
40
|
-
graphQLId?: string;
|
|
41
|
-
id: string;
|
|
42
|
-
labels: GitLabel[];
|
|
43
|
-
number: string;
|
|
44
|
-
repository: {
|
|
45
|
-
id: string;
|
|
46
|
-
graphQLId?: string;
|
|
47
|
-
name: string;
|
|
48
|
-
owner: {
|
|
49
|
-
login?: string;
|
|
50
|
-
};
|
|
51
|
-
} | null;
|
|
52
|
-
project?: {
|
|
53
|
-
namespace: string | null;
|
|
54
|
-
resourceId: string | null;
|
|
55
|
-
name: string;
|
|
56
|
-
};
|
|
57
|
-
state: {
|
|
58
|
-
id?: string;
|
|
59
|
-
name: string;
|
|
60
|
-
color: string | null;
|
|
61
|
-
category?: IssueStatusCategory;
|
|
62
|
-
} | null;
|
|
63
|
-
statusTransitions?: IssueTransition[];
|
|
64
|
-
components?: IssueComponent[];
|
|
65
|
-
title: string;
|
|
66
|
-
type: string | null;
|
|
67
|
-
updatedDate: Date | null;
|
|
68
|
-
upvoteCount: number | null;
|
|
69
|
-
url: string | null;
|
|
70
|
-
milestone?: GitMilestone | null;
|
|
71
|
-
}
|
|
72
|
-
export interface SetIssueInput {
|
|
73
|
-
id: string;
|
|
74
|
-
graphQLId?: string;
|
|
75
|
-
number: string;
|
|
76
|
-
repository: {
|
|
77
|
-
name: string;
|
|
78
|
-
owner: {
|
|
79
|
-
login?: string;
|
|
80
|
-
};
|
|
81
|
-
} | null;
|
|
82
|
-
project?: {
|
|
83
|
-
namespace: string | null;
|
|
84
|
-
resourceId: string | null;
|
|
85
|
-
name: string;
|
|
86
|
-
};
|
|
87
|
-
}
|
|
88
|
-
export interface SetStatusInput {
|
|
89
|
-
name: string;
|
|
90
|
-
id?: string;
|
|
91
|
-
}
|
|
1
|
+
import { GetRepoInput, Options, SetAccountInput, SetLabelInput, SetMilestoneInput } from '../types/exportedTypes/gitProvider';
|
|
2
|
+
import { GetIssueInput, GetIssuesForReposInput, Issue, SetIssueInput, SetStatusInput } from '../types/exportedTypes/issueProvider';
|
|
3
|
+
import { PagedResult, Result } from '../types/exportedTypes/types';
|
|
92
4
|
export interface IssueProvider {
|
|
93
5
|
getIssue?(input: GetIssueInput, options: Options): Promise<Result<Issue>>;
|
|
94
6
|
getIssuesForRepo?(input: {
|
|
@@ -1,24 +1,9 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
1
|
+
import { CursorPageInput, EnterpriseOptions, NumberedPageInput, SetAccountInput, SetLabelInput } from '../../types/exportedTypes/gitProvider';
|
|
2
|
+
import { SetIssueInput, SetStatusInput } from '../../types/exportedTypes/issueProvider';
|
|
3
|
+
import { JiraGetIssueInput, JiraProject, JiraResource, SetComponentInput } from '../../types/exportedTypes/jira';
|
|
4
|
+
import { Result } from '../../types/exportedTypes/types';
|
|
5
|
+
import { IssueProvider } from '../issueProvider';
|
|
4
6
|
import { Provider } from '../provider';
|
|
5
|
-
import { SetComponentInput } from './sharedTypes';
|
|
6
|
-
export interface JiraResource {
|
|
7
|
-
id: string;
|
|
8
|
-
name: string;
|
|
9
|
-
url: string;
|
|
10
|
-
avatarUrl: string;
|
|
11
|
-
}
|
|
12
|
-
export interface JiraProject {
|
|
13
|
-
id: string;
|
|
14
|
-
key: string;
|
|
15
|
-
name: string;
|
|
16
|
-
resourceId: string;
|
|
17
|
-
}
|
|
18
|
-
export interface JiraGetIssueInput {
|
|
19
|
-
resourceId: string;
|
|
20
|
-
number: string;
|
|
21
|
-
}
|
|
22
7
|
export declare class Jira extends Provider implements IssueProvider {
|
|
23
8
|
private _resourceUrlCache;
|
|
24
9
|
private getResourceUrl;
|
|
@@ -73,10 +58,10 @@ export declare class Jira extends Provider implements IssueProvider {
|
|
|
73
58
|
resourceId: string;
|
|
74
59
|
projectIdOrKey: string;
|
|
75
60
|
}, options?: EnterpriseOptions): Promise<{
|
|
76
|
-
data: import("
|
|
61
|
+
data: import("../../types/exportedTypes/jira").JiraComponent[];
|
|
77
62
|
}>;
|
|
78
63
|
getIssue(input: JiraGetIssueInput, options?: EnterpriseOptions): Promise<{
|
|
79
|
-
data: import("
|
|
64
|
+
data: import("../../types/exportedTypes/issueProvider").Issue;
|
|
80
65
|
}>;
|
|
81
66
|
getIssuesForProject(input: {
|
|
82
67
|
project: string;
|
|
@@ -85,7 +70,7 @@ export declare class Jira extends Provider implements IssueProvider {
|
|
|
85
70
|
authorLogin?: string;
|
|
86
71
|
mentionLogin?: string;
|
|
87
72
|
} & NumberedPageInput, options?: EnterpriseOptions): Promise<{
|
|
88
|
-
data: import("
|
|
73
|
+
data: import("../../types/exportedTypes/issueProvider").Issue[];
|
|
89
74
|
pageInfo: {
|
|
90
75
|
hasNextPage: boolean;
|
|
91
76
|
nextPage: number | null;
|
|
@@ -94,7 +79,7 @@ export declare class Jira extends Provider implements IssueProvider {
|
|
|
94
79
|
getIssuesForResourceForCurrentUser(input: {
|
|
95
80
|
resourceId: string;
|
|
96
81
|
} & NumberedPageInput, options?: EnterpriseOptions): Promise<{
|
|
97
|
-
data: import("
|
|
82
|
+
data: import("../../types/exportedTypes/issueProvider").Issue[];
|
|
98
83
|
pageInfo: {
|
|
99
84
|
hasNextPage: boolean;
|
|
100
85
|
nextPage: number | null;
|
|
@@ -1,7 +1,8 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
1
|
+
import { EnterpriseOptions, NumberedPageInput, SetLabelInput } from '../../types/exportedTypes/gitProvider';
|
|
2
|
+
import { Issue, IssueComponent, IssueTransition, SetIssueInput, SetStatusInput } from '../../types/exportedTypes/issueProvider';
|
|
3
|
+
import { JiraComponent, JiraUser, SetComponentInput } from '../../types/exportedTypes/jira';
|
|
4
|
+
import { ProviderConfig } from '../../types/exportedTypes/types';
|
|
5
|
+
import { JiraComponentStub, JiraIssue, JiraTransition } from '../../types/internalTypes/jira';
|
|
5
6
|
export declare const normalizeIssue: (issue: JiraIssue, resourceUrl: string | null, resourceId?: string) => Issue;
|
|
6
7
|
export declare const normalizeTransition: (transition: JiraTransition) => IssueTransition;
|
|
7
8
|
export declare const normalizeComponentStub: (component: JiraComponentStub) => IssueComponent;
|
|
@@ -1,11 +1,8 @@
|
|
|
1
|
-
import { EnterpriseOptions, NumberedPageInput, SetLabelInput } from '
|
|
2
|
-
import {
|
|
3
|
-
import { SetComponentInput } from '
|
|
1
|
+
import { EnterpriseOptions, NumberedPageInput, SetLabelInput } from '../../types/exportedTypes/gitProvider';
|
|
2
|
+
import { SetIssueInput, SetStatusInput } from '../../types/exportedTypes/issueProvider';
|
|
3
|
+
import { SetComponentInput } from '../../types/exportedTypes/jira';
|
|
4
|
+
import { IssueProvider } from '../issueProvider';
|
|
4
5
|
import { EnterpriseProvider } from '../provider';
|
|
5
|
-
export interface JiraServerProject {
|
|
6
|
-
id: string;
|
|
7
|
-
name: string;
|
|
8
|
-
}
|
|
9
6
|
export declare class JiraServer extends EnterpriseProvider implements IssueProvider {
|
|
10
7
|
getCurrentUser(options?: EnterpriseOptions): Promise<{
|
|
11
8
|
data: {
|
|
@@ -26,7 +23,7 @@ export declare class JiraServer extends EnterpriseProvider implements IssueProvi
|
|
|
26
23
|
getIssue(input: {
|
|
27
24
|
number: string;
|
|
28
25
|
}, options?: EnterpriseOptions): Promise<{
|
|
29
|
-
data: import("
|
|
26
|
+
data: import("../../types/exportedTypes/issueProvider").Issue;
|
|
30
27
|
}>;
|
|
31
28
|
getIssuesForProject(input: {
|
|
32
29
|
project: string;
|
|
@@ -34,14 +31,14 @@ export declare class JiraServer extends EnterpriseProvider implements IssueProvi
|
|
|
34
31
|
authorLogin?: string;
|
|
35
32
|
mentionLogin?: string;
|
|
36
33
|
} & NumberedPageInput, options?: EnterpriseOptions): Promise<{
|
|
37
|
-
data: import("
|
|
34
|
+
data: import("../../types/exportedTypes/issueProvider").Issue[];
|
|
38
35
|
pageInfo: {
|
|
39
36
|
hasNextPage: boolean;
|
|
40
37
|
nextPage: number | null;
|
|
41
38
|
};
|
|
42
39
|
}>;
|
|
43
40
|
getIssuesForResourceForCurrentUser(input: NumberedPageInput, options?: EnterpriseOptions): Promise<{
|
|
44
|
-
data: import("
|
|
41
|
+
data: import("../../types/exportedTypes/issueProvider").Issue[];
|
|
45
42
|
pageInfo: {
|
|
46
43
|
hasNextPage: boolean;
|
|
47
44
|
nextPage: number | null;
|
|
@@ -70,6 +67,6 @@ export declare class JiraServer extends EnterpriseProvider implements IssueProvi
|
|
|
70
67
|
getComponentsForJiraProject(input: {
|
|
71
68
|
projectIdOrKey: string;
|
|
72
69
|
}, options?: EnterpriseOptions): Promise<{
|
|
73
|
-
data: import("
|
|
70
|
+
data: import("../../types/exportedTypes/jira").JiraComponent[];
|
|
74
71
|
}>;
|
|
75
72
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { EnterpriseProviderConfigInit, ProviderConfig, ProviderConfigInit } from '../types';
|
|
1
|
+
import { EnterpriseProviderConfigInit, ProviderConfig, ProviderConfigInit } from '../types/exportedTypes/types';
|
|
2
2
|
export declare class Provider<Config extends ProviderConfigInit = ProviderConfigInit> {
|
|
3
3
|
protected config: ProviderConfig;
|
|
4
4
|
constructor(config?: Config);
|
|
@@ -1,29 +1,9 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
1
|
+
import { EnterpriseOptions, SetAccountInput, SetLabelInput } from '../../types/exportedTypes/gitProvider';
|
|
2
|
+
import { Issue, SetIssueInput, SetStatusInput } from '../../types/exportedTypes/issueProvider';
|
|
3
|
+
import { TrelloBoard, TrelloList } from '../../types/exportedTypes/trello';
|
|
4
|
+
import { Result } from '../../types/exportedTypes/types';
|
|
5
|
+
import { IssueProvider } from '../issueProvider';
|
|
4
6
|
import { Provider } from '../provider';
|
|
5
|
-
interface TrelloList {
|
|
6
|
-
id: string;
|
|
7
|
-
name: string;
|
|
8
|
-
closed: boolean;
|
|
9
|
-
pos: number;
|
|
10
|
-
softLimit: string;
|
|
11
|
-
idBoard: string;
|
|
12
|
-
subscribed: boolean;
|
|
13
|
-
limits: {
|
|
14
|
-
attachments: {
|
|
15
|
-
perBoard: {
|
|
16
|
-
status: string;
|
|
17
|
-
disableAt: number;
|
|
18
|
-
warnAt: number;
|
|
19
|
-
};
|
|
20
|
-
};
|
|
21
|
-
};
|
|
22
|
-
}
|
|
23
|
-
export interface TrelloBoard {
|
|
24
|
-
id: string;
|
|
25
|
-
name: string;
|
|
26
|
-
}
|
|
27
7
|
export declare class Trello extends Provider implements IssueProvider {
|
|
28
8
|
getCurrentUser(input: {
|
|
29
9
|
appKey: string;
|
|
@@ -107,4 +87,3 @@ export declare class Trello extends Provider implements IssueProvider {
|
|
|
107
87
|
}[];
|
|
108
88
|
}>;
|
|
109
89
|
}
|
|
110
|
-
export {};
|
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
import { GetRepoInput, SetAccountInput, SetPullRequestInput } from './gitProvider';
|
|
2
|
+
import { SetIssueInput } from './issueProvider';
|
|
3
|
+
export interface WorkItemState {
|
|
4
|
+
category: 'Proposed' | 'InProgress' | 'Resolved' | 'Completed' | 'Removed';
|
|
5
|
+
color: string;
|
|
6
|
+
name: string;
|
|
7
|
+
}
|
|
8
|
+
export interface AzureGraphAccount {
|
|
9
|
+
avatarUrl: string | null;
|
|
10
|
+
descriptor: string;
|
|
11
|
+
email: string | null;
|
|
12
|
+
name: string;
|
|
13
|
+
storageKeyURL: string;
|
|
14
|
+
username: string;
|
|
15
|
+
}
|
|
16
|
+
export declare enum PullRequestAsyncStatus {
|
|
17
|
+
Conflicts = "conflicts",
|
|
18
|
+
Failure = "failure",
|
|
19
|
+
NotSet = "notSet",
|
|
20
|
+
Queued = "queued",
|
|
21
|
+
RejectedByPolicy = "rejectedByPolicy",
|
|
22
|
+
Succeeded = "succeeded"
|
|
23
|
+
}
|
|
24
|
+
export interface WorkItemTypeField {
|
|
25
|
+
helpText: string;
|
|
26
|
+
alwaysRequired: boolean;
|
|
27
|
+
referenceName: string;
|
|
28
|
+
name: string;
|
|
29
|
+
url: string;
|
|
30
|
+
}
|
|
31
|
+
export interface WorkItemTypeTransition {
|
|
32
|
+
to: string;
|
|
33
|
+
actions: string[] | null;
|
|
34
|
+
}
|
|
35
|
+
export interface WorkItemType {
|
|
36
|
+
name: string;
|
|
37
|
+
referenceName: string;
|
|
38
|
+
description: string;
|
|
39
|
+
color: string;
|
|
40
|
+
icon: {
|
|
41
|
+
id: string;
|
|
42
|
+
url: string;
|
|
43
|
+
};
|
|
44
|
+
isDisabled: boolean;
|
|
45
|
+
xmlForm: string;
|
|
46
|
+
fields: WorkItemTypeField[];
|
|
47
|
+
fieldInstances: WorkItemTypeField[];
|
|
48
|
+
transitions: {
|
|
49
|
+
[index: string]: WorkItemTypeTransition;
|
|
50
|
+
};
|
|
51
|
+
states: WorkItemState[];
|
|
52
|
+
url: string;
|
|
53
|
+
}
|
|
54
|
+
export interface AzureDevOpsProject {
|
|
55
|
+
namespace: string;
|
|
56
|
+
name: string;
|
|
57
|
+
}
|
|
58
|
+
export interface AzureGetRepoInput extends GetRepoInput {
|
|
59
|
+
project: string;
|
|
60
|
+
}
|
|
61
|
+
export interface AzureGetReposInput {
|
|
62
|
+
namespace: string;
|
|
63
|
+
project: string;
|
|
64
|
+
}
|
|
65
|
+
export interface AzureSetAccountInput extends SetAccountInput {
|
|
66
|
+
name: string;
|
|
67
|
+
}
|
|
68
|
+
export interface AzureSetIssueInput extends SetIssueInput {
|
|
69
|
+
project: {
|
|
70
|
+
namespace: string;
|
|
71
|
+
resourceId: null;
|
|
72
|
+
name: string;
|
|
73
|
+
};
|
|
74
|
+
}
|
|
75
|
+
export interface AzureSetPullRequestInput extends SetPullRequestInput {
|
|
76
|
+
repository: {
|
|
77
|
+
id: string;
|
|
78
|
+
name: string;
|
|
79
|
+
project: string;
|
|
80
|
+
owner: {
|
|
81
|
+
login: string;
|
|
82
|
+
};
|
|
83
|
+
};
|
|
84
|
+
}
|
|
85
|
+
export interface AzureProject {
|
|
86
|
+
id: string;
|
|
87
|
+
name: string;
|
|
88
|
+
namespace: string;
|
|
89
|
+
}
|
|
90
|
+
export interface AzureOrganization {
|
|
91
|
+
id: string;
|
|
92
|
+
name: string;
|
|
93
|
+
}
|
|
94
|
+
export type StatusByWorkItemIdByStatusId = {
|
|
95
|
+
[workItemType: string]: {
|
|
96
|
+
[statusId: string]: {
|
|
97
|
+
title: string;
|
|
98
|
+
};
|
|
99
|
+
};
|
|
100
|
+
};
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
export interface RefreshTokenResponse {
|
|
2
|
+
access_token: string;
|
|
3
|
+
scopes: string;
|
|
4
|
+
token_type: string;
|
|
5
|
+
expires_in: number;
|
|
6
|
+
state: string;
|
|
7
|
+
refresh_token: string;
|
|
8
|
+
}
|
|
9
|
+
export interface BitbucketServerMergeStrategy {
|
|
10
|
+
description: string;
|
|
11
|
+
enabled: boolean;
|
|
12
|
+
flag: string;
|
|
13
|
+
id: string;
|
|
14
|
+
name: string;
|
|
15
|
+
}
|