@structured-world/gitlab-mcp 7.6.0 → 8.0.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/README.md +26 -5
- package/README.md.in +23 -2
- package/dist/src/cli/inject-tool-refs.d.ts +1 -0
- package/dist/src/cli/inject-tool-refs.js +10 -2
- package/dist/src/cli/inject-tool-refs.js.map +1 -1
- package/dist/src/cli/list-tools.js +2 -8
- package/dist/src/cli/list-tools.js.map +1 -1
- package/dist/src/cli/setup/presets.js +1 -1
- package/dist/src/cli/setup/presets.js.map +1 -1
- package/dist/src/entities/access_tokens/registry.d.ts +3 -0
- package/dist/src/entities/access_tokens/registry.js +147 -0
- package/dist/src/entities/access_tokens/registry.js.map +1 -0
- package/dist/src/entities/access_tokens/schema-readonly.d.ts +40 -0
- package/dist/src/entities/access_tokens/schema-readonly.js +60 -0
- package/dist/src/entities/access_tokens/schema-readonly.js.map +1 -0
- package/dist/src/entities/access_tokens/schema.d.ts +28 -0
- package/dist/src/entities/access_tokens/schema.js +68 -0
- package/dist/src/entities/access_tokens/schema.js.map +1 -0
- package/dist/src/entities/audit_events/registry.d.ts +3 -0
- package/dist/src/entities/audit_events/registry.js +93 -0
- package/dist/src/entities/audit_events/registry.js.map +1 -0
- package/dist/src/entities/audit_events/schema-readonly.d.ts +33 -0
- package/dist/src/entities/audit_events/schema-readonly.js +78 -0
- package/dist/src/entities/audit_events/schema-readonly.js.map +1 -0
- package/dist/src/entities/container_registry/registry.d.ts +3 -0
- package/dist/src/entities/container_registry/registry.js +255 -0
- package/dist/src/entities/container_registry/registry.js.map +1 -0
- package/dist/src/entities/container_registry/schema-readonly.d.ts +22 -0
- package/dist/src/entities/container_registry/schema-readonly.js +62 -0
- package/dist/src/entities/container_registry/schema-readonly.js.map +1 -0
- package/dist/src/entities/container_registry/schema.d.ts +17 -0
- package/dist/src/entities/container_registry/schema.js +66 -0
- package/dist/src/entities/container_registry/schema.js.map +1 -0
- package/dist/src/entities/context/whoami.js +2 -1
- package/dist/src/entities/context/whoami.js.map +1 -1
- package/dist/src/entities/core/registry.js +64 -17
- package/dist/src/entities/core/registry.js.map +1 -1
- package/dist/src/entities/core/schema-readonly.d.ts +2 -0
- package/dist/src/entities/core/schema-readonly.js +12 -0
- package/dist/src/entities/core/schema-readonly.js.map +1 -1
- package/dist/src/entities/core/schema.d.ts +3 -0
- package/dist/src/entities/core/schema.js +8 -0
- package/dist/src/entities/core/schema.js.map +1 -1
- package/dist/src/entities/pipelines/registry.js +5 -23
- package/dist/src/entities/pipelines/registry.js.map +1 -1
- package/dist/src/entities/pipelines/schema.d.ts +4 -6
- package/dist/src/entities/pipelines/schema.js +9 -11
- package/dist/src/entities/pipelines/schema.js.map +1 -1
- package/dist/src/entities/runners/registry.d.ts +3 -0
- package/dist/src/entities/runners/registry.js +226 -0
- package/dist/src/entities/runners/registry.js.map +1 -0
- package/dist/src/entities/runners/schema-readonly.d.ts +99 -0
- package/dist/src/entities/runners/schema-readonly.js +99 -0
- package/dist/src/entities/runners/schema-readonly.js.map +1 -0
- package/dist/src/entities/runners/schema.d.ts +49 -0
- package/dist/src/entities/runners/schema.js +81 -0
- package/dist/src/entities/runners/schema.js.map +1 -0
- package/dist/src/entities/vulnerabilities/registry.d.ts +3 -0
- package/dist/src/entities/vulnerabilities/registry.js +171 -0
- package/dist/src/entities/vulnerabilities/registry.js.map +1 -0
- package/dist/src/entities/vulnerabilities/schema-readonly.d.ts +48 -0
- package/dist/src/entities/vulnerabilities/schema-readonly.js +77 -0
- package/dist/src/entities/vulnerabilities/schema-readonly.js.map +1 -0
- package/dist/src/entities/vulnerabilities/schema.d.ts +23 -0
- package/dist/src/entities/vulnerabilities/schema.js +43 -0
- package/dist/src/entities/vulnerabilities/schema.js.map +1 -0
- package/dist/src/entities/workitems/registry.js +11 -10
- package/dist/src/entities/workitems/registry.js.map +1 -1
- package/dist/src/graphql/containerRegistry.d.ts +91 -0
- package/dist/src/graphql/containerRegistry.js +93 -0
- package/dist/src/graphql/containerRegistry.js.map +1 -0
- package/dist/src/graphql/runners.d.ts +162 -0
- package/dist/src/graphql/runners.js +144 -0
- package/dist/src/graphql/runners.js.map +1 -0
- package/dist/src/graphql/vulnerabilities.d.ts +90 -0
- package/dist/src/graphql/vulnerabilities.js +105 -0
- package/dist/src/graphql/vulnerabilities.js.map +1 -0
- package/dist/src/registry-manager.js +55 -0
- package/dist/src/registry-manager.js.map +1 -1
- package/dist/src/services/TokenScopeDetector.js +9 -1
- package/dist/src/services/TokenScopeDetector.js.map +1 -1
- package/dist/tsconfig.build.tsbuildinfo +1 -1
- package/package.json +72 -16
|
@@ -0,0 +1,91 @@
|
|
|
1
|
+
import { TypedDocumentNode } from '@graphql-typed-document-node/core';
|
|
2
|
+
export interface ContainerRepositoryNode {
|
|
3
|
+
id: string;
|
|
4
|
+
name: string | null;
|
|
5
|
+
path: string;
|
|
6
|
+
location: string;
|
|
7
|
+
status: string | null;
|
|
8
|
+
tagsCount: number;
|
|
9
|
+
createdAt: string;
|
|
10
|
+
updatedAt: string;
|
|
11
|
+
lastPublishedAt?: string | null;
|
|
12
|
+
}
|
|
13
|
+
export interface ContainerTagNode {
|
|
14
|
+
name: string;
|
|
15
|
+
path: string;
|
|
16
|
+
location: string;
|
|
17
|
+
digest: string | null;
|
|
18
|
+
revision: string | null;
|
|
19
|
+
shortRevision: string | null;
|
|
20
|
+
totalSize: string | null;
|
|
21
|
+
createdAt: string | null;
|
|
22
|
+
publishedAt: string | null;
|
|
23
|
+
mediaType: string | null;
|
|
24
|
+
}
|
|
25
|
+
interface PageInfo {
|
|
26
|
+
hasNextPage: boolean;
|
|
27
|
+
endCursor: string | null;
|
|
28
|
+
}
|
|
29
|
+
export interface ListRepositoriesResult {
|
|
30
|
+
project: {
|
|
31
|
+
containerRepositories: {
|
|
32
|
+
nodes: ContainerRepositoryNode[];
|
|
33
|
+
pageInfo: PageInfo;
|
|
34
|
+
};
|
|
35
|
+
} | null;
|
|
36
|
+
}
|
|
37
|
+
export interface ListRepositoriesVars {
|
|
38
|
+
fullPath: string;
|
|
39
|
+
name?: string | null;
|
|
40
|
+
first?: number | null;
|
|
41
|
+
after?: string | null;
|
|
42
|
+
}
|
|
43
|
+
export declare const LIST_CONTAINER_REPOSITORIES: TypedDocumentNode<ListRepositoriesResult, ListRepositoriesVars>;
|
|
44
|
+
export interface GetRepositoryResult {
|
|
45
|
+
containerRepository: ContainerRepositoryNode | null;
|
|
46
|
+
}
|
|
47
|
+
export interface GetRepositoryVars {
|
|
48
|
+
id: string;
|
|
49
|
+
}
|
|
50
|
+
export declare const GET_CONTAINER_REPOSITORY: TypedDocumentNode<GetRepositoryResult, GetRepositoryVars>;
|
|
51
|
+
export interface ListTagsResult {
|
|
52
|
+
containerRepository: {
|
|
53
|
+
id: string;
|
|
54
|
+
tags: {
|
|
55
|
+
nodes: ContainerTagNode[];
|
|
56
|
+
pageInfo: PageInfo;
|
|
57
|
+
};
|
|
58
|
+
} | null;
|
|
59
|
+
}
|
|
60
|
+
export interface ListTagsVars {
|
|
61
|
+
id: string;
|
|
62
|
+
name?: string | null;
|
|
63
|
+
first?: number | null;
|
|
64
|
+
after?: string | null;
|
|
65
|
+
}
|
|
66
|
+
export declare const LIST_CONTAINER_REPOSITORY_TAGS: TypedDocumentNode<ListTagsResult, ListTagsVars>;
|
|
67
|
+
export interface DestroyRepositoryResult {
|
|
68
|
+
destroyContainerRepository: {
|
|
69
|
+
containerRepository: {
|
|
70
|
+
id: string;
|
|
71
|
+
status: string | null;
|
|
72
|
+
} | null;
|
|
73
|
+
errors: string[];
|
|
74
|
+
} | null;
|
|
75
|
+
}
|
|
76
|
+
export interface DestroyRepositoryVars {
|
|
77
|
+
id: string;
|
|
78
|
+
}
|
|
79
|
+
export declare const DESTROY_CONTAINER_REPOSITORY: TypedDocumentNode<DestroyRepositoryResult, DestroyRepositoryVars>;
|
|
80
|
+
export interface DestroyTagsResult {
|
|
81
|
+
destroyContainerRepositoryTags: {
|
|
82
|
+
deletedTagNames: string[];
|
|
83
|
+
errors: string[];
|
|
84
|
+
} | null;
|
|
85
|
+
}
|
|
86
|
+
export interface DestroyTagsVars {
|
|
87
|
+
id: string;
|
|
88
|
+
tagNames: string[];
|
|
89
|
+
}
|
|
90
|
+
export declare const DESTROY_CONTAINER_REPOSITORY_TAGS: TypedDocumentNode<DestroyTagsResult, DestroyTagsVars>;
|
|
91
|
+
export {};
|
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.DESTROY_CONTAINER_REPOSITORY_TAGS = exports.DESTROY_CONTAINER_REPOSITORY = exports.LIST_CONTAINER_REPOSITORY_TAGS = exports.GET_CONTAINER_REPOSITORY = exports.LIST_CONTAINER_REPOSITORIES = void 0;
|
|
4
|
+
const graphql_tag_1 = require("graphql-tag");
|
|
5
|
+
const REPOSITORY_LIST_FIELDS = `
|
|
6
|
+
id
|
|
7
|
+
name
|
|
8
|
+
path
|
|
9
|
+
location
|
|
10
|
+
status
|
|
11
|
+
tagsCount
|
|
12
|
+
createdAt
|
|
13
|
+
updatedAt
|
|
14
|
+
`;
|
|
15
|
+
const REPOSITORY_DETAIL_FIELDS = `
|
|
16
|
+
${REPOSITORY_LIST_FIELDS}
|
|
17
|
+
lastPublishedAt
|
|
18
|
+
`;
|
|
19
|
+
const TAG_FIELDS = `
|
|
20
|
+
name
|
|
21
|
+
path
|
|
22
|
+
location
|
|
23
|
+
digest
|
|
24
|
+
revision
|
|
25
|
+
shortRevision
|
|
26
|
+
totalSize
|
|
27
|
+
createdAt
|
|
28
|
+
publishedAt
|
|
29
|
+
mediaType
|
|
30
|
+
`;
|
|
31
|
+
exports.LIST_CONTAINER_REPOSITORIES = (0, graphql_tag_1.gql) `
|
|
32
|
+
query ListContainerRepositories($fullPath: ID!, $name: String, $first: Int, $after: String) {
|
|
33
|
+
project(fullPath: $fullPath) {
|
|
34
|
+
containerRepositories(name: $name, first: $first, after: $after) {
|
|
35
|
+
nodes {
|
|
36
|
+
${REPOSITORY_LIST_FIELDS}
|
|
37
|
+
}
|
|
38
|
+
pageInfo {
|
|
39
|
+
hasNextPage
|
|
40
|
+
endCursor
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
`;
|
|
46
|
+
exports.GET_CONTAINER_REPOSITORY = (0, graphql_tag_1.gql) `
|
|
47
|
+
query GetContainerRepository($id: ContainerRepositoryID!) {
|
|
48
|
+
containerRepository(id: $id) {
|
|
49
|
+
${REPOSITORY_DETAIL_FIELDS}
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
`;
|
|
53
|
+
exports.LIST_CONTAINER_REPOSITORY_TAGS = (0, graphql_tag_1.gql) `
|
|
54
|
+
query ListContainerRepositoryTags(
|
|
55
|
+
$id: ContainerRepositoryID!
|
|
56
|
+
$name: String
|
|
57
|
+
$first: Int
|
|
58
|
+
$after: String
|
|
59
|
+
) {
|
|
60
|
+
containerRepository(id: $id) {
|
|
61
|
+
id
|
|
62
|
+
tags(name: $name, first: $first, after: $after) {
|
|
63
|
+
nodes {
|
|
64
|
+
${TAG_FIELDS}
|
|
65
|
+
}
|
|
66
|
+
pageInfo {
|
|
67
|
+
hasNextPage
|
|
68
|
+
endCursor
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
`;
|
|
74
|
+
exports.DESTROY_CONTAINER_REPOSITORY = (0, graphql_tag_1.gql) `
|
|
75
|
+
mutation DestroyContainerRepository($id: ContainerRepositoryID!) {
|
|
76
|
+
destroyContainerRepository(input: { id: $id }) {
|
|
77
|
+
containerRepository {
|
|
78
|
+
id
|
|
79
|
+
status
|
|
80
|
+
}
|
|
81
|
+
errors
|
|
82
|
+
}
|
|
83
|
+
}
|
|
84
|
+
`;
|
|
85
|
+
exports.DESTROY_CONTAINER_REPOSITORY_TAGS = (0, graphql_tag_1.gql) `
|
|
86
|
+
mutation DestroyContainerRepositoryTags($id: ContainerRepositoryID!, $tagNames: [String!]!) {
|
|
87
|
+
destroyContainerRepositoryTags(input: { id: $id, tagNames: $tagNames }) {
|
|
88
|
+
deletedTagNames
|
|
89
|
+
errors
|
|
90
|
+
}
|
|
91
|
+
}
|
|
92
|
+
`;
|
|
93
|
+
//# sourceMappingURL=containerRegistry.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"containerRegistry.js","sourceRoot":"","sources":["../../../src/graphql/containerRegistry.ts"],"names":[],"mappings":";;;AAAA,6CAAkC;AAqBlC,MAAM,sBAAsB,GAAG;;;;;;;;;CAS9B,CAAC;AACF,MAAM,wBAAwB,GAAG;IAC7B,sBAAsB;;CAEzB,CAAC;AAEF,MAAM,UAAU,GAAG;;;;;;;;;;;CAWlB,CAAC;AAgDW,QAAA,2BAA2B,GAGpC,IAAA,iBAAG,EAAA;;;;;YAKK,sBAAsB;;;;;;;;;CASjC,CAAC;AASW,QAAA,wBAAwB,GACnC,IAAA,iBAAG,EAAA;;;UAGK,wBAAwB;;;GAG/B,CAAC;AAkBS,QAAA,8BAA8B,GAAoD,IAAA,iBAAG,EAAA;;;;;;;;;;;YAWtF,UAAU;;;;;;;;;CASrB,CAAC;AAYW,QAAA,4BAA4B,GAGrC,IAAA,iBAAG,EAAA;;;;;;;;;;CAUN,CAAC;AAaW,QAAA,iCAAiC,GAG1C,IAAA,iBAAG,EAAA;;;;;;;CAON,CAAC"}
|
|
@@ -0,0 +1,162 @@
|
|
|
1
|
+
import { TypedDocumentNode } from '@graphql-typed-document-node/core';
|
|
2
|
+
export interface RunnerNode {
|
|
3
|
+
id: string;
|
|
4
|
+
description: string | null;
|
|
5
|
+
runnerType: string;
|
|
6
|
+
status: string | null;
|
|
7
|
+
paused: boolean;
|
|
8
|
+
locked: boolean;
|
|
9
|
+
runUntagged: boolean;
|
|
10
|
+
tagList: string[] | null;
|
|
11
|
+
accessLevel: string | null;
|
|
12
|
+
maximumTimeout: number | null;
|
|
13
|
+
jobExecutionStatus: string | null;
|
|
14
|
+
jobCount: number | null;
|
|
15
|
+
contactedAt: string | null;
|
|
16
|
+
createdAt: string | null;
|
|
17
|
+
}
|
|
18
|
+
interface PageInfo {
|
|
19
|
+
hasNextPage: boolean;
|
|
20
|
+
endCursor: string | null;
|
|
21
|
+
}
|
|
22
|
+
interface RunnerConnection {
|
|
23
|
+
nodes: RunnerNode[];
|
|
24
|
+
pageInfo: PageInfo;
|
|
25
|
+
}
|
|
26
|
+
export interface RunnerListVars {
|
|
27
|
+
type?: string | null;
|
|
28
|
+
status?: string | null;
|
|
29
|
+
paused?: boolean | null;
|
|
30
|
+
tagList?: string[] | null;
|
|
31
|
+
search?: string | null;
|
|
32
|
+
first?: number | null;
|
|
33
|
+
after?: string | null;
|
|
34
|
+
}
|
|
35
|
+
export interface ListRunnersResult {
|
|
36
|
+
runners: RunnerConnection | null;
|
|
37
|
+
}
|
|
38
|
+
export declare const LIST_RUNNERS: TypedDocumentNode<ListRunnersResult, RunnerListVars>;
|
|
39
|
+
export interface ListOwnedRunnersResult {
|
|
40
|
+
currentUser: {
|
|
41
|
+
runners: RunnerConnection | null;
|
|
42
|
+
} | null;
|
|
43
|
+
}
|
|
44
|
+
export declare const LIST_OWNED_RUNNERS: TypedDocumentNode<ListOwnedRunnersResult, RunnerListVars>;
|
|
45
|
+
export interface ListGroupRunnersResult {
|
|
46
|
+
group: {
|
|
47
|
+
runners: RunnerConnection | null;
|
|
48
|
+
} | null;
|
|
49
|
+
}
|
|
50
|
+
export interface ListNamespaceRunnersVars extends RunnerListVars {
|
|
51
|
+
fullPath: string;
|
|
52
|
+
}
|
|
53
|
+
export declare const LIST_GROUP_RUNNERS: TypedDocumentNode<ListGroupRunnersResult, ListNamespaceRunnersVars>;
|
|
54
|
+
export interface ListProjectRunnersResult {
|
|
55
|
+
project: {
|
|
56
|
+
runners: RunnerConnection | null;
|
|
57
|
+
} | null;
|
|
58
|
+
}
|
|
59
|
+
export declare const LIST_PROJECT_RUNNERS: TypedDocumentNode<ListProjectRunnersResult, ListNamespaceRunnersVars>;
|
|
60
|
+
export interface GetRunnerResult {
|
|
61
|
+
runner: RunnerNode | null;
|
|
62
|
+
}
|
|
63
|
+
export interface GetRunnerVars {
|
|
64
|
+
id: string;
|
|
65
|
+
}
|
|
66
|
+
export declare const GET_RUNNER: TypedDocumentNode<GetRunnerResult, GetRunnerVars>;
|
|
67
|
+
export interface RunnerJobNode {
|
|
68
|
+
id: string;
|
|
69
|
+
name: string | null;
|
|
70
|
+
status: string | null;
|
|
71
|
+
createdAt: string | null;
|
|
72
|
+
finishedAt: string | null;
|
|
73
|
+
duration: number | null;
|
|
74
|
+
webPath: string | null;
|
|
75
|
+
}
|
|
76
|
+
export interface ListRunnerJobsResult {
|
|
77
|
+
runner: {
|
|
78
|
+
id: string;
|
|
79
|
+
jobs: {
|
|
80
|
+
nodes: RunnerJobNode[];
|
|
81
|
+
pageInfo: PageInfo;
|
|
82
|
+
} | null;
|
|
83
|
+
} | null;
|
|
84
|
+
}
|
|
85
|
+
export interface ListRunnerJobsVars {
|
|
86
|
+
id: string;
|
|
87
|
+
statuses?: string | null;
|
|
88
|
+
first?: number | null;
|
|
89
|
+
after?: string | null;
|
|
90
|
+
}
|
|
91
|
+
export declare const LIST_RUNNER_JOBS: TypedDocumentNode<ListRunnerJobsResult, ListRunnerJobsVars>;
|
|
92
|
+
export interface ResolveGroupResult {
|
|
93
|
+
group: {
|
|
94
|
+
id: string;
|
|
95
|
+
} | null;
|
|
96
|
+
}
|
|
97
|
+
export interface ResolveProjectResult {
|
|
98
|
+
project: {
|
|
99
|
+
id: string;
|
|
100
|
+
} | null;
|
|
101
|
+
}
|
|
102
|
+
export interface ResolvePathVars {
|
|
103
|
+
fullPath: string;
|
|
104
|
+
}
|
|
105
|
+
export declare const RESOLVE_GROUP_ID: TypedDocumentNode<ResolveGroupResult, ResolvePathVars>;
|
|
106
|
+
export declare const RESOLVE_PROJECT_ID: TypedDocumentNode<ResolveProjectResult, ResolvePathVars>;
|
|
107
|
+
export interface RunnerCreateResult {
|
|
108
|
+
runnerCreate: {
|
|
109
|
+
runner: (RunnerNode & {
|
|
110
|
+
ephemeralAuthenticationToken: string | null;
|
|
111
|
+
}) | null;
|
|
112
|
+
errors: string[];
|
|
113
|
+
} | null;
|
|
114
|
+
}
|
|
115
|
+
export interface RunnerCreateVars {
|
|
116
|
+
input: {
|
|
117
|
+
runnerType: string;
|
|
118
|
+
groupId?: string | null;
|
|
119
|
+
projectId?: string | null;
|
|
120
|
+
description?: string | null;
|
|
121
|
+
paused?: boolean | null;
|
|
122
|
+
locked?: boolean | null;
|
|
123
|
+
runUntagged?: boolean | null;
|
|
124
|
+
tagList?: string[] | null;
|
|
125
|
+
accessLevel?: string | null;
|
|
126
|
+
maximumTimeout?: number | null;
|
|
127
|
+
maintenanceNote?: string | null;
|
|
128
|
+
};
|
|
129
|
+
}
|
|
130
|
+
export declare const RUNNER_CREATE: TypedDocumentNode<RunnerCreateResult, RunnerCreateVars>;
|
|
131
|
+
export interface RunnerUpdateResult {
|
|
132
|
+
runnerUpdate: {
|
|
133
|
+
runner: RunnerNode | null;
|
|
134
|
+
errors: string[];
|
|
135
|
+
} | null;
|
|
136
|
+
}
|
|
137
|
+
export interface RunnerUpdateVars {
|
|
138
|
+
input: {
|
|
139
|
+
id: string;
|
|
140
|
+
description?: string | null;
|
|
141
|
+
paused?: boolean | null;
|
|
142
|
+
locked?: boolean | null;
|
|
143
|
+
runUntagged?: boolean | null;
|
|
144
|
+
tagList?: string[] | null;
|
|
145
|
+
accessLevel?: string | null;
|
|
146
|
+
maximumTimeout?: number | null;
|
|
147
|
+
maintenanceNote?: string | null;
|
|
148
|
+
};
|
|
149
|
+
}
|
|
150
|
+
export declare const RUNNER_UPDATE: TypedDocumentNode<RunnerUpdateResult, RunnerUpdateVars>;
|
|
151
|
+
export interface RunnerDeleteResult {
|
|
152
|
+
runnerDelete: {
|
|
153
|
+
errors: string[];
|
|
154
|
+
} | null;
|
|
155
|
+
}
|
|
156
|
+
export interface RunnerDeleteVars {
|
|
157
|
+
input: {
|
|
158
|
+
id: string;
|
|
159
|
+
};
|
|
160
|
+
}
|
|
161
|
+
export declare const RUNNER_DELETE: TypedDocumentNode<RunnerDeleteResult, RunnerDeleteVars>;
|
|
162
|
+
export {};
|
|
@@ -0,0 +1,144 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.RUNNER_DELETE = exports.RUNNER_UPDATE = exports.RUNNER_CREATE = exports.RESOLVE_PROJECT_ID = exports.RESOLVE_GROUP_ID = exports.LIST_RUNNER_JOBS = exports.GET_RUNNER = exports.LIST_PROJECT_RUNNERS = exports.LIST_GROUP_RUNNERS = exports.LIST_OWNED_RUNNERS = exports.LIST_RUNNERS = void 0;
|
|
4
|
+
const graphql_tag_1 = require("graphql-tag");
|
|
5
|
+
const RUNNER_FIELDS = `
|
|
6
|
+
id
|
|
7
|
+
description
|
|
8
|
+
runnerType
|
|
9
|
+
status
|
|
10
|
+
paused
|
|
11
|
+
locked
|
|
12
|
+
runUntagged
|
|
13
|
+
tagList
|
|
14
|
+
accessLevel
|
|
15
|
+
maximumTimeout
|
|
16
|
+
jobExecutionStatus
|
|
17
|
+
jobCount
|
|
18
|
+
contactedAt
|
|
19
|
+
createdAt
|
|
20
|
+
`;
|
|
21
|
+
const LIST_ARG_DECLS = `
|
|
22
|
+
$type: CiRunnerType
|
|
23
|
+
$status: CiRunnerStatus
|
|
24
|
+
$paused: Boolean
|
|
25
|
+
$tagList: [String!]
|
|
26
|
+
$search: String
|
|
27
|
+
$first: Int
|
|
28
|
+
$after: String
|
|
29
|
+
`;
|
|
30
|
+
const LIST_ARG_USE = `
|
|
31
|
+
type: $type
|
|
32
|
+
status: $status
|
|
33
|
+
paused: $paused
|
|
34
|
+
tagList: $tagList
|
|
35
|
+
search: $search
|
|
36
|
+
first: $first
|
|
37
|
+
after: $after
|
|
38
|
+
`;
|
|
39
|
+
exports.LIST_RUNNERS = (0, graphql_tag_1.gql) `
|
|
40
|
+
query ListRunners(${LIST_ARG_DECLS}) {
|
|
41
|
+
runners(${LIST_ARG_USE}) {
|
|
42
|
+
nodes { ${RUNNER_FIELDS} }
|
|
43
|
+
pageInfo { hasNextPage endCursor }
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
`;
|
|
47
|
+
exports.LIST_OWNED_RUNNERS = (0, graphql_tag_1.gql) `
|
|
48
|
+
query ListOwnedRunners(${LIST_ARG_DECLS}) {
|
|
49
|
+
currentUser {
|
|
50
|
+
runners(${LIST_ARG_USE}) {
|
|
51
|
+
nodes { ${RUNNER_FIELDS} }
|
|
52
|
+
pageInfo { hasNextPage endCursor }
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
`;
|
|
57
|
+
exports.LIST_GROUP_RUNNERS = (0, graphql_tag_1.gql) `
|
|
58
|
+
query ListGroupRunners($fullPath: ID!, ${LIST_ARG_DECLS}) {
|
|
59
|
+
group(fullPath: $fullPath) {
|
|
60
|
+
runners(${LIST_ARG_USE}) {
|
|
61
|
+
nodes { ${RUNNER_FIELDS} }
|
|
62
|
+
pageInfo { hasNextPage endCursor }
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
}
|
|
66
|
+
`;
|
|
67
|
+
exports.LIST_PROJECT_RUNNERS = (0, graphql_tag_1.gql) `
|
|
68
|
+
query ListProjectRunners($fullPath: ID!, ${LIST_ARG_DECLS}) {
|
|
69
|
+
project(fullPath: $fullPath) {
|
|
70
|
+
runners(${LIST_ARG_USE}) {
|
|
71
|
+
nodes { ${RUNNER_FIELDS} }
|
|
72
|
+
pageInfo { hasNextPage endCursor }
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
}
|
|
76
|
+
`;
|
|
77
|
+
exports.GET_RUNNER = (0, graphql_tag_1.gql) `
|
|
78
|
+
query GetRunner($id: CiRunnerID!) {
|
|
79
|
+
runner(id: $id) { ${RUNNER_FIELDS} }
|
|
80
|
+
}
|
|
81
|
+
`;
|
|
82
|
+
exports.LIST_RUNNER_JOBS = (0, graphql_tag_1.gql) `
|
|
83
|
+
query ListRunnerJobs($id: CiRunnerID!, $statuses: CiJobStatus, $first: Int, $after: String) {
|
|
84
|
+
runner(id: $id) {
|
|
85
|
+
id
|
|
86
|
+
jobs(statuses: $statuses, first: $first, after: $after) {
|
|
87
|
+
nodes {
|
|
88
|
+
id
|
|
89
|
+
name
|
|
90
|
+
status
|
|
91
|
+
createdAt
|
|
92
|
+
finishedAt
|
|
93
|
+
duration
|
|
94
|
+
webPath
|
|
95
|
+
}
|
|
96
|
+
pageInfo {
|
|
97
|
+
hasNextPage
|
|
98
|
+
endCursor
|
|
99
|
+
}
|
|
100
|
+
}
|
|
101
|
+
}
|
|
102
|
+
}
|
|
103
|
+
`;
|
|
104
|
+
exports.RESOLVE_GROUP_ID = (0, graphql_tag_1.gql) `
|
|
105
|
+
query ResolveGroupId($fullPath: ID!) {
|
|
106
|
+
group(fullPath: $fullPath) {
|
|
107
|
+
id
|
|
108
|
+
}
|
|
109
|
+
}
|
|
110
|
+
`;
|
|
111
|
+
exports.RESOLVE_PROJECT_ID = (0, graphql_tag_1.gql) `
|
|
112
|
+
query ResolveProjectId($fullPath: ID!) {
|
|
113
|
+
project(fullPath: $fullPath) {
|
|
114
|
+
id
|
|
115
|
+
}
|
|
116
|
+
}
|
|
117
|
+
`;
|
|
118
|
+
exports.RUNNER_CREATE = (0, graphql_tag_1.gql) `
|
|
119
|
+
mutation RunnerCreate($input: RunnerCreateInput!) {
|
|
120
|
+
runnerCreate(input: $input) {
|
|
121
|
+
runner {
|
|
122
|
+
${RUNNER_FIELDS}
|
|
123
|
+
ephemeralAuthenticationToken
|
|
124
|
+
}
|
|
125
|
+
errors
|
|
126
|
+
}
|
|
127
|
+
}
|
|
128
|
+
`;
|
|
129
|
+
exports.RUNNER_UPDATE = (0, graphql_tag_1.gql) `
|
|
130
|
+
mutation RunnerUpdate($input: RunnerUpdateInput!) {
|
|
131
|
+
runnerUpdate(input: $input) {
|
|
132
|
+
runner { ${RUNNER_FIELDS} }
|
|
133
|
+
errors
|
|
134
|
+
}
|
|
135
|
+
}
|
|
136
|
+
`;
|
|
137
|
+
exports.RUNNER_DELETE = (0, graphql_tag_1.gql) `
|
|
138
|
+
mutation RunnerDelete($input: RunnerDeleteInput!) {
|
|
139
|
+
runnerDelete(input: $input) {
|
|
140
|
+
errors
|
|
141
|
+
}
|
|
142
|
+
}
|
|
143
|
+
`;
|
|
144
|
+
//# sourceMappingURL=runners.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"runners.js","sourceRoot":"","sources":["../../../src/graphql/runners.ts"],"names":[],"mappings":";;;AAAA,6CAAkC;AAiBlC,MAAM,aAAa,GAAG;;;;;;;;;;;;;;;CAerB,CAAC;AAuCF,MAAM,cAAc,GAAG;;;;;;;;CAQtB,CAAC;AACF,MAAM,YAAY,GAAG;;;;;;;;CAQpB,CAAC;AAMW,QAAA,YAAY,GAAyD,IAAA,iBAAG,EAAA;sBAC/D,cAAc;cACtB,YAAY;gBACV,aAAa;;;;CAI5B,CAAC;AAMW,QAAA,kBAAkB,GAA8D,IAAA,iBAAG,EAAA;2BACrE,cAAc;;gBAEzB,YAAY;kBACV,aAAa;;;;;CAK9B,CAAC;AASW,QAAA,kBAAkB,GAG3B,IAAA,iBAAG,EAAA;2CACoC,cAAc;;gBAEzC,YAAY;kBACV,aAAa;;;;;CAK9B,CAAC;AAMW,QAAA,oBAAoB,GAG7B,IAAA,iBAAG,EAAA;6CACsC,cAAc;;gBAE3C,YAAY;kBACV,aAAa;;;;;CAK9B,CAAC;AASW,QAAA,UAAU,GAAsD,IAAA,iBAAG,EAAA;;wBAExD,aAAa;;CAEpC,CAAC;AAwBW,QAAA,gBAAgB,GAAgE,IAAA,iBAAG,EAAA;;;;;;;;;;;;;;;;;;;;;CAqB/F,CAAC;AAaW,QAAA,gBAAgB,GAA2D,IAAA,iBAAG,EAAA;;;;;;CAM1F,CAAC;AACW,QAAA,kBAAkB,GAA6D,IAAA,iBAAG,EAAA;;;;;;CAM9F,CAAC;AAwBW,QAAA,aAAa,GAA4D,IAAA,iBAAG,EAAA;;;;UAI/E,aAAa;;;;;;CAMtB,CAAC;AAmBW,QAAA,aAAa,GAA4D,IAAA,iBAAG,EAAA;;;iBAGxE,aAAa;;;;CAI7B,CAAC;AASW,QAAA,aAAa,GAA4D,IAAA,iBAAG,EAAA;;;;;;CAMxF,CAAC"}
|
|
@@ -0,0 +1,90 @@
|
|
|
1
|
+
import { TypedDocumentNode } from '@graphql-typed-document-node/core';
|
|
2
|
+
export interface VulnerabilityNode {
|
|
3
|
+
id: string;
|
|
4
|
+
title: string | null;
|
|
5
|
+
description: string | null;
|
|
6
|
+
state: string | null;
|
|
7
|
+
severity: string | null;
|
|
8
|
+
reportType: string | null;
|
|
9
|
+
resolvedOnDefaultBranch: boolean | null;
|
|
10
|
+
detectedAt: string | null;
|
|
11
|
+
confirmedAt: string | null;
|
|
12
|
+
resolvedAt: string | null;
|
|
13
|
+
dismissedAt: string | null;
|
|
14
|
+
vulnerabilityPath: string | null;
|
|
15
|
+
webUrl: string | null;
|
|
16
|
+
}
|
|
17
|
+
interface PageInfo {
|
|
18
|
+
hasNextPage: boolean;
|
|
19
|
+
endCursor: string | null;
|
|
20
|
+
}
|
|
21
|
+
interface VulnConnection {
|
|
22
|
+
nodes: VulnerabilityNode[];
|
|
23
|
+
pageInfo: PageInfo;
|
|
24
|
+
}
|
|
25
|
+
export interface VulnListVars {
|
|
26
|
+
state?: string[] | null;
|
|
27
|
+
severity?: string[] | null;
|
|
28
|
+
reportType?: string[] | null;
|
|
29
|
+
sort?: string | null;
|
|
30
|
+
first?: number | null;
|
|
31
|
+
after?: string | null;
|
|
32
|
+
}
|
|
33
|
+
export interface ListProjectVulnsResult {
|
|
34
|
+
project: {
|
|
35
|
+
vulnerabilities: VulnConnection | null;
|
|
36
|
+
} | null;
|
|
37
|
+
}
|
|
38
|
+
export interface ListNamespaceVulnsVars extends VulnListVars {
|
|
39
|
+
fullPath: string;
|
|
40
|
+
}
|
|
41
|
+
export declare const LIST_PROJECT_VULNS: TypedDocumentNode<ListProjectVulnsResult, ListNamespaceVulnsVars>;
|
|
42
|
+
export interface ListGroupVulnsResult {
|
|
43
|
+
group: {
|
|
44
|
+
vulnerabilities: VulnConnection | null;
|
|
45
|
+
} | null;
|
|
46
|
+
}
|
|
47
|
+
export declare const LIST_GROUP_VULNS: TypedDocumentNode<ListGroupVulnsResult, ListNamespaceVulnsVars>;
|
|
48
|
+
export interface ListInstanceVulnsResult {
|
|
49
|
+
vulnerabilities: VulnConnection | null;
|
|
50
|
+
}
|
|
51
|
+
export interface ListInstanceVulnsVars extends VulnListVars {
|
|
52
|
+
projectId?: string[] | null;
|
|
53
|
+
}
|
|
54
|
+
export declare const LIST_INSTANCE_VULNS: TypedDocumentNode<ListInstanceVulnsResult, ListInstanceVulnsVars>;
|
|
55
|
+
export interface GetVulnResult {
|
|
56
|
+
vulnerability: VulnerabilityNode | null;
|
|
57
|
+
}
|
|
58
|
+
export interface GetVulnVars {
|
|
59
|
+
id: string;
|
|
60
|
+
}
|
|
61
|
+
export declare const GET_VULN: TypedDocumentNode<GetVulnResult, GetVulnVars>;
|
|
62
|
+
interface VulnMutationPayload {
|
|
63
|
+
vulnerability: VulnerabilityNode | null;
|
|
64
|
+
errors: string[];
|
|
65
|
+
}
|
|
66
|
+
export interface DismissVulnResult {
|
|
67
|
+
vulnerabilityDismiss: VulnMutationPayload | null;
|
|
68
|
+
}
|
|
69
|
+
export interface DismissVulnVars {
|
|
70
|
+
id: string;
|
|
71
|
+
comment?: string | null;
|
|
72
|
+
dismissalReason?: string | null;
|
|
73
|
+
}
|
|
74
|
+
export declare const DISMISS_VULN: TypedDocumentNode<DismissVulnResult, DismissVulnVars>;
|
|
75
|
+
export interface ConfirmVulnResult {
|
|
76
|
+
vulnerabilityConfirm: VulnMutationPayload | null;
|
|
77
|
+
}
|
|
78
|
+
export interface VulnIdVars {
|
|
79
|
+
id: string;
|
|
80
|
+
}
|
|
81
|
+
export declare const CONFIRM_VULN: TypedDocumentNode<ConfirmVulnResult, VulnIdVars>;
|
|
82
|
+
export interface ResolveVulnResult {
|
|
83
|
+
vulnerabilityResolve: VulnMutationPayload | null;
|
|
84
|
+
}
|
|
85
|
+
export declare const RESOLVE_VULN: TypedDocumentNode<ResolveVulnResult, VulnIdVars>;
|
|
86
|
+
export interface RevertVulnResult {
|
|
87
|
+
vulnerabilityRevertToDetected: VulnMutationPayload | null;
|
|
88
|
+
}
|
|
89
|
+
export declare const REVERT_VULN: TypedDocumentNode<RevertVulnResult, VulnIdVars>;
|
|
90
|
+
export {};
|
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.REVERT_VULN = exports.RESOLVE_VULN = exports.CONFIRM_VULN = exports.DISMISS_VULN = exports.GET_VULN = exports.LIST_INSTANCE_VULNS = exports.LIST_GROUP_VULNS = exports.LIST_PROJECT_VULNS = void 0;
|
|
4
|
+
const graphql_tag_1 = require("graphql-tag");
|
|
5
|
+
const VULN_FIELDS = `
|
|
6
|
+
id
|
|
7
|
+
title
|
|
8
|
+
description
|
|
9
|
+
state
|
|
10
|
+
severity
|
|
11
|
+
reportType
|
|
12
|
+
resolvedOnDefaultBranch
|
|
13
|
+
detectedAt
|
|
14
|
+
confirmedAt
|
|
15
|
+
resolvedAt
|
|
16
|
+
dismissedAt
|
|
17
|
+
vulnerabilityPath
|
|
18
|
+
webUrl
|
|
19
|
+
`;
|
|
20
|
+
const LIST_ARG_DECLS = `
|
|
21
|
+
$state: [VulnerabilityState!]
|
|
22
|
+
$severity: [VulnerabilitySeverity!]
|
|
23
|
+
$reportType: [VulnerabilityReportType!]
|
|
24
|
+
$sort: VulnerabilitySort
|
|
25
|
+
$first: Int
|
|
26
|
+
$after: String
|
|
27
|
+
`;
|
|
28
|
+
const LIST_ARG_USE = `
|
|
29
|
+
state: $state
|
|
30
|
+
severity: $severity
|
|
31
|
+
reportType: $reportType
|
|
32
|
+
sort: $sort
|
|
33
|
+
first: $first
|
|
34
|
+
after: $after
|
|
35
|
+
`;
|
|
36
|
+
exports.LIST_PROJECT_VULNS = (0, graphql_tag_1.gql) `
|
|
37
|
+
query ListProjectVulnerabilities($fullPath: ID!, ${LIST_ARG_DECLS}) {
|
|
38
|
+
project(fullPath: $fullPath) {
|
|
39
|
+
vulnerabilities(${LIST_ARG_USE}) {
|
|
40
|
+
nodes { ${VULN_FIELDS} }
|
|
41
|
+
pageInfo { hasNextPage endCursor }
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
`;
|
|
46
|
+
exports.LIST_GROUP_VULNS = (0, graphql_tag_1.gql) `
|
|
47
|
+
query ListGroupVulnerabilities($fullPath: ID!, ${LIST_ARG_DECLS}) {
|
|
48
|
+
group(fullPath: $fullPath) {
|
|
49
|
+
vulnerabilities(${LIST_ARG_USE}) {
|
|
50
|
+
nodes { ${VULN_FIELDS} }
|
|
51
|
+
pageInfo { hasNextPage endCursor }
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
`;
|
|
56
|
+
exports.LIST_INSTANCE_VULNS = (0, graphql_tag_1.gql) `
|
|
57
|
+
query ListInstanceVulnerabilities($projectId: [ID!], ${LIST_ARG_DECLS}) {
|
|
58
|
+
vulnerabilities(projectId: $projectId, ${LIST_ARG_USE}) {
|
|
59
|
+
nodes { ${VULN_FIELDS} }
|
|
60
|
+
pageInfo { hasNextPage endCursor }
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
`;
|
|
64
|
+
exports.GET_VULN = (0, graphql_tag_1.gql) `
|
|
65
|
+
query GetVulnerability($id: VulnerabilityID!) {
|
|
66
|
+
vulnerability(id: $id) { ${VULN_FIELDS} }
|
|
67
|
+
}
|
|
68
|
+
`;
|
|
69
|
+
exports.DISMISS_VULN = (0, graphql_tag_1.gql) `
|
|
70
|
+
mutation DismissVulnerability(
|
|
71
|
+
$id: VulnerabilityID!
|
|
72
|
+
$comment: String
|
|
73
|
+
$dismissalReason: VulnerabilityDismissalReason
|
|
74
|
+
) {
|
|
75
|
+
vulnerabilityDismiss(input: { id: $id, comment: $comment, dismissalReason: $dismissalReason }) {
|
|
76
|
+
vulnerability { ${VULN_FIELDS} }
|
|
77
|
+
errors
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
`;
|
|
81
|
+
exports.CONFIRM_VULN = (0, graphql_tag_1.gql) `
|
|
82
|
+
mutation ConfirmVulnerability($id: VulnerabilityID!) {
|
|
83
|
+
vulnerabilityConfirm(input: { id: $id }) {
|
|
84
|
+
vulnerability { ${VULN_FIELDS} }
|
|
85
|
+
errors
|
|
86
|
+
}
|
|
87
|
+
}
|
|
88
|
+
`;
|
|
89
|
+
exports.RESOLVE_VULN = (0, graphql_tag_1.gql) `
|
|
90
|
+
mutation ResolveVulnerability($id: VulnerabilityID!) {
|
|
91
|
+
vulnerabilityResolve(input: { id: $id }) {
|
|
92
|
+
vulnerability { ${VULN_FIELDS} }
|
|
93
|
+
errors
|
|
94
|
+
}
|
|
95
|
+
}
|
|
96
|
+
`;
|
|
97
|
+
exports.REVERT_VULN = (0, graphql_tag_1.gql) `
|
|
98
|
+
mutation RevertVulnerabilityToDetected($id: VulnerabilityID!) {
|
|
99
|
+
vulnerabilityRevertToDetected(input: { id: $id }) {
|
|
100
|
+
vulnerability { ${VULN_FIELDS} }
|
|
101
|
+
errors
|
|
102
|
+
}
|
|
103
|
+
}
|
|
104
|
+
`;
|
|
105
|
+
//# sourceMappingURL=vulnerabilities.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"vulnerabilities.js","sourceRoot":"","sources":["../../../src/graphql/vulnerabilities.ts"],"names":[],"mappings":";;;AAAA,6CAAkC;AAiBlC,MAAM,WAAW,GAAG;;;;;;;;;;;;;;CAcnB,CAAC;AAqCF,MAAM,cAAc,GAAG;;;;;;;CAOtB,CAAC;AACF,MAAM,YAAY,GAAG;;;;;;;CAOpB,CAAC;AASW,QAAA,kBAAkB,GAC7B,IAAA,iBAAG,EAAA;qDACgD,cAAc;;wBAE3C,YAAY;kBAClB,WAAW;;;;;CAK5B,CAAC;AAMW,QAAA,gBAAgB,GAC3B,IAAA,iBAAG,EAAA;mDAC8C,cAAc;;wBAEzC,YAAY;kBAClB,WAAW;;;;;CAK5B,CAAC;AASW,QAAA,mBAAmB,GAG5B,IAAA,iBAAG,EAAA;yDACkD,cAAc;6CAC1B,YAAY;gBACzC,WAAW;;;;CAI1B,CAAC;AASW,QAAA,QAAQ,GAAkD,IAAA,iBAAG,EAAA;;+BAE3C,WAAW;;CAEzC,CAAC;AAgBW,QAAA,YAAY,GAA0D,IAAA,iBAAG,EAAA;;;;;;;wBAO9D,WAAW;;;;CAIlC,CAAC;AAQW,QAAA,YAAY,GAAqD,IAAA,iBAAG,EAAA;;;wBAGzD,WAAW;;;;CAIlC,CAAC;AAKW,QAAA,YAAY,GAAqD,IAAA,iBAAG,EAAA;;;wBAGzD,WAAW;;;;CAIlC,CAAC;AAKW,QAAA,WAAW,GAAoD,IAAA,iBAAG,EAAA;;;wBAGvD,WAAW;;;;CAIlC,CAAC"}
|