@coast/coast-api-client 2.0.17
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 +1 -0
- package/dist/lib/HeaderKeys.d.ts +3 -0
- package/dist/lib/HeaderKeys.js +8 -0
- package/dist/lib/HeaderKeys.js.map +1 -0
- package/dist/lib/coast-api/CoastApiClient.d.ts +54 -0
- package/dist/lib/coast-api/CoastApiClient.js +134 -0
- package/dist/lib/coast-api/CoastApiClient.js.map +1 -0
- package/dist/lib/coast-api/CoastApiClientGqlError.d.ts +12 -0
- package/dist/lib/coast-api/CoastApiClientGqlError.js +11 -0
- package/dist/lib/coast-api/CoastApiClientGqlError.js.map +1 -0
- package/dist/lib/coast-api/CoastApiOptions.d.ts +6 -0
- package/dist/lib/coast-api/CoastApiOptions.js +3 -0
- package/dist/lib/coast-api/CoastApiOptions.js.map +1 -0
- package/dist/lib/coast-api/CoastApiRequests.d.ts +90 -0
- package/dist/lib/coast-api/CoastApiRequests.js +316 -0
- package/dist/lib/coast-api/CoastApiRequests.js.map +1 -0
- package/dist/lib/coast-api/CoastCallOptions.d.ts +9 -0
- package/dist/lib/coast-api/CoastCallOptions.js +3 -0
- package/dist/lib/coast-api/CoastCallOptions.js.map +1 -0
- package/dist/lib/coast-api/WorkflowEntitiesGqlFields.d.ts +3 -0
- package/dist/lib/coast-api/WorkflowEntitiesGqlFields.js +14 -0
- package/dist/lib/coast-api/WorkflowEntitiesGqlFields.js.map +1 -0
- package/dist/lib/coast-api/WorkflowEntityGqlFields.d.ts +3 -0
- package/dist/lib/coast-api/WorkflowEntityGqlFields.js +15 -0
- package/dist/lib/coast-api/WorkflowEntityGqlFields.js.map +1 -0
- package/dist/lib/coast-api/WorkflowTemplateGqlFields.d.ts +3 -0
- package/dist/lib/coast-api/WorkflowTemplateGqlFields.js +130 -0
- package/dist/lib/coast-api/WorkflowTemplateGqlFields.js.map +1 -0
- package/dist/lib/graphql/GqlRequestBody.d.ts +8 -0
- package/dist/lib/graphql/GqlRequestBody.js +3 -0
- package/dist/lib/graphql/GqlRequestBody.js.map +1 -0
- package/dist/lib/graphql/GqlResponse.d.ts +14 -0
- package/dist/lib/graphql/GqlResponse.js +3 -0
- package/dist/lib/graphql/GqlResponse.js.map +1 -0
- package/dist/tsconfig.tsbuildinfo +1 -0
- package/package.json +58 -0
|
@@ -0,0 +1,316 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.CoastApiRequests = void 0;
|
|
4
|
+
const WorkflowEntitiesGqlFields_1 = require("./WorkflowEntitiesGqlFields");
|
|
5
|
+
const WorkflowEntityGqlFields_1 = require("./WorkflowEntityGqlFields");
|
|
6
|
+
const WorkflowTemplateGqlFields_1 = require("./WorkflowTemplateGqlFields");
|
|
7
|
+
class CoastApiRequests {
|
|
8
|
+
static aggregateRelatedCardQuantityStats(filter) {
|
|
9
|
+
return {
|
|
10
|
+
query: `
|
|
11
|
+
query ($input: AggregateRelatedCardQuantity!) {
|
|
12
|
+
aggregateRelatedCardQuantityStats(input: $input) {
|
|
13
|
+
count sum avg max min
|
|
14
|
+
}
|
|
15
|
+
}
|
|
16
|
+
`,
|
|
17
|
+
variables: { input: filter },
|
|
18
|
+
};
|
|
19
|
+
}
|
|
20
|
+
static createEntityAuditTrailEvent(createEntityAuditTrailEvent) {
|
|
21
|
+
return {
|
|
22
|
+
query: `
|
|
23
|
+
mutation ($input: CreateEntityAuditTrailEvent!) {
|
|
24
|
+
createEntityAuditTrailEvent(input: $input) { id }
|
|
25
|
+
}
|
|
26
|
+
`,
|
|
27
|
+
variables: { input: createEntityAuditTrailEvent },
|
|
28
|
+
};
|
|
29
|
+
}
|
|
30
|
+
static createSharedCardLink(createSharedCardLink) {
|
|
31
|
+
return {
|
|
32
|
+
query: `
|
|
33
|
+
mutation ($input: CreateSharedCardLink!) {
|
|
34
|
+
createSharedCardLink(input: $input) {
|
|
35
|
+
id
|
|
36
|
+
type
|
|
37
|
+
shortUrl
|
|
38
|
+
cardId
|
|
39
|
+
channelId
|
|
40
|
+
url
|
|
41
|
+
viewTemplateId
|
|
42
|
+
workflowTemplateId
|
|
43
|
+
fields
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
`,
|
|
47
|
+
variables: { input: createSharedCardLink },
|
|
48
|
+
};
|
|
49
|
+
}
|
|
50
|
+
static createUsers(createUsers) {
|
|
51
|
+
return {
|
|
52
|
+
query: `
|
|
53
|
+
mutation ($input: [CreateUserV2!]!) {
|
|
54
|
+
createUsersV2(input: $input) {
|
|
55
|
+
id
|
|
56
|
+
firstName
|
|
57
|
+
lastName
|
|
58
|
+
email
|
|
59
|
+
phoneNumber
|
|
60
|
+
createdAt
|
|
61
|
+
updatedAt
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
`,
|
|
65
|
+
variables: { input: createUsers },
|
|
66
|
+
};
|
|
67
|
+
}
|
|
68
|
+
static createWorkflowAutomationEvent(createWorkflowAutomationEvent) {
|
|
69
|
+
return {
|
|
70
|
+
query: `
|
|
71
|
+
mutation ($input: CreateWorkflowAutomationEvent!) {
|
|
72
|
+
createWorkflowAutomationEvent(input: $input)
|
|
73
|
+
}
|
|
74
|
+
`,
|
|
75
|
+
variables: { input: createWorkflowAutomationEvent },
|
|
76
|
+
};
|
|
77
|
+
}
|
|
78
|
+
static createWorkflowEntities(createWorkflowEntities) {
|
|
79
|
+
return {
|
|
80
|
+
query: `
|
|
81
|
+
mutation ($input: CreateWorkflowEntities!) {
|
|
82
|
+
createWorkflowEntities(input: $input) {
|
|
83
|
+
entities {
|
|
84
|
+
id
|
|
85
|
+
workflowTemplateId
|
|
86
|
+
fields
|
|
87
|
+
}
|
|
88
|
+
refs {
|
|
89
|
+
workflowEntityRefs {
|
|
90
|
+
id
|
|
91
|
+
}
|
|
92
|
+
personRefs {
|
|
93
|
+
id
|
|
94
|
+
}
|
|
95
|
+
workflowTemplateRefs {
|
|
96
|
+
id
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
}
|
|
100
|
+
}
|
|
101
|
+
`,
|
|
102
|
+
variables: { input: createWorkflowEntities },
|
|
103
|
+
};
|
|
104
|
+
}
|
|
105
|
+
static createWorkflowEntity(createWorkflowEntity) {
|
|
106
|
+
return {
|
|
107
|
+
query: `
|
|
108
|
+
mutation ($input: CreateWorkflowEntity!) {
|
|
109
|
+
createWorkflowEntity(input: $input) {
|
|
110
|
+
entity {
|
|
111
|
+
id
|
|
112
|
+
workflowTemplateId
|
|
113
|
+
fields
|
|
114
|
+
}
|
|
115
|
+
refs {
|
|
116
|
+
workflowEntityRefs {
|
|
117
|
+
id
|
|
118
|
+
}
|
|
119
|
+
personRefs {
|
|
120
|
+
id
|
|
121
|
+
}
|
|
122
|
+
workflowTemplateRefs {
|
|
123
|
+
id
|
|
124
|
+
}
|
|
125
|
+
}
|
|
126
|
+
}
|
|
127
|
+
}
|
|
128
|
+
`,
|
|
129
|
+
variables: { input: createWorkflowEntity },
|
|
130
|
+
};
|
|
131
|
+
}
|
|
132
|
+
static getCard(cardId) {
|
|
133
|
+
return {
|
|
134
|
+
query: `
|
|
135
|
+
query ($id: UUID!) {
|
|
136
|
+
getCard(id: $id) {
|
|
137
|
+
id
|
|
138
|
+
fields
|
|
139
|
+
}
|
|
140
|
+
}
|
|
141
|
+
`,
|
|
142
|
+
variables: { id: cardId },
|
|
143
|
+
};
|
|
144
|
+
}
|
|
145
|
+
static getChannel(channelId) {
|
|
146
|
+
return {
|
|
147
|
+
query: `
|
|
148
|
+
query ($id: Int!) {
|
|
149
|
+
getChannel(id: $id) {
|
|
150
|
+
id
|
|
151
|
+
name
|
|
152
|
+
slug
|
|
153
|
+
}
|
|
154
|
+
}
|
|
155
|
+
`,
|
|
156
|
+
variables: { id: channelId },
|
|
157
|
+
};
|
|
158
|
+
}
|
|
159
|
+
static getSamlUser(email, samlOrganizationId) {
|
|
160
|
+
return {
|
|
161
|
+
query: `
|
|
162
|
+
query ($input: GetSamlUser!) {
|
|
163
|
+
getSamlUser(input: $input) {
|
|
164
|
+
id
|
|
165
|
+
email
|
|
166
|
+
businessId
|
|
167
|
+
}
|
|
168
|
+
}
|
|
169
|
+
`,
|
|
170
|
+
variables: { input: { email, samlOrganizationId } },
|
|
171
|
+
};
|
|
172
|
+
}
|
|
173
|
+
static getWorkflowEntity(workflowEntityId) {
|
|
174
|
+
return {
|
|
175
|
+
query: `
|
|
176
|
+
query ($input: GetWorkflowEntity!) {
|
|
177
|
+
getWorkflowEntity(input: $input) {
|
|
178
|
+
${WorkflowEntityGqlFields_1.WorkflowEntityGqlFields.fields}
|
|
179
|
+
}
|
|
180
|
+
}
|
|
181
|
+
`,
|
|
182
|
+
variables: { input: { id: workflowEntityId } },
|
|
183
|
+
};
|
|
184
|
+
}
|
|
185
|
+
static getWorkflowTemplate(workflowTemplateId) {
|
|
186
|
+
return {
|
|
187
|
+
query: `
|
|
188
|
+
query ($id: UUID!) {
|
|
189
|
+
getWorkflowTemplate(id: $id) {
|
|
190
|
+
components {
|
|
191
|
+
${WorkflowTemplateGqlFields_1.WorkflowTemplateGqlFields.componentFields}
|
|
192
|
+
}
|
|
193
|
+
}
|
|
194
|
+
}
|
|
195
|
+
`,
|
|
196
|
+
variables: { id: workflowTemplateId },
|
|
197
|
+
};
|
|
198
|
+
}
|
|
199
|
+
static listWorkflowEntities(listWorkflowEntities) {
|
|
200
|
+
return {
|
|
201
|
+
query: `
|
|
202
|
+
query ($input: ListWorkflowEntities!) {
|
|
203
|
+
listWorkflowEntities(input: $input) {
|
|
204
|
+
${WorkflowEntitiesGqlFields_1.WorkflowEntitiesGqlFields.fields}
|
|
205
|
+
totalResults
|
|
206
|
+
hasMore
|
|
207
|
+
}
|
|
208
|
+
}
|
|
209
|
+
`,
|
|
210
|
+
variables: { input: listWorkflowEntities },
|
|
211
|
+
};
|
|
212
|
+
}
|
|
213
|
+
static listWorkflowEntitiesFormData(filter) {
|
|
214
|
+
return {
|
|
215
|
+
query: `
|
|
216
|
+
query ($input: ListEntitiesFormData!) {
|
|
217
|
+
listEntitiesFormData(input: $input) {
|
|
218
|
+
hasMore
|
|
219
|
+
totalResults
|
|
220
|
+
exports {
|
|
221
|
+
type
|
|
222
|
+
title
|
|
223
|
+
targetFormat
|
|
224
|
+
data {
|
|
225
|
+
... on ComponentDataExport {
|
|
226
|
+
label
|
|
227
|
+
value
|
|
228
|
+
imageUrls
|
|
229
|
+
type
|
|
230
|
+
}
|
|
231
|
+
... on SubformDataExport {
|
|
232
|
+
type
|
|
233
|
+
title
|
|
234
|
+
businessName
|
|
235
|
+
data {
|
|
236
|
+
... on ComponentDataExport {
|
|
237
|
+
label
|
|
238
|
+
value
|
|
239
|
+
imageUrls
|
|
240
|
+
type
|
|
241
|
+
}
|
|
242
|
+
}
|
|
243
|
+
}
|
|
244
|
+
}
|
|
245
|
+
businessName
|
|
246
|
+
url
|
|
247
|
+
}
|
|
248
|
+
}
|
|
249
|
+
}
|
|
250
|
+
`,
|
|
251
|
+
variables: { input: filter },
|
|
252
|
+
};
|
|
253
|
+
}
|
|
254
|
+
static updateCard(card) {
|
|
255
|
+
return {
|
|
256
|
+
query: `
|
|
257
|
+
mutation ($input: UpdateCard!) {
|
|
258
|
+
updateCard(input: $input) {
|
|
259
|
+
id
|
|
260
|
+
}
|
|
261
|
+
}
|
|
262
|
+
`,
|
|
263
|
+
variables: { input: card },
|
|
264
|
+
};
|
|
265
|
+
}
|
|
266
|
+
static updateUser(updateUser) {
|
|
267
|
+
return {
|
|
268
|
+
query: `
|
|
269
|
+
mutation ($input: UpdateUser!) {
|
|
270
|
+
updateUserV2(input: $input) {
|
|
271
|
+
id
|
|
272
|
+
}
|
|
273
|
+
}
|
|
274
|
+
`,
|
|
275
|
+
variables: { input: updateUser },
|
|
276
|
+
};
|
|
277
|
+
}
|
|
278
|
+
static updateWorkflowEntities(updateWorkflowEntities) {
|
|
279
|
+
return {
|
|
280
|
+
query: `
|
|
281
|
+
mutation ($input: UpdateWorkflowEntities!) {
|
|
282
|
+
updateWorkflowEntities(input: $input) {
|
|
283
|
+
${WorkflowEntitiesGqlFields_1.WorkflowEntitiesGqlFields.fields}
|
|
284
|
+
}
|
|
285
|
+
}
|
|
286
|
+
`,
|
|
287
|
+
variables: { input: updateWorkflowEntities },
|
|
288
|
+
};
|
|
289
|
+
}
|
|
290
|
+
static updateWorkflowEntity(updateWorkflowEntity) {
|
|
291
|
+
return {
|
|
292
|
+
query: `
|
|
293
|
+
mutation ($input: UpdateWorkflowEntity!) {
|
|
294
|
+
updateWorkflowEntity(input: $input) {
|
|
295
|
+
${WorkflowEntityGqlFields_1.WorkflowEntityGqlFields.fields}
|
|
296
|
+
}
|
|
297
|
+
}
|
|
298
|
+
`,
|
|
299
|
+
variables: { input: updateWorkflowEntity },
|
|
300
|
+
};
|
|
301
|
+
}
|
|
302
|
+
static updateWorkflowTemplate(updateWorkflowTemplate) {
|
|
303
|
+
return {
|
|
304
|
+
query: `
|
|
305
|
+
mutation ($input: UpdateWorkflowTemplate!) {
|
|
306
|
+
updateWorkflowTemplate(input: $input) {
|
|
307
|
+
id
|
|
308
|
+
}
|
|
309
|
+
}
|
|
310
|
+
`,
|
|
311
|
+
variables: { input: updateWorkflowTemplate },
|
|
312
|
+
};
|
|
313
|
+
}
|
|
314
|
+
}
|
|
315
|
+
exports.CoastApiRequests = CoastApiRequests;
|
|
316
|
+
//# sourceMappingURL=CoastApiRequests.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"CoastApiRequests.js","sourceRoot":"","sources":["../../../lib/coast-api/CoastApiRequests.ts"],"names":[],"mappings":";;;AA6BA,2EAAwE;AACxE,uEAAoE;AACpE,2EAAwE;AAExE,MAAa,gBAAgB;IACzB,MAAM,CAAC,iCAAiC,CACpC,MAAoC;QAEpC,OAAO;YACH,KAAK,EAAE;;;;;;aAMN;YACD,SAAS,EAAE,EAAE,KAAK,EAAE,MAAM,EAAE;SAC/B,CAAC;IACN,CAAC;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AAE,KAAK,EAAE,UAAU,EAAE;SACnC,CAAC;IACN,CAAC;IAED,MAAM,CAAC,sBAAsB,CACzB,sBAA8C;QAE9C,OAAO;YACH,KAAK,EAAE;;;0BAGO,qDAAyB,CAAC,MAAM;;;aAG7C;YACD,SAAS,EAAE,EAAE,KAAK,EAAE,sBAAsB,EAAE;SAC/C,CAAC;IACN,CAAC;IAED,MAAM,CAAC,oBAAoB,CACvB,oBAA0C;QAE1C,OAAO;YACH,KAAK,EAAE;;;0BAGO,iDAAuB,CAAC,MAAM;;;aAG3C;YACD,SAAS,EAAE,EAAE,KAAK,EAAE,oBAAoB,EAAE;SAC7C,CAAC;IACN,CAAC;IAED,MAAM,CAAC,sBAAsB,CACzB,sBAA8C;QAE9C,OAAO;YACH,KAAK,EAAE;;;;;;aAMN;YACD,SAAS,EAAE,EAAE,KAAK,EAAE,sBAAsB,EAAE;SAC/C,CAAC;IACN,CAAC;CACJ;AAhWD,4CAgWC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { AutomationId } from '@coast/core-api-types/automations/AutomationId';
|
|
2
|
+
import { BusinessId } from '@coast/core-api-types/business/BusinessId';
|
|
3
|
+
import { CoastExecutionContext } from '@coast/core-api-types/execution/CoastExecutionContext';
|
|
4
|
+
export interface CoastCallOptions {
|
|
5
|
+
businessId: BusinessId;
|
|
6
|
+
businessIdOverride?: BusinessId;
|
|
7
|
+
executionContext?: CoastExecutionContext;
|
|
8
|
+
sourceAutomationId?: AutomationId;
|
|
9
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"CoastCallOptions.js","sourceRoot":"","sources":["../../../lib/coast-api/CoastCallOptions.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.WorkflowEntitiesGqlFields = void 0;
|
|
4
|
+
exports.WorkflowEntitiesGqlFields = {
|
|
5
|
+
fields: `
|
|
6
|
+
entities { id fields workflowTemplateId }
|
|
7
|
+
refs {
|
|
8
|
+
workflowEntityRefs { id }
|
|
9
|
+
personRefs { id }
|
|
10
|
+
workflowTemplateRefs { id }
|
|
11
|
+
}
|
|
12
|
+
`,
|
|
13
|
+
};
|
|
14
|
+
//# sourceMappingURL=WorkflowEntitiesGqlFields.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"WorkflowEntitiesGqlFields.js","sourceRoot":"","sources":["../../../lib/coast-api/WorkflowEntitiesGqlFields.ts"],"names":[],"mappings":";;;AAAa,QAAA,yBAAyB,GAAG;IACrC,MAAM,EAAE;;;;;;;KAOP;CACJ,CAAC"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.WorkflowEntityGqlFields = void 0;
|
|
4
|
+
const WorkflowTemplateGqlFields_1 = require("./WorkflowTemplateGqlFields");
|
|
5
|
+
exports.WorkflowEntityGqlFields = {
|
|
6
|
+
fields: `
|
|
7
|
+
entity { id workflowTemplateId fields }
|
|
8
|
+
refs {
|
|
9
|
+
workflowEntityRefs { id workflowTemplateId fields }
|
|
10
|
+
personRefs { id }
|
|
11
|
+
workflowTemplateRefs { id components { ${WorkflowTemplateGqlFields_1.WorkflowTemplateGqlFields.componentFields} } }
|
|
12
|
+
}
|
|
13
|
+
`,
|
|
14
|
+
};
|
|
15
|
+
//# sourceMappingURL=WorkflowEntityGqlFields.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"WorkflowEntityGqlFields.js","sourceRoot":"","sources":["../../../lib/coast-api/WorkflowEntityGqlFields.ts"],"names":[],"mappings":";;;AAAA,2EAAwE;AAE3D,QAAA,uBAAuB,GAAG;IACnC,MAAM,EAAE;;;;;qDAKyC,qDAAyB,CAAC,eAAe;;KAEzF;CACJ,CAAC"}
|
|
@@ -0,0 +1,130 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.WorkflowTemplateGqlFields = void 0;
|
|
4
|
+
const inputComponentFields = [
|
|
5
|
+
'id',
|
|
6
|
+
'type',
|
|
7
|
+
'label',
|
|
8
|
+
'placeholder',
|
|
9
|
+
'readonly',
|
|
10
|
+
'required',
|
|
11
|
+
'isFilterable',
|
|
12
|
+
'isSortable',
|
|
13
|
+
'isServerManaged',
|
|
14
|
+
];
|
|
15
|
+
exports.WorkflowTemplateGqlFields = {
|
|
16
|
+
componentFields: `
|
|
17
|
+
... on AddressComponent {
|
|
18
|
+
${inputComponentFields.join(' ')}
|
|
19
|
+
}
|
|
20
|
+
... on AuditCheckboxComponent {
|
|
21
|
+
${inputComponentFields.join(' ')}
|
|
22
|
+
}
|
|
23
|
+
... on AuditTagComponent {
|
|
24
|
+
${inputComponentFields.join(' ')}
|
|
25
|
+
multiselect
|
|
26
|
+
options { label value archived }
|
|
27
|
+
}
|
|
28
|
+
... on AuditTextComponent {
|
|
29
|
+
${inputComponentFields.join(' ')}
|
|
30
|
+
maxlength
|
|
31
|
+
multiline
|
|
32
|
+
}
|
|
33
|
+
... on CombinedTagsComponent {
|
|
34
|
+
id
|
|
35
|
+
type
|
|
36
|
+
label
|
|
37
|
+
icon
|
|
38
|
+
locked
|
|
39
|
+
isServerManaged
|
|
40
|
+
componentIds
|
|
41
|
+
}
|
|
42
|
+
... on DateComponent {
|
|
43
|
+
${inputComponentFields.join(' ')}
|
|
44
|
+
}
|
|
45
|
+
... on EmailComponent {
|
|
46
|
+
${inputComponentFields.join(' ')}
|
|
47
|
+
default { value }
|
|
48
|
+
}
|
|
49
|
+
... on FileComponent {
|
|
50
|
+
${inputComponentFields.join(' ')}
|
|
51
|
+
acceptedContentTypes
|
|
52
|
+
}
|
|
53
|
+
... on GeolocationComponent {
|
|
54
|
+
${inputComponentFields.join(' ')}
|
|
55
|
+
}
|
|
56
|
+
... on InputButtonComponent {
|
|
57
|
+
id
|
|
58
|
+
type
|
|
59
|
+
locked
|
|
60
|
+
isServerManaged
|
|
61
|
+
buttonText
|
|
62
|
+
inputComponentId
|
|
63
|
+
}
|
|
64
|
+
... on NumberComponent {
|
|
65
|
+
${inputComponentFields.join(' ')}
|
|
66
|
+
format
|
|
67
|
+
}
|
|
68
|
+
... on PersonComponent {
|
|
69
|
+
${inputComponentFields.join(' ')}
|
|
70
|
+
default { token userIds }
|
|
71
|
+
}
|
|
72
|
+
... on RelatedCardComponent {
|
|
73
|
+
${inputComponentFields.join(' ')}
|
|
74
|
+
workflowTemplateId
|
|
75
|
+
default { cardIds }
|
|
76
|
+
listDefault {
|
|
77
|
+
sortByComponents { componentId direction }
|
|
78
|
+
filterByComponents {
|
|
79
|
+
componentId
|
|
80
|
+
value {
|
|
81
|
+
containsCurrentUser { value }
|
|
82
|
+
containsNumber { values }
|
|
83
|
+
containsString { values }
|
|
84
|
+
dateRange { before after }
|
|
85
|
+
dateTokenIs { value }
|
|
86
|
+
isEmpty { value }
|
|
87
|
+
numberIs { value }
|
|
88
|
+
stringWildcard { value }
|
|
89
|
+
}
|
|
90
|
+
}
|
|
91
|
+
omniSearchQuery
|
|
92
|
+
limit
|
|
93
|
+
offset
|
|
94
|
+
}
|
|
95
|
+
}
|
|
96
|
+
... on RelatedCardLookupComponent {
|
|
97
|
+
${inputComponentFields.join(' ')}
|
|
98
|
+
relatedCardComponentId
|
|
99
|
+
lookupWorkflowTemplateId
|
|
100
|
+
lookupComponentId
|
|
101
|
+
}
|
|
102
|
+
... on SignatureComponent {
|
|
103
|
+
${inputComponentFields.join(' ')}
|
|
104
|
+
}
|
|
105
|
+
... on StaticTextComponent {
|
|
106
|
+
id type text
|
|
107
|
+
}
|
|
108
|
+
... on SubformComponent {
|
|
109
|
+
${inputComponentFields.join(' ')}
|
|
110
|
+
workflowTemplateIds
|
|
111
|
+
default { workflowTemplateId }
|
|
112
|
+
}
|
|
113
|
+
... on TagComponent {
|
|
114
|
+
${inputComponentFields.join(' ')}
|
|
115
|
+
multiselect
|
|
116
|
+
options { label value archived }
|
|
117
|
+
default { value }
|
|
118
|
+
}
|
|
119
|
+
... on TextComponent {
|
|
120
|
+
${inputComponentFields.join(' ')}
|
|
121
|
+
maxlength
|
|
122
|
+
multiline
|
|
123
|
+
default { text }
|
|
124
|
+
}
|
|
125
|
+
... on TodoComponent {
|
|
126
|
+
${inputComponentFields.join(' ')}
|
|
127
|
+
}
|
|
128
|
+
`,
|
|
129
|
+
};
|
|
130
|
+
//# sourceMappingURL=WorkflowTemplateGqlFields.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"WorkflowTemplateGqlFields.js","sourceRoot":"","sources":["../../../lib/coast-api/WorkflowTemplateGqlFields.ts"],"names":[],"mappings":";;;AAEA,MAAM,oBAAoB,GAA+C;IACrE,IAAI;IACJ,MAAM;IACN,OAAO;IACP,aAAa;IACb,UAAU;IACV,UAAU;IACV,cAAc;IACd,YAAY;IACZ,iBAAiB;CACpB,CAAC;AAEW,QAAA,yBAAyB,GAAG;IACrC,eAAe,EAAE;;cAEP,oBAAoB,CAAC,IAAI,CAAC,GAAG,CAAC;;;cAG9B,oBAAoB,CAAC,IAAI,CAAC,GAAG,CAAC;;;cAG9B,oBAAoB,CAAC,IAAI,CAAC,GAAG,CAAC;;;;;cAK9B,oBAAoB,CAAC,IAAI,CAAC,GAAG,CAAC;;;;;;;;;;;;;;cAc9B,oBAAoB,CAAC,IAAI,CAAC,GAAG,CAAC;;;cAG9B,oBAAoB,CAAC,IAAI,CAAC,GAAG,CAAC;;;;cAI9B,oBAAoB,CAAC,IAAI,CAAC,GAAG,CAAC;;;;cAI9B,oBAAoB,CAAC,IAAI,CAAC,GAAG,CAAC;;;;;;;;;;;cAW9B,oBAAoB,CAAC,IAAI,CAAC,GAAG,CAAC;;;;cAI9B,oBAAoB,CAAC,IAAI,CAAC,GAAG,CAAC;;;;cAI9B,oBAAoB,CAAC,IAAI,CAAC,GAAG,CAAC;;;;;;;;;;;;;;;;;;;;;;;;cAwB9B,oBAAoB,CAAC,IAAI,CAAC,GAAG,CAAC;;;;;;cAM9B,oBAAoB,CAAC,IAAI,CAAC,GAAG,CAAC;;;;;;cAM9B,oBAAoB,CAAC,IAAI,CAAC,GAAG,CAAC;;;;;cAK9B,oBAAoB,CAAC,IAAI,CAAC,GAAG,CAAC;;;;;;cAM9B,oBAAoB,CAAC,IAAI,CAAC,GAAG,CAAC;;;;;;cAM9B,oBAAoB,CAAC,IAAI,CAAC,GAAG,CAAC;;SAEnC;CACR,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"GqlRequestBody.js","sourceRoot":"","sources":["../../../lib/graphql/GqlRequestBody.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { Response } from 'superagent';
|
|
2
|
+
export type GqlResponse<T> = Omit<Response, 'body'> & {
|
|
3
|
+
body: TypedBody<T>;
|
|
4
|
+
};
|
|
5
|
+
interface TypedBody<T> {
|
|
6
|
+
data: T;
|
|
7
|
+
errors?: {
|
|
8
|
+
extensions?: {
|
|
9
|
+
code: number;
|
|
10
|
+
};
|
|
11
|
+
message: string;
|
|
12
|
+
}[];
|
|
13
|
+
}
|
|
14
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"GqlResponse.js","sourceRoot":"","sources":["../../../lib/graphql/GqlResponse.ts"],"names":[],"mappings":""}
|