@gitkraken/provider-apis 0.14.1 → 0.14.2
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 +16 -0
- package/dist/index.js +191 -123
- package/dist/providerUtils/shared.d.ts +4 -0
- package/dist/providers/azureDevops/azureDevOps.d.ts +24 -0
- package/dist/providers/gitProvider.d.ts +37 -0
- package/dist/providers/github/github.d.ts +19 -1
- package/dist/providers/github/githubHelpers.d.ts +7 -1
- package/dist/providers/github/githubTypes.d.ts +32 -0
- package/dist/providers/issueProvider.d.ts +1 -0
- package/dist/providers/jira/jira.d.ts +4 -37
- package/dist/providers/jira/sharedHelpers.d.ts +46 -0
- package/dist/providers/jira/sharedTypes.d.ts +115 -0
- package/dist/providers/jiraServer/jiraServer.d.ts +16 -3
- package/dist/providers/trello/trello.d.ts +2 -0
- package/package.json +1 -1
|
@@ -35,6 +35,7 @@ export declare class AzureDevOps extends Provider implements GitProvider {
|
|
|
35
35
|
username: string;
|
|
36
36
|
email: string;
|
|
37
37
|
avatarUrl: null;
|
|
38
|
+
url: null;
|
|
38
39
|
};
|
|
39
40
|
}>;
|
|
40
41
|
getCurrentUserForInstance(input: {
|
|
@@ -146,6 +147,29 @@ export declare class AzureDevOps extends Provider implements GitProvider {
|
|
|
146
147
|
}, options?: EnterpriseOptions): Promise<{
|
|
147
148
|
data: GitPullRequest[];
|
|
148
149
|
}>;
|
|
150
|
+
private getPullRequestsForProjectBase;
|
|
151
|
+
getPullRequestsForProject(input: {
|
|
152
|
+
namespace: string;
|
|
153
|
+
project: string;
|
|
154
|
+
assigneeLogins?: string[];
|
|
155
|
+
authorLogin?: string;
|
|
156
|
+
} & NumberedPageInput, options?: EnterpriseOptions): Promise<{
|
|
157
|
+
pageInfo: {
|
|
158
|
+
hasNextPage: boolean;
|
|
159
|
+
nextPage: number;
|
|
160
|
+
};
|
|
161
|
+
data: GitPullRequest[];
|
|
162
|
+
}>;
|
|
163
|
+
getPullRequestsForProjects(input: {
|
|
164
|
+
projects: {
|
|
165
|
+
namespace: string;
|
|
166
|
+
project: string;
|
|
167
|
+
}[];
|
|
168
|
+
assigneeLogins?: string[];
|
|
169
|
+
authorLogin?: string;
|
|
170
|
+
}, options?: EnterpriseOptions): Promise<{
|
|
171
|
+
data: GitPullRequest[];
|
|
172
|
+
}>;
|
|
149
173
|
getAzurePullRequestLastMergeStatus(input: {
|
|
150
174
|
repo: GetRepoInput;
|
|
151
175
|
pullRequestId: string;
|
|
@@ -15,6 +15,7 @@ export interface Account extends User {
|
|
|
15
15
|
id: string;
|
|
16
16
|
graphQLId?: string;
|
|
17
17
|
username: string | null;
|
|
18
|
+
url: string | null;
|
|
18
19
|
}
|
|
19
20
|
export interface Organization {
|
|
20
21
|
id: string;
|
|
@@ -159,6 +160,7 @@ export interface GitPullRequest {
|
|
|
159
160
|
createdDate: Date;
|
|
160
161
|
updatedDate: Date;
|
|
161
162
|
closedDate: Date | null;
|
|
163
|
+
mergedDate: Date | null;
|
|
162
164
|
baseRef: GitRefWithOID | null;
|
|
163
165
|
headRef: GitRefWithOID | null;
|
|
164
166
|
commentCount: number | null;
|
|
@@ -173,11 +175,17 @@ export interface GitPullRequest {
|
|
|
173
175
|
reviewer: Account;
|
|
174
176
|
state: GitPullRequestReviewState;
|
|
175
177
|
}[] | null;
|
|
178
|
+
reviewDecision: GitPullRequestReviewState | null;
|
|
176
179
|
repository: {
|
|
177
180
|
name: string;
|
|
181
|
+
project?: string;
|
|
178
182
|
owner: {
|
|
179
183
|
login?: string;
|
|
180
184
|
};
|
|
185
|
+
remoteInfo: {
|
|
186
|
+
cloneUrlHTTPS: string;
|
|
187
|
+
cloneUrlSSH: string;
|
|
188
|
+
} | null;
|
|
181
189
|
};
|
|
182
190
|
headRepository: {
|
|
183
191
|
name: string;
|
|
@@ -196,6 +204,35 @@ export interface GitPullRequest {
|
|
|
196
204
|
milestone?: GitMilestone | null;
|
|
197
205
|
labels?: GitLabel[];
|
|
198
206
|
}
|
|
207
|
+
export interface GitComment {
|
|
208
|
+
author: Account | User | null;
|
|
209
|
+
body: string;
|
|
210
|
+
createdAt: Date | null;
|
|
211
|
+
id: string;
|
|
212
|
+
graphQLId?: string;
|
|
213
|
+
url: string;
|
|
214
|
+
}
|
|
215
|
+
export declare enum GitDiffLineType {
|
|
216
|
+
ADDED = "ADDED",
|
|
217
|
+
DELETED = "DELETED",
|
|
218
|
+
UNMODIFIED = "UNMODIFIED"
|
|
219
|
+
}
|
|
220
|
+
export interface GitDiffLine {
|
|
221
|
+
line: string;
|
|
222
|
+
oldLineNumber: number | null;
|
|
223
|
+
newLineNumber: number | null;
|
|
224
|
+
type: GitDiffLineType;
|
|
225
|
+
}
|
|
226
|
+
export interface GitPullRequestReviewComment extends GitComment {
|
|
227
|
+
diffLines: GitDiffLine[];
|
|
228
|
+
filename: string;
|
|
229
|
+
replies: GitComment[];
|
|
230
|
+
isOutdated: boolean;
|
|
231
|
+
isResolved: boolean;
|
|
232
|
+
}
|
|
233
|
+
export interface GitPullRequestReview extends GitComment {
|
|
234
|
+
reviewComments: GitPullRequestReviewComment[];
|
|
235
|
+
}
|
|
199
236
|
export interface GetRepoInput {
|
|
200
237
|
namespace: string;
|
|
201
238
|
name: string;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Account, CursorPageInput, EnterpriseOptions, GetRepoErrorData, GetRepoInput, GitLabel, GitMergeStrategy, GitMilestone, GitProvider, GitPullRequest, GitRepository, Organization } from '../gitProvider';
|
|
1
|
+
import { Account, CursorPageInput, EnterpriseOptions, GetRepoErrorData, GetRepoInput, GitLabel, GitMergeStrategy, GitMilestone, GitProvider, GitPullRequest, GitPullRequestReviewComment, GitRepository, Organization } from '../gitProvider';
|
|
2
2
|
import { Issue } from '../issueProvider';
|
|
3
3
|
import { EnterpriseProvider } from '../provider';
|
|
4
4
|
import { FetchIssuesData, FetchPullRequestsData } from './githubTypes';
|
|
@@ -212,6 +212,24 @@ export declare class GitHub extends EnterpriseProvider implements GitProvider {
|
|
|
212
212
|
pullRequestGraphQLId: string;
|
|
213
213
|
assigneeGraphQLIds: string[];
|
|
214
214
|
}, options?: EnterpriseOptions): Promise<void>;
|
|
215
|
+
getReviewsForPullRequest(input: {
|
|
216
|
+
repo: GetRepoInput;
|
|
217
|
+
pullRequestId: number;
|
|
218
|
+
}, options?: EnterpriseOptions): Promise<{
|
|
219
|
+
data: {
|
|
220
|
+
author: {
|
|
221
|
+
avatarUrl: string;
|
|
222
|
+
email: null;
|
|
223
|
+
name: string;
|
|
224
|
+
} | null;
|
|
225
|
+
body: string;
|
|
226
|
+
createdAt: Date | null;
|
|
227
|
+
id: string;
|
|
228
|
+
graphQLId: string;
|
|
229
|
+
reviewComments: GitPullRequestReviewComment[];
|
|
230
|
+
url: string;
|
|
231
|
+
}[];
|
|
232
|
+
}>;
|
|
215
233
|
/**
|
|
216
234
|
* Returns issues that were created by or are assigned to the user.
|
|
217
235
|
*/
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { GraphQLBody, GraphQLError, GraphQLResponse, ProviderConfig } from '../../types';
|
|
2
|
-
import { EnterpriseOptions } from '../gitProvider';
|
|
2
|
+
import { EnterpriseOptions, GitDiffLineType } from '../gitProvider';
|
|
3
3
|
export declare const GITHUB_API_URL = "https://api.github.com";
|
|
4
4
|
export declare const GITHUB_GRAPHQL_API_URL: string;
|
|
5
5
|
export declare const GRAPHQL_MILESTONE_FIELDS = "\ndescription\ndueOn\nid\nnumber\nstate\ntitle\nurl\n";
|
|
@@ -15,3 +15,9 @@ export declare const GithubSearchSyntaxQualifiers: Record<string, string>;
|
|
|
15
15
|
export declare const getProjectGithubSearchSyntax: (search: string) => string[];
|
|
16
16
|
export declare const makeSearchIssuesOrPRsGraphQLBody: (type: 'issue' | 'pr', query: string, cursor: string | null | undefined, supportsEmail: boolean, supportsDrafts?: boolean) => GraphQLBody;
|
|
17
17
|
export declare const hasDraftsNotSupportedError: (errors?: GraphQLError[]) => boolean;
|
|
18
|
+
export declare const getDiffLinesFromDiffHunk: (diffHunk: string, originalLine: number | null, originalStartLine: number | null, startDiffSide: 'LEFT' | 'RIGHT' | null) => {
|
|
19
|
+
line: string;
|
|
20
|
+
oldLineNumber: number | null;
|
|
21
|
+
newLineNumber: number | null;
|
|
22
|
+
type: GitDiffLineType;
|
|
23
|
+
}[];
|
|
@@ -49,6 +49,7 @@ export interface GraphQLUser {
|
|
|
49
49
|
login: string;
|
|
50
50
|
email?: string;
|
|
51
51
|
avatarUrl: string;
|
|
52
|
+
url: string;
|
|
52
53
|
}
|
|
53
54
|
export interface GraphQLBot {
|
|
54
55
|
__typename: 'Bot';
|
|
@@ -56,6 +57,7 @@ export interface GraphQLBot {
|
|
|
56
57
|
databaseId: number;
|
|
57
58
|
login: string;
|
|
58
59
|
avatarUrl: string;
|
|
60
|
+
url: string;
|
|
59
61
|
}
|
|
60
62
|
export interface GraphQLOrganization {
|
|
61
63
|
id: string;
|
|
@@ -91,6 +93,7 @@ export interface GraphQLPullRequest {
|
|
|
91
93
|
};
|
|
92
94
|
createdAt: string;
|
|
93
95
|
closedAt: string | null;
|
|
96
|
+
mergedAt: string | null;
|
|
94
97
|
isDraft: boolean;
|
|
95
98
|
changedFiles: number;
|
|
96
99
|
additions: number;
|
|
@@ -138,6 +141,8 @@ export interface GraphQLPullRequest {
|
|
|
138
141
|
owner: {
|
|
139
142
|
login: string;
|
|
140
143
|
};
|
|
144
|
+
sshUrl: string;
|
|
145
|
+
url: string;
|
|
141
146
|
};
|
|
142
147
|
reviewRequests: {
|
|
143
148
|
nodes: {
|
|
@@ -176,6 +181,7 @@ export interface GraphQLIssue {
|
|
|
176
181
|
nodes: GraphQLUser[] | null;
|
|
177
182
|
};
|
|
178
183
|
author: GraphQLUser | GraphQLBot | Record<string, never> | null;
|
|
184
|
+
closedAt: string | null;
|
|
179
185
|
createdAt: string;
|
|
180
186
|
updatedAt: string;
|
|
181
187
|
comments: {
|
|
@@ -216,3 +222,29 @@ export interface FetchIssuesData {
|
|
|
216
222
|
mentionLogin?: string;
|
|
217
223
|
startQuery?: string;
|
|
218
224
|
}
|
|
225
|
+
export interface GraphQLReviewThread {
|
|
226
|
+
comments: {
|
|
227
|
+
nodes: GraphQLReviewComment[];
|
|
228
|
+
};
|
|
229
|
+
isOutdated: boolean;
|
|
230
|
+
isResolved: boolean;
|
|
231
|
+
originalLine: number | null;
|
|
232
|
+
originalStartLine: number | null;
|
|
233
|
+
startDiffSide: 'LEFT' | 'RIGHT' | null;
|
|
234
|
+
}
|
|
235
|
+
export interface GraphQLReviewComment {
|
|
236
|
+
author: {
|
|
237
|
+
avatarUrl: string;
|
|
238
|
+
login: string;
|
|
239
|
+
} | null;
|
|
240
|
+
body: string;
|
|
241
|
+
databaseId: string;
|
|
242
|
+
diffHunk: string;
|
|
243
|
+
id: string;
|
|
244
|
+
path: string;
|
|
245
|
+
publishedAt: string | null;
|
|
246
|
+
pullRequestReview: {
|
|
247
|
+
id: string;
|
|
248
|
+
} | null;
|
|
249
|
+
url: string;
|
|
250
|
+
}
|
|
@@ -1,40 +1,6 @@
|
|
|
1
1
|
import { Result } from '../../types';
|
|
2
2
|
import { CursorPageInput, EnterpriseOptions } from '../gitProvider';
|
|
3
|
-
import { Issue } from '../issueProvider';
|
|
4
3
|
import { Provider } from '../provider';
|
|
5
|
-
interface AvatarUrls {
|
|
6
|
-
'16x16': string;
|
|
7
|
-
'24x24': string;
|
|
8
|
-
'32x32': string;
|
|
9
|
-
'48x48': string;
|
|
10
|
-
}
|
|
11
|
-
interface JiraUser {
|
|
12
|
-
accountId: string;
|
|
13
|
-
accountType: string;
|
|
14
|
-
active: boolean;
|
|
15
|
-
avatarUrls: AvatarUrls;
|
|
16
|
-
displayName: string;
|
|
17
|
-
emailAddress: string;
|
|
18
|
-
self: string;
|
|
19
|
-
timeZone: string;
|
|
20
|
-
}
|
|
21
|
-
interface JiraComponent {
|
|
22
|
-
ari?: string;
|
|
23
|
-
assignee?: JiraUser;
|
|
24
|
-
assigneeType: string;
|
|
25
|
-
description?: string;
|
|
26
|
-
id: string;
|
|
27
|
-
isAssigneeTypeValid: boolean;
|
|
28
|
-
lead?: JiraUser;
|
|
29
|
-
leadUserName?: string;
|
|
30
|
-
metadata?: unknown;
|
|
31
|
-
name: string;
|
|
32
|
-
project: string;
|
|
33
|
-
projectId: string;
|
|
34
|
-
realAssignee?: JiraUser;
|
|
35
|
-
realAssigneeType: string;
|
|
36
|
-
self: string;
|
|
37
|
-
}
|
|
38
4
|
export interface JiraResource {
|
|
39
5
|
id: string;
|
|
40
6
|
name: string;
|
|
@@ -59,6 +25,7 @@ export declare class Jira extends Provider {
|
|
|
59
25
|
avatarUrl: string;
|
|
60
26
|
id: string;
|
|
61
27
|
username: string;
|
|
28
|
+
url: string | null;
|
|
62
29
|
};
|
|
63
30
|
}>;
|
|
64
31
|
getJiraResourcesForCurrentUser(options?: EnterpriseOptions): Promise<Result<JiraResource[]>>;
|
|
@@ -93,13 +60,14 @@ export declare class Jira extends Provider {
|
|
|
93
60
|
email: string;
|
|
94
61
|
avatarUrl: string;
|
|
95
62
|
username: string;
|
|
63
|
+
url: string;
|
|
96
64
|
}[];
|
|
97
65
|
}>;
|
|
98
66
|
getComponentsForJiraProject(input: {
|
|
99
67
|
resourceId: string;
|
|
100
68
|
projectIdOrKey: string;
|
|
101
69
|
}, options?: EnterpriseOptions): Promise<{
|
|
102
|
-
data: JiraComponent[];
|
|
70
|
+
data: import("./sharedTypes").JiraComponent[];
|
|
103
71
|
}>;
|
|
104
72
|
getIssuesForProject(input: {
|
|
105
73
|
project: string;
|
|
@@ -108,7 +76,7 @@ export declare class Jira extends Provider {
|
|
|
108
76
|
authorLogin?: string;
|
|
109
77
|
mentionLogin?: string;
|
|
110
78
|
}, options?: EnterpriseOptions): Promise<{
|
|
111
|
-
data: Issue[];
|
|
79
|
+
data: import("../issueProvider").Issue[];
|
|
112
80
|
}>;
|
|
113
81
|
setIssueStatus(input: {
|
|
114
82
|
resourceId: string;
|
|
@@ -145,4 +113,3 @@ export declare class Jira extends Provider {
|
|
|
145
113
|
}[];
|
|
146
114
|
}>;
|
|
147
115
|
}
|
|
148
|
-
export {};
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
import { ProviderConfig } from '../../types';
|
|
2
|
+
import { EnterpriseOptions } from '../gitProvider';
|
|
3
|
+
import { Issue, IssueComponent, IssueTransition } from '../issueProvider';
|
|
4
|
+
import { JiraComponent, JiraComponentStub, JiraIssue, JiraTransition, JiraUser } from './sharedTypes';
|
|
5
|
+
export declare const normalizeIssue: (issue: JiraIssue, resourceUrl: string | null, isServer: boolean) => Issue;
|
|
6
|
+
export declare const normalizeTransition: (transition: JiraTransition) => IssueTransition;
|
|
7
|
+
export declare const normalizeComponentStub: (component: JiraComponentStub) => IssueComponent;
|
|
8
|
+
export declare const normalizeUserURL: (user: JiraUser, resourceUrl: string | null, isServer: boolean) => string;
|
|
9
|
+
export declare const normalizeUser: (user: JiraUser, resourceUrl: string | null, isServer: boolean) => {
|
|
10
|
+
id: string;
|
|
11
|
+
name: string;
|
|
12
|
+
email: string;
|
|
13
|
+
avatarUrl: string;
|
|
14
|
+
username: string;
|
|
15
|
+
url: string;
|
|
16
|
+
};
|
|
17
|
+
export declare const getIssuesForProject: (config: ProviderConfig, input: {
|
|
18
|
+
resourceId?: string;
|
|
19
|
+
project: string;
|
|
20
|
+
assigneeLogins?: string[];
|
|
21
|
+
authorLogin?: string;
|
|
22
|
+
mentionLogin?: string;
|
|
23
|
+
}, resourceUrl: string | null, options?: EnterpriseOptions) => Promise<{
|
|
24
|
+
data: Issue[];
|
|
25
|
+
}>;
|
|
26
|
+
export declare const setIssueLabels: (config: ProviderConfig, input: {
|
|
27
|
+
resourceId?: string;
|
|
28
|
+
issueId: string;
|
|
29
|
+
labelNames: string[];
|
|
30
|
+
}, options?: EnterpriseOptions) => Promise<void>;
|
|
31
|
+
export declare const setIssueComponents: (config: ProviderConfig, input: {
|
|
32
|
+
resourceId?: string;
|
|
33
|
+
issueId: string;
|
|
34
|
+
componentIds: string[];
|
|
35
|
+
}, options?: EnterpriseOptions) => Promise<void>;
|
|
36
|
+
export declare const setIssueStatus: (config: ProviderConfig, input: {
|
|
37
|
+
resourceId?: string;
|
|
38
|
+
issueId: string;
|
|
39
|
+
status: string;
|
|
40
|
+
}, options?: EnterpriseOptions) => Promise<void>;
|
|
41
|
+
export declare const getComponentsForJiraProject: (config: ProviderConfig, input: {
|
|
42
|
+
resourceId?: string;
|
|
43
|
+
projectIdOrKey: string;
|
|
44
|
+
}, options?: EnterpriseOptions) => Promise<{
|
|
45
|
+
data: JiraComponent[];
|
|
46
|
+
}>;
|
|
@@ -0,0 +1,115 @@
|
|
|
1
|
+
export interface AvatarUrls {
|
|
2
|
+
'16x16': string;
|
|
3
|
+
'24x24': string;
|
|
4
|
+
'32x32': string;
|
|
5
|
+
'48x48': string;
|
|
6
|
+
}
|
|
7
|
+
export interface JiraUser {
|
|
8
|
+
accountId?: string;
|
|
9
|
+
accountType: string;
|
|
10
|
+
active: boolean;
|
|
11
|
+
avatarUrls: AvatarUrls;
|
|
12
|
+
displayName: string;
|
|
13
|
+
emailAddress: string;
|
|
14
|
+
key?: string;
|
|
15
|
+
self: string;
|
|
16
|
+
timeZone: string;
|
|
17
|
+
name?: string;
|
|
18
|
+
}
|
|
19
|
+
export interface JiraTransition {
|
|
20
|
+
id: string;
|
|
21
|
+
name: string;
|
|
22
|
+
to: {
|
|
23
|
+
self: string;
|
|
24
|
+
description: string;
|
|
25
|
+
iconUrl: string;
|
|
26
|
+
name: string;
|
|
27
|
+
id: string;
|
|
28
|
+
statusCategory: {
|
|
29
|
+
self: string;
|
|
30
|
+
id: number;
|
|
31
|
+
key: string;
|
|
32
|
+
colorName: string;
|
|
33
|
+
name: string;
|
|
34
|
+
};
|
|
35
|
+
};
|
|
36
|
+
hasScreen: boolean;
|
|
37
|
+
isGlobal: boolean;
|
|
38
|
+
isInitial: boolean;
|
|
39
|
+
isAvailable: boolean;
|
|
40
|
+
isConditional: boolean;
|
|
41
|
+
isLooped: boolean;
|
|
42
|
+
}
|
|
43
|
+
export interface JiraComponentStub {
|
|
44
|
+
description?: string;
|
|
45
|
+
id: string;
|
|
46
|
+
name: string;
|
|
47
|
+
self: string;
|
|
48
|
+
}
|
|
49
|
+
export interface JiraComponent {
|
|
50
|
+
ari?: string;
|
|
51
|
+
assignee?: JiraUser;
|
|
52
|
+
assigneeType: string;
|
|
53
|
+
description?: string;
|
|
54
|
+
id: string;
|
|
55
|
+
isAssigneeTypeValid: boolean;
|
|
56
|
+
lead?: JiraUser;
|
|
57
|
+
leadUserName?: string;
|
|
58
|
+
metadata?: unknown;
|
|
59
|
+
name: string;
|
|
60
|
+
project: string;
|
|
61
|
+
projectId: string;
|
|
62
|
+
realAssignee?: JiraUser;
|
|
63
|
+
realAssigneeType: string;
|
|
64
|
+
self: string;
|
|
65
|
+
}
|
|
66
|
+
export interface JiraIssueStatus {
|
|
67
|
+
name: string;
|
|
68
|
+
statusCategory: {
|
|
69
|
+
colorName: string;
|
|
70
|
+
id: number;
|
|
71
|
+
key: string;
|
|
72
|
+
name: 'To Do' | 'In Progress' | 'Done';
|
|
73
|
+
self: string;
|
|
74
|
+
};
|
|
75
|
+
}
|
|
76
|
+
export interface JiraIssue {
|
|
77
|
+
expand: string;
|
|
78
|
+
fields: {
|
|
79
|
+
components?: JiraComponentStub[];
|
|
80
|
+
status: JiraIssueStatus;
|
|
81
|
+
assignee?: JiraUser;
|
|
82
|
+
comment: {
|
|
83
|
+
comments: {
|
|
84
|
+
author: JiraUser;
|
|
85
|
+
body: string;
|
|
86
|
+
created: string;
|
|
87
|
+
id: string;
|
|
88
|
+
jsdPublic: boolean;
|
|
89
|
+
self: string;
|
|
90
|
+
updateAuthor: JiraUser;
|
|
91
|
+
}[];
|
|
92
|
+
maxResults: number;
|
|
93
|
+
self: string;
|
|
94
|
+
startAt: number;
|
|
95
|
+
total: number;
|
|
96
|
+
};
|
|
97
|
+
created: string;
|
|
98
|
+
creator: JiraUser;
|
|
99
|
+
issuetype: {
|
|
100
|
+
name: string;
|
|
101
|
+
};
|
|
102
|
+
labels?: string[];
|
|
103
|
+
summary: string;
|
|
104
|
+
updated: string;
|
|
105
|
+
votes: {
|
|
106
|
+
hasVoted: boolean;
|
|
107
|
+
self: string;
|
|
108
|
+
votes: number;
|
|
109
|
+
};
|
|
110
|
+
};
|
|
111
|
+
id: string;
|
|
112
|
+
key: string;
|
|
113
|
+
self: string;
|
|
114
|
+
transitions?: JiraTransition[];
|
|
115
|
+
}
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { EnterpriseOptions } from '../gitProvider';
|
|
2
|
-
import { Issue } from '../issueProvider';
|
|
3
2
|
import { EnterpriseProvider } from '../provider';
|
|
4
3
|
export interface JiraServerProject {
|
|
5
4
|
id: string;
|
|
@@ -13,6 +12,7 @@ export declare class JiraServer extends EnterpriseProvider {
|
|
|
13
12
|
avatarUrl: string;
|
|
14
13
|
id: string;
|
|
15
14
|
username: string;
|
|
15
|
+
url: null;
|
|
16
16
|
};
|
|
17
17
|
}>;
|
|
18
18
|
getJiraProjects(options?: EnterpriseOptions): Promise<{
|
|
@@ -27,13 +27,21 @@ export declare class JiraServer extends EnterpriseProvider {
|
|
|
27
27
|
authorLogin?: string;
|
|
28
28
|
mentionLogin?: string;
|
|
29
29
|
}, options?: EnterpriseOptions): Promise<{
|
|
30
|
-
data: Issue[];
|
|
30
|
+
data: import("../issueProvider").Issue[];
|
|
31
31
|
}>;
|
|
32
32
|
setIssueStatus(input: {
|
|
33
33
|
issueId: string;
|
|
34
34
|
status: string;
|
|
35
35
|
}, options?: EnterpriseOptions): Promise<void>;
|
|
36
|
-
|
|
36
|
+
setIssueLabels(input: {
|
|
37
|
+
issueId: string;
|
|
38
|
+
labelNames: string[];
|
|
39
|
+
}, options?: EnterpriseOptions): Promise<void>;
|
|
40
|
+
setIssueComponents(input: {
|
|
41
|
+
issueId: string;
|
|
42
|
+
componentIds: string[];
|
|
43
|
+
}, options?: EnterpriseOptions): Promise<void>;
|
|
44
|
+
getLabels(options?: EnterpriseOptions): Promise<{
|
|
37
45
|
data: {
|
|
38
46
|
color: null;
|
|
39
47
|
description: null;
|
|
@@ -41,4 +49,9 @@ export declare class JiraServer extends EnterpriseProvider {
|
|
|
41
49
|
name: string;
|
|
42
50
|
}[];
|
|
43
51
|
}>;
|
|
52
|
+
getComponentsForJiraProject(input: {
|
|
53
|
+
projectIdOrKey: string;
|
|
54
|
+
}, options?: EnterpriseOptions): Promise<{
|
|
55
|
+
data: import("../jira/sharedTypes").JiraComponent[];
|
|
56
|
+
}>;
|
|
44
57
|
}
|
|
@@ -34,6 +34,7 @@ export declare class Trello extends Provider {
|
|
|
34
34
|
avatarUrl: string | null;
|
|
35
35
|
id: string;
|
|
36
36
|
username: string;
|
|
37
|
+
url: string;
|
|
37
38
|
};
|
|
38
39
|
}>;
|
|
39
40
|
getBoardsForCurrentUser(input: {
|
|
@@ -55,6 +56,7 @@ export declare class Trello extends Provider {
|
|
|
55
56
|
username: string;
|
|
56
57
|
email: null;
|
|
57
58
|
avatarUrl: null;
|
|
59
|
+
url: null;
|
|
58
60
|
}[];
|
|
59
61
|
}>;
|
|
60
62
|
getIssuesForBoard(input: {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@gitkraken/provider-apis",
|
|
3
|
-
"version": "0.14.
|
|
3
|
+
"version": "0.14.2",
|
|
4
4
|
"description": "An SDK around different third-party APIs that accepts and returns data in a common format.",
|
|
5
5
|
"author": "Axosoft, LLC dba GitKraken",
|
|
6
6
|
"license": "SEE LICENSE IN LICENSE",
|