@wix/auto_sdk_crm_pipelines 1.0.0 → 1.0.1
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/build/cjs/index.d.ts +76 -130
- package/build/cjs/index.js +194 -977
- package/build/cjs/index.js.map +1 -1
- package/build/cjs/index.typings.d.ts +998 -15
- package/build/cjs/index.typings.js +146 -767
- package/build/cjs/index.typings.js.map +1 -1
- package/build/cjs/meta.d.ts +133 -1005
- package/build/cjs/meta.js +128 -682
- package/build/cjs/meta.js.map +1 -1
- package/build/es/index.d.mts +76 -130
- package/build/es/index.mjs +184 -947
- package/build/es/index.mjs.map +1 -1
- package/build/es/index.typings.d.mts +998 -15
- package/build/es/index.typings.mjs +138 -743
- package/build/es/index.typings.mjs.map +1 -1
- package/build/es/meta.d.mts +133 -1005
- package/build/es/meta.mjs +121 -659
- package/build/es/meta.mjs.map +1 -1
- package/build/internal/cjs/index.d.ts +76 -163
- package/build/internal/cjs/index.js +194 -977
- package/build/internal/cjs/index.js.map +1 -1
- package/build/internal/cjs/index.typings.d.ts +998 -15
- package/build/internal/cjs/index.typings.js +146 -767
- package/build/internal/cjs/index.typings.js.map +1 -1
- package/build/internal/cjs/meta.d.ts +133 -1005
- package/build/internal/cjs/meta.js +128 -682
- package/build/internal/cjs/meta.js.map +1 -1
- package/build/internal/es/index.d.mts +76 -163
- package/build/internal/es/index.mjs +184 -947
- package/build/internal/es/index.mjs.map +1 -1
- package/build/internal/es/index.typings.d.mts +998 -15
- package/build/internal/es/index.typings.mjs +138 -743
- package/build/internal/es/index.typings.mjs.map +1 -1
- package/build/internal/es/meta.d.mts +133 -1005
- package/build/internal/es/meta.mjs +121 -659
- package/build/internal/es/meta.mjs.map +1 -1
- package/package.json +3 -3
- package/build/cjs/crm-pipelines-v1-card-pipelines.universal-DGtqU_Zb.d.ts +0 -2265
- package/build/es/crm-pipelines-v1-card-pipelines.universal-DGtqU_Zb.d.mts +0 -2265
- package/build/internal/cjs/crm-pipelines-v1-card-pipelines.universal-BHszxzqA.d.ts +0 -2303
- package/build/internal/es/crm-pipelines-v1-card-pipelines.universal-BHszxzqA.d.mts +0 -2303
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
// src/crm-pipelines-v1-
|
|
1
|
+
// src/crm-pipelines-v1-pipeline-pipelines.universal.ts
|
|
2
2
|
import { transformError as sdkTransformError } from "@wix/sdk-runtime/transform-error";
|
|
3
3
|
import { queryBuilder } from "@wix/sdk-runtime/query-builder";
|
|
4
4
|
import {
|
|
@@ -6,94 +6,88 @@ import {
|
|
|
6
6
|
renameKeysFromRESTResponseToSDKResponse
|
|
7
7
|
} from "@wix/sdk-runtime/rename-all-nested-keys";
|
|
8
8
|
|
|
9
|
-
// src/crm-pipelines-v1-
|
|
9
|
+
// src/crm-pipelines-v1-pipeline-pipelines.http.ts
|
|
10
10
|
import { toURLSearchParams } from "@wix/sdk-runtime/rest-modules";
|
|
11
|
-
import { transformSDKFloatToRESTFloat } from "@wix/sdk-runtime/transformations/float";
|
|
12
|
-
import { transformRESTFloatToSDKFloat } from "@wix/sdk-runtime/transformations/float";
|
|
13
11
|
import { transformSDKTimestampToRESTTimestamp } from "@wix/sdk-runtime/transformations/timestamp";
|
|
14
12
|
import { transformRESTTimestampToSDKTimestamp } from "@wix/sdk-runtime/transformations/timestamp";
|
|
15
13
|
import { transformSDKFieldMaskToRESTFieldMask } from "@wix/sdk-runtime/transformations/field-mask";
|
|
16
14
|
import { transformPaths } from "@wix/sdk-runtime/transformations/transform-paths";
|
|
17
15
|
import { resolveUrl } from "@wix/sdk-runtime/rest-modules";
|
|
18
|
-
function
|
|
16
|
+
function resolveWixCrmPipelinesPipelinesV1PipelinesUrl(opts) {
|
|
19
17
|
const domainToMappings = {
|
|
20
18
|
"manage._base_domain_": [
|
|
21
19
|
{
|
|
22
|
-
srcPath: "/_api/
|
|
23
|
-
destPath: "/v1/
|
|
20
|
+
srcPath: "/_api/pipelines-app/v1/pipelines",
|
|
21
|
+
destPath: "/v1/pipelines"
|
|
24
22
|
},
|
|
25
23
|
{
|
|
26
|
-
srcPath: "/_api/
|
|
27
|
-
destPath: "/v1/bulk/
|
|
24
|
+
srcPath: "/_api/pipelines-app/v1/bulk/pipelines/",
|
|
25
|
+
destPath: "/v1/bulk/pipelines/"
|
|
28
26
|
},
|
|
29
27
|
{
|
|
30
|
-
srcPath: "/_api/
|
|
31
|
-
destPath: "/v1/
|
|
28
|
+
srcPath: "/_api/pipelines/v1/pipelines",
|
|
29
|
+
destPath: "/v1/pipelines"
|
|
32
30
|
},
|
|
33
31
|
{
|
|
34
|
-
srcPath: "/_api/
|
|
35
|
-
destPath: "/v1/bulk/
|
|
32
|
+
srcPath: "/_api/pipelines/v1/bulk/pipelines",
|
|
33
|
+
destPath: "/v1/bulk/pipelines"
|
|
36
34
|
}
|
|
37
35
|
],
|
|
38
36
|
_: [
|
|
39
37
|
{
|
|
40
|
-
srcPath: "/_api/
|
|
41
|
-
destPath: "/v1/
|
|
38
|
+
srcPath: "/_api/pipelines/v1/pipelines",
|
|
39
|
+
destPath: "/v1/pipelines"
|
|
42
40
|
},
|
|
43
41
|
{
|
|
44
|
-
srcPath: "/_api/
|
|
45
|
-
destPath: "/v1/bulk/
|
|
42
|
+
srcPath: "/_api/pipelines/v1/bulk/pipelines",
|
|
43
|
+
destPath: "/v1/bulk/pipelines"
|
|
46
44
|
}
|
|
47
45
|
],
|
|
48
46
|
"*.dev.wix-code.com": [
|
|
49
47
|
{
|
|
50
|
-
srcPath: "/_api/
|
|
51
|
-
destPath: "/v1/
|
|
48
|
+
srcPath: "/_api/pipelines/v1/pipelines",
|
|
49
|
+
destPath: "/v1/pipelines"
|
|
52
50
|
},
|
|
53
51
|
{
|
|
54
|
-
srcPath: "/_api/
|
|
55
|
-
destPath: "/v1/bulk/
|
|
52
|
+
srcPath: "/_api/pipelines/v1/bulk/pipelines",
|
|
53
|
+
destPath: "/v1/bulk/pipelines"
|
|
56
54
|
}
|
|
57
55
|
],
|
|
58
56
|
"www.wixapis.com": [
|
|
59
57
|
{
|
|
60
|
-
srcPath: "/crm/pipelines/v1/
|
|
61
|
-
destPath: "/v1/
|
|
58
|
+
srcPath: "/crm/pipelines/v1/pipelines",
|
|
59
|
+
destPath: "/v1/pipelines"
|
|
62
60
|
},
|
|
63
61
|
{
|
|
64
|
-
srcPath: "/crm/pipelines/v1/bulk/
|
|
65
|
-
destPath: "/v1/bulk/
|
|
62
|
+
srcPath: "/crm/pipelines/v1/bulk/pipelines",
|
|
63
|
+
destPath: "/v1/bulk/pipelines"
|
|
66
64
|
}
|
|
67
65
|
]
|
|
68
66
|
};
|
|
69
67
|
return resolveUrl(Object.assign(opts, { domainToMappings }));
|
|
70
68
|
}
|
|
71
69
|
var PACKAGE_NAME = "@wix/auto_sdk_crm_pipelines";
|
|
72
|
-
function
|
|
73
|
-
function
|
|
70
|
+
function createPipeline(payload) {
|
|
71
|
+
function __createPipeline({ host }) {
|
|
74
72
|
const serializedData = transformPaths(payload, [
|
|
75
73
|
{
|
|
76
74
|
transformFn: transformSDKTimestampToRESTTimestamp,
|
|
77
75
|
paths: [
|
|
78
|
-
{ path: "
|
|
79
|
-
{ path: "
|
|
80
|
-
{ path: "card.stageUpdatedDate" },
|
|
81
|
-
{ path: "card.dueDate" },
|
|
82
|
-
{ path: "card.staleDate" },
|
|
83
|
-
{ path: "card.linkedEntities.linkedDate" }
|
|
76
|
+
{ path: "pipeline.createdDate" },
|
|
77
|
+
{ path: "pipeline.updatedDate" }
|
|
84
78
|
]
|
|
85
79
|
}
|
|
86
80
|
]);
|
|
87
81
|
const metadata = {
|
|
88
|
-
entityFqdn: "wix.crm.pipelines.v1.
|
|
82
|
+
entityFqdn: "wix.crm.pipelines.v1.pipeline",
|
|
89
83
|
method: "POST",
|
|
90
|
-
methodFqn: "wix.crm.pipelines.
|
|
84
|
+
methodFqn: "wix.crm.pipelines.pipelines.v1.Pipelines.CreatePipeline",
|
|
91
85
|
packageName: PACKAGE_NAME,
|
|
92
86
|
migrationOptions: {
|
|
93
87
|
optInTransformResponse: true
|
|
94
88
|
},
|
|
95
|
-
url:
|
|
96
|
-
protoPath: "/v1/
|
|
89
|
+
url: resolveWixCrmPipelinesPipelinesV1PipelinesUrl({
|
|
90
|
+
protoPath: "/v1/pipelines",
|
|
97
91
|
data: serializedData,
|
|
98
92
|
host
|
|
99
93
|
}),
|
|
@@ -102,32 +96,28 @@ function createCard(payload) {
|
|
|
102
96
|
{
|
|
103
97
|
transformFn: transformRESTTimestampToSDKTimestamp,
|
|
104
98
|
paths: [
|
|
105
|
-
{ path: "
|
|
106
|
-
{ path: "
|
|
107
|
-
{ path: "card.stageUpdatedDate" },
|
|
108
|
-
{ path: "card.dueDate" },
|
|
109
|
-
{ path: "card.staleDate" },
|
|
110
|
-
{ path: "card.linkedEntities.linkedDate" }
|
|
99
|
+
{ path: "pipeline.createdDate" },
|
|
100
|
+
{ path: "pipeline.updatedDate" }
|
|
111
101
|
]
|
|
112
102
|
}
|
|
113
103
|
])
|
|
114
104
|
};
|
|
115
105
|
return metadata;
|
|
116
106
|
}
|
|
117
|
-
return
|
|
107
|
+
return __createPipeline;
|
|
118
108
|
}
|
|
119
|
-
function
|
|
120
|
-
function
|
|
109
|
+
function getPipeline(payload) {
|
|
110
|
+
function __getPipeline({ host }) {
|
|
121
111
|
const metadata = {
|
|
122
|
-
entityFqdn: "wix.crm.pipelines.v1.
|
|
112
|
+
entityFqdn: "wix.crm.pipelines.v1.pipeline",
|
|
123
113
|
method: "GET",
|
|
124
|
-
methodFqn: "wix.crm.pipelines.
|
|
114
|
+
methodFqn: "wix.crm.pipelines.pipelines.v1.Pipelines.GetPipeline",
|
|
125
115
|
packageName: PACKAGE_NAME,
|
|
126
116
|
migrationOptions: {
|
|
127
117
|
optInTransformResponse: true
|
|
128
118
|
},
|
|
129
|
-
url:
|
|
130
|
-
protoPath: "/v1/
|
|
119
|
+
url: resolveWixCrmPipelinesPipelinesV1PipelinesUrl({
|
|
120
|
+
protoPath: "/v1/pipelines/{pipelineId}",
|
|
131
121
|
data: payload,
|
|
132
122
|
host
|
|
133
123
|
}),
|
|
@@ -136,22 +126,18 @@ function getCard(payload) {
|
|
|
136
126
|
{
|
|
137
127
|
transformFn: transformRESTTimestampToSDKTimestamp,
|
|
138
128
|
paths: [
|
|
139
|
-
{ path: "
|
|
140
|
-
{ path: "
|
|
141
|
-
{ path: "card.stageUpdatedDate" },
|
|
142
|
-
{ path: "card.dueDate" },
|
|
143
|
-
{ path: "card.staleDate" },
|
|
144
|
-
{ path: "card.linkedEntities.linkedDate" }
|
|
129
|
+
{ path: "pipeline.createdDate" },
|
|
130
|
+
{ path: "pipeline.updatedDate" }
|
|
145
131
|
]
|
|
146
132
|
}
|
|
147
133
|
])
|
|
148
134
|
};
|
|
149
135
|
return metadata;
|
|
150
136
|
}
|
|
151
|
-
return
|
|
137
|
+
return __getPipeline;
|
|
152
138
|
}
|
|
153
|
-
function
|
|
154
|
-
function
|
|
139
|
+
function updatePipeline(payload) {
|
|
140
|
+
function __updatePipeline({ host }) {
|
|
155
141
|
const serializedData = transformPaths(payload, [
|
|
156
142
|
{
|
|
157
143
|
transformFn: transformSDKFieldMaskToRESTFieldMask,
|
|
@@ -160,25 +146,21 @@ function updateCard(payload) {
|
|
|
160
146
|
{
|
|
161
147
|
transformFn: transformSDKTimestampToRESTTimestamp,
|
|
162
148
|
paths: [
|
|
163
|
-
{ path: "
|
|
164
|
-
{ path: "
|
|
165
|
-
{ path: "card.stageUpdatedDate" },
|
|
166
|
-
{ path: "card.dueDate" },
|
|
167
|
-
{ path: "card.staleDate" },
|
|
168
|
-
{ path: "card.linkedEntities.linkedDate" }
|
|
149
|
+
{ path: "pipeline.createdDate" },
|
|
150
|
+
{ path: "pipeline.updatedDate" }
|
|
169
151
|
]
|
|
170
152
|
}
|
|
171
153
|
]);
|
|
172
154
|
const metadata = {
|
|
173
|
-
entityFqdn: "wix.crm.pipelines.v1.
|
|
155
|
+
entityFqdn: "wix.crm.pipelines.v1.pipeline",
|
|
174
156
|
method: "PATCH",
|
|
175
|
-
methodFqn: "wix.crm.pipelines.
|
|
157
|
+
methodFqn: "wix.crm.pipelines.pipelines.v1.Pipelines.UpdatePipeline",
|
|
176
158
|
packageName: PACKAGE_NAME,
|
|
177
159
|
migrationOptions: {
|
|
178
160
|
optInTransformResponse: true
|
|
179
161
|
},
|
|
180
|
-
url:
|
|
181
|
-
protoPath: "/v1/
|
|
162
|
+
url: resolveWixCrmPipelinesPipelinesV1PipelinesUrl({
|
|
163
|
+
protoPath: "/v1/pipelines/{pipeline.id}",
|
|
182
164
|
data: serializedData,
|
|
183
165
|
host
|
|
184
166
|
}),
|
|
@@ -187,66 +169,28 @@ function updateCard(payload) {
|
|
|
187
169
|
{
|
|
188
170
|
transformFn: transformRESTTimestampToSDKTimestamp,
|
|
189
171
|
paths: [
|
|
190
|
-
{ path: "
|
|
191
|
-
{ path: "
|
|
192
|
-
{ path: "card.stageUpdatedDate" },
|
|
193
|
-
{ path: "card.dueDate" },
|
|
194
|
-
{ path: "card.staleDate" },
|
|
195
|
-
{ path: "card.linkedEntities.linkedDate" }
|
|
172
|
+
{ path: "pipeline.createdDate" },
|
|
173
|
+
{ path: "pipeline.updatedDate" }
|
|
196
174
|
]
|
|
197
175
|
}
|
|
198
176
|
])
|
|
199
177
|
};
|
|
200
178
|
return metadata;
|
|
201
179
|
}
|
|
202
|
-
return
|
|
180
|
+
return __updatePipeline;
|
|
203
181
|
}
|
|
204
|
-
function
|
|
205
|
-
function
|
|
182
|
+
function deletePipeline(payload) {
|
|
183
|
+
function __deletePipeline({ host }) {
|
|
206
184
|
const metadata = {
|
|
207
|
-
entityFqdn: "wix.crm.pipelines.v1.
|
|
208
|
-
method: "PATCH",
|
|
209
|
-
methodFqn: "wix.crm.pipelines.cards.v1.Cards.MoveCard",
|
|
210
|
-
packageName: PACKAGE_NAME,
|
|
211
|
-
migrationOptions: {
|
|
212
|
-
optInTransformResponse: true
|
|
213
|
-
},
|
|
214
|
-
url: resolveWixCrmPipelinesCardsV1CardsUrl({
|
|
215
|
-
protoPath: "/v1/cards/move/{cardId}",
|
|
216
|
-
data: payload,
|
|
217
|
-
host
|
|
218
|
-
}),
|
|
219
|
-
data: payload,
|
|
220
|
-
transformResponse: (payload2) => transformPaths(payload2, [
|
|
221
|
-
{
|
|
222
|
-
transformFn: transformRESTTimestampToSDKTimestamp,
|
|
223
|
-
paths: [
|
|
224
|
-
{ path: "card.createdDate" },
|
|
225
|
-
{ path: "card.updatedDate" },
|
|
226
|
-
{ path: "card.stageUpdatedDate" },
|
|
227
|
-
{ path: "card.dueDate" },
|
|
228
|
-
{ path: "card.staleDate" },
|
|
229
|
-
{ path: "card.linkedEntities.linkedDate" }
|
|
230
|
-
]
|
|
231
|
-
}
|
|
232
|
-
])
|
|
233
|
-
};
|
|
234
|
-
return metadata;
|
|
235
|
-
}
|
|
236
|
-
return __moveCard;
|
|
237
|
-
}
|
|
238
|
-
function deleteCard(payload) {
|
|
239
|
-
function __deleteCard({ host }) {
|
|
240
|
-
const metadata = {
|
|
241
|
-
entityFqdn: "wix.crm.pipelines.v1.card",
|
|
185
|
+
entityFqdn: "wix.crm.pipelines.v1.pipeline",
|
|
242
186
|
method: "DELETE",
|
|
243
|
-
methodFqn: "wix.crm.pipelines.
|
|
187
|
+
methodFqn: "wix.crm.pipelines.pipelines.v1.Pipelines.DeletePipeline",
|
|
244
188
|
packageName: PACKAGE_NAME,
|
|
245
189
|
migrationOptions: {
|
|
246
190
|
optInTransformResponse: true
|
|
247
191
|
},
|
|
248
|
-
url:
|
|
249
|
-
protoPath: "/v1/
|
|
192
|
+
url: resolveWixCrmPipelinesPipelinesV1PipelinesUrl({
|
|
193
|
+
protoPath: "/v1/pipelines/{pipelineId}",
|
|
250
194
|
data: payload,
|
|
251
195
|
host
|
|
252
196
|
}),
|
|
@@ -254,20 +198,20 @@ function deleteCard(payload) {
|
|
|
254
198
|
};
|
|
255
199
|
return metadata;
|
|
256
200
|
}
|
|
257
|
-
return
|
|
201
|
+
return __deletePipeline;
|
|
258
202
|
}
|
|
259
|
-
function
|
|
260
|
-
function
|
|
203
|
+
function queryPipelines(payload) {
|
|
204
|
+
function __queryPipelines({ host }) {
|
|
261
205
|
const metadata = {
|
|
262
|
-
entityFqdn: "wix.crm.pipelines.v1.
|
|
206
|
+
entityFqdn: "wix.crm.pipelines.v1.pipeline",
|
|
263
207
|
method: "GET",
|
|
264
|
-
methodFqn: "wix.crm.pipelines.
|
|
208
|
+
methodFqn: "wix.crm.pipelines.pipelines.v1.Pipelines.QueryPipelines",
|
|
265
209
|
packageName: PACKAGE_NAME,
|
|
266
210
|
migrationOptions: {
|
|
267
211
|
optInTransformResponse: true
|
|
268
212
|
},
|
|
269
|
-
url:
|
|
270
|
-
protoPath: "/v1/
|
|
213
|
+
url: resolveWixCrmPipelinesPipelinesV1PipelinesUrl({
|
|
214
|
+
protoPath: "/v1/pipelines/query",
|
|
271
215
|
data: payload,
|
|
272
216
|
host
|
|
273
217
|
}),
|
|
@@ -276,20 +220,16 @@ function queryCards(payload) {
|
|
|
276
220
|
{
|
|
277
221
|
transformFn: transformRESTTimestampToSDKTimestamp,
|
|
278
222
|
paths: [
|
|
279
|
-
{ path: "
|
|
280
|
-
{ path: "
|
|
281
|
-
{ path: "cards.stageUpdatedDate" },
|
|
282
|
-
{ path: "cards.dueDate" },
|
|
283
|
-
{ path: "cards.staleDate" },
|
|
284
|
-
{ path: "cards.linkedEntities.linkedDate" }
|
|
223
|
+
{ path: "pipelines.createdDate" },
|
|
224
|
+
{ path: "pipelines.updatedDate" }
|
|
285
225
|
]
|
|
286
226
|
}
|
|
287
227
|
]),
|
|
288
228
|
fallback: [
|
|
289
229
|
{
|
|
290
230
|
method: "POST",
|
|
291
|
-
url:
|
|
292
|
-
protoPath: "/v1/
|
|
231
|
+
url: resolveWixCrmPipelinesPipelinesV1PipelinesUrl({
|
|
232
|
+
protoPath: "/v1/pipelines/query",
|
|
293
233
|
data: payload,
|
|
294
234
|
host
|
|
295
235
|
}),
|
|
@@ -299,290 +239,20 @@ function queryCards(payload) {
|
|
|
299
239
|
};
|
|
300
240
|
return metadata;
|
|
301
241
|
}
|
|
302
|
-
return
|
|
303
|
-
}
|
|
304
|
-
function searchCards(payload) {
|
|
305
|
-
function __searchCards({ host }) {
|
|
306
|
-
const serializedData = transformPaths(payload, [
|
|
307
|
-
{
|
|
308
|
-
transformFn: transformSDKFloatToRESTFloat,
|
|
309
|
-
paths: [
|
|
310
|
-
{ path: "search.aggregations.range.buckets.from" },
|
|
311
|
-
{ path: "search.aggregations.range.buckets.to" },
|
|
312
|
-
{
|
|
313
|
-
path: "search.aggregations.nested.nestedAggregations.range.buckets.from"
|
|
314
|
-
},
|
|
315
|
-
{
|
|
316
|
-
path: "search.aggregations.nested.nestedAggregations.range.buckets.to"
|
|
317
|
-
}
|
|
318
|
-
]
|
|
319
|
-
}
|
|
320
|
-
]);
|
|
321
|
-
const metadata = {
|
|
322
|
-
entityFqdn: "wix.crm.pipelines.v1.card",
|
|
323
|
-
method: "GET",
|
|
324
|
-
methodFqn: "wix.crm.pipelines.cards.v1.Cards.SearchCards",
|
|
325
|
-
packageName: PACKAGE_NAME,
|
|
326
|
-
migrationOptions: {
|
|
327
|
-
optInTransformResponse: true
|
|
328
|
-
},
|
|
329
|
-
url: resolveWixCrmPipelinesCardsV1CardsUrl({
|
|
330
|
-
protoPath: "/v1/cards/search",
|
|
331
|
-
data: serializedData,
|
|
332
|
-
host
|
|
333
|
-
}),
|
|
334
|
-
params: toURLSearchParams(serializedData, true),
|
|
335
|
-
transformResponse: (payload2) => transformPaths(payload2, [
|
|
336
|
-
{
|
|
337
|
-
transformFn: transformRESTTimestampToSDKTimestamp,
|
|
338
|
-
paths: [
|
|
339
|
-
{ path: "cards.createdDate" },
|
|
340
|
-
{ path: "cards.updatedDate" },
|
|
341
|
-
{ path: "cards.stageUpdatedDate" },
|
|
342
|
-
{ path: "cards.dueDate" },
|
|
343
|
-
{ path: "cards.staleDate" },
|
|
344
|
-
{ path: "cards.linkedEntities.linkedDate" }
|
|
345
|
-
]
|
|
346
|
-
},
|
|
347
|
-
{
|
|
348
|
-
transformFn: transformRESTFloatToSDKFloat,
|
|
349
|
-
paths: [
|
|
350
|
-
{ path: "aggregationData.results.ranges.results.from" },
|
|
351
|
-
{ path: "aggregationData.results.ranges.results.to" },
|
|
352
|
-
{
|
|
353
|
-
path: "aggregationData.results.groupedByValue.results.nestedResults.ranges.results.from"
|
|
354
|
-
},
|
|
355
|
-
{
|
|
356
|
-
path: "aggregationData.results.groupedByValue.results.nestedResults.ranges.results.to"
|
|
357
|
-
},
|
|
358
|
-
{
|
|
359
|
-
path: "aggregationData.results.nested.results.results.*.range.from"
|
|
360
|
-
},
|
|
361
|
-
{
|
|
362
|
-
path: "aggregationData.results.nested.results.results.*.range.to"
|
|
363
|
-
},
|
|
364
|
-
{ path: "aggregationData.results.scalar.value" },
|
|
365
|
-
{
|
|
366
|
-
path: "aggregationData.results.groupedByValue.results.nestedResults.scalar.value"
|
|
367
|
-
},
|
|
368
|
-
{
|
|
369
|
-
path: "aggregationData.results.nested.results.results.*.scalar.value"
|
|
370
|
-
}
|
|
371
|
-
]
|
|
372
|
-
}
|
|
373
|
-
]),
|
|
374
|
-
fallback: [
|
|
375
|
-
{
|
|
376
|
-
method: "POST",
|
|
377
|
-
url: resolveWixCrmPipelinesCardsV1CardsUrl({
|
|
378
|
-
protoPath: "/v1/cards/search",
|
|
379
|
-
data: serializedData,
|
|
380
|
-
host
|
|
381
|
-
}),
|
|
382
|
-
data: serializedData
|
|
383
|
-
}
|
|
384
|
-
]
|
|
385
|
-
};
|
|
386
|
-
return metadata;
|
|
387
|
-
}
|
|
388
|
-
return __searchCards;
|
|
389
|
-
}
|
|
390
|
-
function searchCardsByStage(payload) {
|
|
391
|
-
function __searchCardsByStage({ host }) {
|
|
392
|
-
const serializedData = transformPaths(payload, [
|
|
393
|
-
{
|
|
394
|
-
transformFn: transformSDKFloatToRESTFloat,
|
|
395
|
-
paths: [
|
|
396
|
-
{ path: "search.aggregations.range.buckets.from" },
|
|
397
|
-
{ path: "search.aggregations.range.buckets.to" },
|
|
398
|
-
{
|
|
399
|
-
path: "search.aggregations.nested.nestedAggregations.range.buckets.from"
|
|
400
|
-
},
|
|
401
|
-
{
|
|
402
|
-
path: "search.aggregations.nested.nestedAggregations.range.buckets.to"
|
|
403
|
-
}
|
|
404
|
-
]
|
|
405
|
-
}
|
|
406
|
-
]);
|
|
407
|
-
const metadata = {
|
|
408
|
-
entityFqdn: "wix.crm.pipelines.v1.card",
|
|
409
|
-
method: "GET",
|
|
410
|
-
methodFqn: "wix.crm.pipelines.cards.v1.Cards.SearchCardsByStage",
|
|
411
|
-
packageName: PACKAGE_NAME,
|
|
412
|
-
migrationOptions: {
|
|
413
|
-
optInTransformResponse: true
|
|
414
|
-
},
|
|
415
|
-
url: resolveWixCrmPipelinesCardsV1CardsUrl({
|
|
416
|
-
protoPath: "/v1/cards/search-by-stage",
|
|
417
|
-
data: serializedData,
|
|
418
|
-
host
|
|
419
|
-
}),
|
|
420
|
-
params: toURLSearchParams(serializedData, true),
|
|
421
|
-
transformResponse: (payload2) => transformPaths(payload2, [
|
|
422
|
-
{
|
|
423
|
-
transformFn: transformRESTTimestampToSDKTimestamp,
|
|
424
|
-
paths: [
|
|
425
|
-
{ path: "results.cards.createdDate" },
|
|
426
|
-
{ path: "results.cards.updatedDate" },
|
|
427
|
-
{ path: "results.cards.stageUpdatedDate" },
|
|
428
|
-
{ path: "results.cards.dueDate" },
|
|
429
|
-
{ path: "results.cards.staleDate" },
|
|
430
|
-
{ path: "results.cards.linkedEntities.linkedDate" }
|
|
431
|
-
]
|
|
432
|
-
},
|
|
433
|
-
{
|
|
434
|
-
transformFn: transformRESTFloatToSDKFloat,
|
|
435
|
-
paths: [
|
|
436
|
-
{ path: "results.aggregationData.results.ranges.results.from" },
|
|
437
|
-
{ path: "results.aggregationData.results.ranges.results.to" },
|
|
438
|
-
{
|
|
439
|
-
path: "results.aggregationData.results.groupedByValue.results.nestedResults.ranges.results.from"
|
|
440
|
-
},
|
|
441
|
-
{
|
|
442
|
-
path: "results.aggregationData.results.groupedByValue.results.nestedResults.ranges.results.to"
|
|
443
|
-
},
|
|
444
|
-
{
|
|
445
|
-
path: "results.aggregationData.results.nested.results.results.*.range.from"
|
|
446
|
-
},
|
|
447
|
-
{
|
|
448
|
-
path: "results.aggregationData.results.nested.results.results.*.range.to"
|
|
449
|
-
},
|
|
450
|
-
{ path: "results.aggregationData.results.scalar.value" },
|
|
451
|
-
{
|
|
452
|
-
path: "results.aggregationData.results.groupedByValue.results.nestedResults.scalar.value"
|
|
453
|
-
},
|
|
454
|
-
{
|
|
455
|
-
path: "results.aggregationData.results.nested.results.results.*.scalar.value"
|
|
456
|
-
}
|
|
457
|
-
]
|
|
458
|
-
}
|
|
459
|
-
]),
|
|
460
|
-
fallback: [
|
|
461
|
-
{
|
|
462
|
-
method: "POST",
|
|
463
|
-
url: resolveWixCrmPipelinesCardsV1CardsUrl({
|
|
464
|
-
protoPath: "/v1/cards/search-by-stage",
|
|
465
|
-
data: serializedData,
|
|
466
|
-
host
|
|
467
|
-
}),
|
|
468
|
-
data: serializedData
|
|
469
|
-
}
|
|
470
|
-
]
|
|
471
|
-
};
|
|
472
|
-
return metadata;
|
|
473
|
-
}
|
|
474
|
-
return __searchCardsByStage;
|
|
475
|
-
}
|
|
476
|
-
function bulkCreateCards(payload) {
|
|
477
|
-
function __bulkCreateCards({ host }) {
|
|
478
|
-
const serializedData = transformPaths(payload, [
|
|
479
|
-
{
|
|
480
|
-
transformFn: transformSDKTimestampToRESTTimestamp,
|
|
481
|
-
paths: [
|
|
482
|
-
{ path: "cards.createdDate" },
|
|
483
|
-
{ path: "cards.updatedDate" },
|
|
484
|
-
{ path: "cards.stageUpdatedDate" },
|
|
485
|
-
{ path: "cards.dueDate" },
|
|
486
|
-
{ path: "cards.staleDate" },
|
|
487
|
-
{ path: "cards.linkedEntities.linkedDate" }
|
|
488
|
-
]
|
|
489
|
-
}
|
|
490
|
-
]);
|
|
491
|
-
const metadata = {
|
|
492
|
-
entityFqdn: "wix.crm.pipelines.v1.card",
|
|
493
|
-
method: "POST",
|
|
494
|
-
methodFqn: "wix.crm.pipelines.cards.v1.Cards.BulkCreateCards",
|
|
495
|
-
packageName: PACKAGE_NAME,
|
|
496
|
-
migrationOptions: {
|
|
497
|
-
optInTransformResponse: true
|
|
498
|
-
},
|
|
499
|
-
url: resolveWixCrmPipelinesCardsV1CardsUrl({
|
|
500
|
-
protoPath: "/v1/bulk/cards/create",
|
|
501
|
-
data: serializedData,
|
|
502
|
-
host
|
|
503
|
-
}),
|
|
504
|
-
data: serializedData,
|
|
505
|
-
transformResponse: (payload2) => transformPaths(payload2, [
|
|
506
|
-
{
|
|
507
|
-
transformFn: transformRESTTimestampToSDKTimestamp,
|
|
508
|
-
paths: [
|
|
509
|
-
{ path: "results.item.createdDate" },
|
|
510
|
-
{ path: "results.item.updatedDate" },
|
|
511
|
-
{ path: "results.item.stageUpdatedDate" },
|
|
512
|
-
{ path: "results.item.dueDate" },
|
|
513
|
-
{ path: "results.item.staleDate" },
|
|
514
|
-
{ path: "results.item.linkedEntities.linkedDate" }
|
|
515
|
-
]
|
|
516
|
-
}
|
|
517
|
-
])
|
|
518
|
-
};
|
|
519
|
-
return metadata;
|
|
520
|
-
}
|
|
521
|
-
return __bulkCreateCards;
|
|
522
|
-
}
|
|
523
|
-
function bulkUpdateCards(payload) {
|
|
524
|
-
function __bulkUpdateCards({ host }) {
|
|
525
|
-
const serializedData = transformPaths(payload, [
|
|
526
|
-
{
|
|
527
|
-
transformFn: transformSDKFieldMaskToRESTFieldMask,
|
|
528
|
-
paths: [{ path: "cards.fieldMask" }]
|
|
529
|
-
},
|
|
530
|
-
{
|
|
531
|
-
transformFn: transformSDKTimestampToRESTTimestamp,
|
|
532
|
-
paths: [
|
|
533
|
-
{ path: "cards.card.createdDate" },
|
|
534
|
-
{ path: "cards.card.updatedDate" },
|
|
535
|
-
{ path: "cards.card.stageUpdatedDate" },
|
|
536
|
-
{ path: "cards.card.dueDate" },
|
|
537
|
-
{ path: "cards.card.staleDate" },
|
|
538
|
-
{ path: "cards.card.linkedEntities.linkedDate" }
|
|
539
|
-
]
|
|
540
|
-
}
|
|
541
|
-
]);
|
|
542
|
-
const metadata = {
|
|
543
|
-
entityFqdn: "wix.crm.pipelines.v1.card",
|
|
544
|
-
method: "POST",
|
|
545
|
-
methodFqn: "wix.crm.pipelines.cards.v1.Cards.BulkUpdateCards",
|
|
546
|
-
packageName: PACKAGE_NAME,
|
|
547
|
-
migrationOptions: {
|
|
548
|
-
optInTransformResponse: true
|
|
549
|
-
},
|
|
550
|
-
url: resolveWixCrmPipelinesCardsV1CardsUrl({
|
|
551
|
-
protoPath: "/v1/bulk/cards/update",
|
|
552
|
-
data: serializedData,
|
|
553
|
-
host
|
|
554
|
-
}),
|
|
555
|
-
data: serializedData,
|
|
556
|
-
transformResponse: (payload2) => transformPaths(payload2, [
|
|
557
|
-
{
|
|
558
|
-
transformFn: transformRESTTimestampToSDKTimestamp,
|
|
559
|
-
paths: [
|
|
560
|
-
{ path: "results.item.createdDate" },
|
|
561
|
-
{ path: "results.item.updatedDate" },
|
|
562
|
-
{ path: "results.item.stageUpdatedDate" },
|
|
563
|
-
{ path: "results.item.dueDate" },
|
|
564
|
-
{ path: "results.item.staleDate" },
|
|
565
|
-
{ path: "results.item.linkedEntities.linkedDate" }
|
|
566
|
-
]
|
|
567
|
-
}
|
|
568
|
-
])
|
|
569
|
-
};
|
|
570
|
-
return metadata;
|
|
571
|
-
}
|
|
572
|
-
return __bulkUpdateCards;
|
|
242
|
+
return __queryPipelines;
|
|
573
243
|
}
|
|
574
|
-
function
|
|
575
|
-
function
|
|
244
|
+
function bulkUpdatePipelineTags(payload) {
|
|
245
|
+
function __bulkUpdatePipelineTags({ host }) {
|
|
576
246
|
const metadata = {
|
|
577
|
-
entityFqdn: "wix.crm.pipelines.v1.
|
|
247
|
+
entityFqdn: "wix.crm.pipelines.v1.pipeline",
|
|
578
248
|
method: "POST",
|
|
579
|
-
methodFqn: "wix.crm.pipelines.
|
|
249
|
+
methodFqn: "wix.crm.pipelines.pipelines.v1.Pipelines.BulkUpdatePipelineTags",
|
|
580
250
|
packageName: PACKAGE_NAME,
|
|
581
251
|
migrationOptions: {
|
|
582
252
|
optInTransformResponse: true
|
|
583
253
|
},
|
|
584
|
-
url:
|
|
585
|
-
protoPath: "/v1/bulk/
|
|
254
|
+
url: resolveWixCrmPipelinesPipelinesV1PipelinesUrl({
|
|
255
|
+
protoPath: "/v1/bulk/pipelines/update-tags",
|
|
586
256
|
data: payload,
|
|
587
257
|
host
|
|
588
258
|
}),
|
|
@@ -590,20 +260,20 @@ function bulkDeleteCards(payload) {
|
|
|
590
260
|
};
|
|
591
261
|
return metadata;
|
|
592
262
|
}
|
|
593
|
-
return
|
|
263
|
+
return __bulkUpdatePipelineTags;
|
|
594
264
|
}
|
|
595
|
-
function
|
|
596
|
-
function
|
|
265
|
+
function bulkUpdatePipelineTagsByFilter(payload) {
|
|
266
|
+
function __bulkUpdatePipelineTagsByFilter({ host }) {
|
|
597
267
|
const metadata = {
|
|
598
|
-
entityFqdn: "wix.crm.pipelines.v1.
|
|
268
|
+
entityFqdn: "wix.crm.pipelines.v1.pipeline",
|
|
599
269
|
method: "POST",
|
|
600
|
-
methodFqn: "wix.crm.pipelines.
|
|
270
|
+
methodFqn: "wix.crm.pipelines.pipelines.v1.Pipelines.BulkUpdatePipelineTagsByFilter",
|
|
601
271
|
packageName: PACKAGE_NAME,
|
|
602
272
|
migrationOptions: {
|
|
603
273
|
optInTransformResponse: true
|
|
604
274
|
},
|
|
605
|
-
url:
|
|
606
|
-
protoPath: "/v1/bulk/
|
|
275
|
+
url: resolveWixCrmPipelinesPipelinesV1PipelinesUrl({
|
|
276
|
+
protoPath: "/v1/bulk/pipelines/update-tags-by-filter",
|
|
607
277
|
data: payload,
|
|
608
278
|
host
|
|
609
279
|
}),
|
|
@@ -611,41 +281,12 @@ function bulkUpdateCardTags(payload) {
|
|
|
611
281
|
};
|
|
612
282
|
return metadata;
|
|
613
283
|
}
|
|
614
|
-
return
|
|
615
|
-
}
|
|
616
|
-
function bulkUpdateCardTagsByFilter(payload) {
|
|
617
|
-
function __bulkUpdateCardTagsByFilter({ host }) {
|
|
618
|
-
const metadata = {
|
|
619
|
-
entityFqdn: "wix.crm.pipelines.v1.card",
|
|
620
|
-
method: "POST",
|
|
621
|
-
methodFqn: "wix.crm.pipelines.cards.v1.Cards.BulkUpdateCardTagsByFilter",
|
|
622
|
-
packageName: PACKAGE_NAME,
|
|
623
|
-
migrationOptions: {
|
|
624
|
-
optInTransformResponse: true
|
|
625
|
-
},
|
|
626
|
-
url: resolveWixCrmPipelinesCardsV1CardsUrl({
|
|
627
|
-
protoPath: "/v1/bulk/cards/update-tags-by-filter",
|
|
628
|
-
data: payload,
|
|
629
|
-
host
|
|
630
|
-
}),
|
|
631
|
-
data: payload
|
|
632
|
-
};
|
|
633
|
-
return metadata;
|
|
634
|
-
}
|
|
635
|
-
return __bulkUpdateCardTagsByFilter;
|
|
284
|
+
return __bulkUpdatePipelineTagsByFilter;
|
|
636
285
|
}
|
|
637
286
|
|
|
638
|
-
// src/crm-pipelines-v1-
|
|
287
|
+
// src/crm-pipelines-v1-pipeline-pipelines.universal.ts
|
|
639
288
|
import { transformPaths as transformPaths2 } from "@wix/sdk-runtime/transformations/transform-paths";
|
|
640
289
|
import { createQueryUtils } from "@wix/sdk-runtime/query-builder-utils";
|
|
641
|
-
import { createSearchUtils } from "@wix/sdk-runtime/search-builder-utils";
|
|
642
|
-
var Priority = /* @__PURE__ */ ((Priority2) => {
|
|
643
|
-
Priority2["P1_URGENT"] = "P1_URGENT";
|
|
644
|
-
Priority2["P2_HIGH"] = "P2_HIGH";
|
|
645
|
-
Priority2["P3_MEDIUM"] = "P3_MEDIUM";
|
|
646
|
-
Priority2["P4_LOW"] = "P4_LOW";
|
|
647
|
-
return Priority2;
|
|
648
|
-
})(Priority || {});
|
|
649
290
|
var Outcome = /* @__PURE__ */ ((Outcome2) => {
|
|
650
291
|
Outcome2["NONE"] = "NONE";
|
|
651
292
|
Outcome2["WON"] = "WON";
|
|
@@ -657,62 +298,6 @@ var SortOrder = /* @__PURE__ */ ((SortOrder2) => {
|
|
|
657
298
|
SortOrder2["DESC"] = "DESC";
|
|
658
299
|
return SortOrder2;
|
|
659
300
|
})(SortOrder || {});
|
|
660
|
-
var SortType = /* @__PURE__ */ ((SortType2) => {
|
|
661
|
-
SortType2["COUNT"] = "COUNT";
|
|
662
|
-
SortType2["VALUE"] = "VALUE";
|
|
663
|
-
return SortType2;
|
|
664
|
-
})(SortType || {});
|
|
665
|
-
var SortDirection = /* @__PURE__ */ ((SortDirection2) => {
|
|
666
|
-
SortDirection2["DESC"] = "DESC";
|
|
667
|
-
SortDirection2["ASC"] = "ASC";
|
|
668
|
-
return SortDirection2;
|
|
669
|
-
})(SortDirection || {});
|
|
670
|
-
var MissingValues = /* @__PURE__ */ ((MissingValues2) => {
|
|
671
|
-
MissingValues2["EXCLUDE"] = "EXCLUDE";
|
|
672
|
-
MissingValues2["INCLUDE"] = "INCLUDE";
|
|
673
|
-
return MissingValues2;
|
|
674
|
-
})(MissingValues || {});
|
|
675
|
-
var ScalarType = /* @__PURE__ */ ((ScalarType2) => {
|
|
676
|
-
ScalarType2["COUNT_DISTINCT"] = "COUNT_DISTINCT";
|
|
677
|
-
ScalarType2["MIN"] = "MIN";
|
|
678
|
-
ScalarType2["MAX"] = "MAX";
|
|
679
|
-
return ScalarType2;
|
|
680
|
-
})(ScalarType || {});
|
|
681
|
-
var NestedAggregationType = /* @__PURE__ */ ((NestedAggregationType2) => {
|
|
682
|
-
NestedAggregationType2["VALUE"] = "VALUE";
|
|
683
|
-
NestedAggregationType2["RANGE"] = "RANGE";
|
|
684
|
-
NestedAggregationType2["SCALAR"] = "SCALAR";
|
|
685
|
-
NestedAggregationType2["DATE_HISTOGRAM"] = "DATE_HISTOGRAM";
|
|
686
|
-
return NestedAggregationType2;
|
|
687
|
-
})(NestedAggregationType || {});
|
|
688
|
-
var Interval = /* @__PURE__ */ ((Interval2) => {
|
|
689
|
-
Interval2["YEAR"] = "YEAR";
|
|
690
|
-
Interval2["MONTH"] = "MONTH";
|
|
691
|
-
Interval2["WEEK"] = "WEEK";
|
|
692
|
-
Interval2["DAY"] = "DAY";
|
|
693
|
-
Interval2["HOUR"] = "HOUR";
|
|
694
|
-
Interval2["MINUTE"] = "MINUTE";
|
|
695
|
-
Interval2["SECOND"] = "SECOND";
|
|
696
|
-
return Interval2;
|
|
697
|
-
})(Interval || {});
|
|
698
|
-
var AggregationType = /* @__PURE__ */ ((AggregationType2) => {
|
|
699
|
-
AggregationType2["VALUE"] = "VALUE";
|
|
700
|
-
AggregationType2["RANGE"] = "RANGE";
|
|
701
|
-
AggregationType2["SCALAR"] = "SCALAR";
|
|
702
|
-
AggregationType2["DATE_HISTOGRAM"] = "DATE_HISTOGRAM";
|
|
703
|
-
AggregationType2["NESTED"] = "NESTED";
|
|
704
|
-
return AggregationType2;
|
|
705
|
-
})(AggregationType || {});
|
|
706
|
-
var Mode = /* @__PURE__ */ ((Mode2) => {
|
|
707
|
-
Mode2["OR"] = "OR";
|
|
708
|
-
Mode2["AND"] = "AND";
|
|
709
|
-
return Mode2;
|
|
710
|
-
})(Mode || {});
|
|
711
|
-
var NameFormat = /* @__PURE__ */ ((NameFormat2) => {
|
|
712
|
-
NameFormat2["BY_FIRST_NAME"] = "BY_FIRST_NAME";
|
|
713
|
-
NameFormat2["BY_LAST_NAME"] = "BY_LAST_NAME";
|
|
714
|
-
return NameFormat2;
|
|
715
|
-
})(NameFormat || {});
|
|
716
301
|
var WebhookIdentityType = /* @__PURE__ */ ((WebhookIdentityType2) => {
|
|
717
302
|
WebhookIdentityType2["UNKNOWN"] = "UNKNOWN";
|
|
718
303
|
WebhookIdentityType2["ANONYMOUS_VISITOR"] = "ANONYMOUS_VISITOR";
|
|
@@ -721,88 +306,85 @@ var WebhookIdentityType = /* @__PURE__ */ ((WebhookIdentityType2) => {
|
|
|
721
306
|
WebhookIdentityType2["APP"] = "APP";
|
|
722
307
|
return WebhookIdentityType2;
|
|
723
308
|
})(WebhookIdentityType || {});
|
|
724
|
-
async function
|
|
309
|
+
async function createPipeline2(pipeline) {
|
|
725
310
|
const { httpClient, sideEffects } = arguments[1];
|
|
726
|
-
const payload = renameKeysFromSDKRequestToRESTRequest({
|
|
727
|
-
|
|
728
|
-
});
|
|
729
|
-
const reqOpts = createCard(payload);
|
|
311
|
+
const payload = renameKeysFromSDKRequestToRESTRequest({ pipeline });
|
|
312
|
+
const reqOpts = createPipeline(payload);
|
|
730
313
|
sideEffects?.onSiteCall?.();
|
|
731
314
|
try {
|
|
732
315
|
const result = await httpClient.request(reqOpts);
|
|
733
316
|
sideEffects?.onSuccess?.(result);
|
|
734
|
-
return renameKeysFromRESTResponseToSDKResponse(result.data)?.
|
|
317
|
+
return renameKeysFromRESTResponseToSDKResponse(result.data)?.pipeline;
|
|
735
318
|
} catch (err) {
|
|
736
319
|
const transformedError = sdkTransformError(
|
|
737
320
|
err,
|
|
738
321
|
{
|
|
739
322
|
spreadPathsToArguments: {},
|
|
740
|
-
explicitPathsToArguments: {
|
|
323
|
+
explicitPathsToArguments: { pipeline: "$[0]" },
|
|
741
324
|
singleArgumentUnchanged: false
|
|
742
325
|
},
|
|
743
|
-
["
|
|
326
|
+
["pipeline"]
|
|
744
327
|
);
|
|
745
328
|
sideEffects?.onError?.(err);
|
|
746
329
|
throw transformedError;
|
|
747
330
|
}
|
|
748
331
|
}
|
|
749
|
-
async function
|
|
332
|
+
async function getPipeline2(pipelineId) {
|
|
750
333
|
const { httpClient, sideEffects } = arguments[1];
|
|
751
|
-
const payload = renameKeysFromSDKRequestToRESTRequest({
|
|
752
|
-
|
|
334
|
+
const payload = renameKeysFromSDKRequestToRESTRequest({
|
|
335
|
+
pipelineId
|
|
336
|
+
});
|
|
337
|
+
const reqOpts = getPipeline(payload);
|
|
753
338
|
sideEffects?.onSiteCall?.();
|
|
754
339
|
try {
|
|
755
340
|
const result = await httpClient.request(reqOpts);
|
|
756
341
|
sideEffects?.onSuccess?.(result);
|
|
757
|
-
return renameKeysFromRESTResponseToSDKResponse(result.data)?.
|
|
342
|
+
return renameKeysFromRESTResponseToSDKResponse(result.data)?.pipeline;
|
|
758
343
|
} catch (err) {
|
|
759
344
|
const transformedError = sdkTransformError(
|
|
760
345
|
err,
|
|
761
346
|
{
|
|
762
347
|
spreadPathsToArguments: {},
|
|
763
|
-
explicitPathsToArguments: {
|
|
348
|
+
explicitPathsToArguments: { pipelineId: "$[0]" },
|
|
764
349
|
singleArgumentUnchanged: false
|
|
765
350
|
},
|
|
766
|
-
["
|
|
351
|
+
["pipelineId"]
|
|
767
352
|
);
|
|
768
353
|
sideEffects?.onError?.(err);
|
|
769
354
|
throw transformedError;
|
|
770
355
|
}
|
|
771
356
|
}
|
|
772
|
-
async function
|
|
357
|
+
async function updatePipeline2(_id, pipeline) {
|
|
773
358
|
const { httpClient, sideEffects } = arguments[2];
|
|
774
359
|
const payload = renameKeysFromSDKRequestToRESTRequest({
|
|
775
|
-
|
|
360
|
+
pipeline: { ...pipeline, id: _id }
|
|
776
361
|
});
|
|
777
|
-
const reqOpts =
|
|
362
|
+
const reqOpts = updatePipeline(payload);
|
|
778
363
|
sideEffects?.onSiteCall?.();
|
|
779
364
|
try {
|
|
780
365
|
const result = await httpClient.request(reqOpts);
|
|
781
366
|
sideEffects?.onSuccess?.(result);
|
|
782
|
-
return renameKeysFromRESTResponseToSDKResponse(result.data)?.
|
|
367
|
+
return renameKeysFromRESTResponseToSDKResponse(result.data)?.pipeline;
|
|
783
368
|
} catch (err) {
|
|
784
369
|
const transformedError = sdkTransformError(
|
|
785
370
|
err,
|
|
786
371
|
{
|
|
787
|
-
spreadPathsToArguments: {
|
|
788
|
-
explicitPathsToArguments: { "
|
|
372
|
+
spreadPathsToArguments: { pipeline: "$[1]" },
|
|
373
|
+
explicitPathsToArguments: { "pipeline.id": "$[0]" },
|
|
789
374
|
singleArgumentUnchanged: false
|
|
790
375
|
},
|
|
791
|
-
["_id", "
|
|
376
|
+
["_id", "pipeline"]
|
|
792
377
|
);
|
|
793
378
|
sideEffects?.onError?.(err);
|
|
794
379
|
throw transformedError;
|
|
795
380
|
}
|
|
796
381
|
}
|
|
797
|
-
async function
|
|
798
|
-
const { httpClient, sideEffects } = arguments[
|
|
382
|
+
async function deletePipeline2(pipelineId) {
|
|
383
|
+
const { httpClient, sideEffects } = arguments[1];
|
|
799
384
|
const payload = renameKeysFromSDKRequestToRESTRequest({
|
|
800
|
-
|
|
801
|
-
stageId,
|
|
802
|
-
revision: options?.revision,
|
|
803
|
-
outcome: options?.outcome
|
|
385
|
+
pipelineId
|
|
804
386
|
});
|
|
805
|
-
const reqOpts =
|
|
387
|
+
const reqOpts = deletePipeline(payload);
|
|
806
388
|
sideEffects?.onSiteCall?.();
|
|
807
389
|
try {
|
|
808
390
|
const result = await httpClient.request(reqOpts);
|
|
@@ -813,47 +395,20 @@ async function moveCard2(cardId, stageId, options) {
|
|
|
813
395
|
err,
|
|
814
396
|
{
|
|
815
397
|
spreadPathsToArguments: {},
|
|
816
|
-
explicitPathsToArguments: {
|
|
817
|
-
cardId: "$[0]",
|
|
818
|
-
stageId: "$[1]",
|
|
819
|
-
revision: "$[2].revision",
|
|
820
|
-
outcome: "$[2].outcome"
|
|
821
|
-
},
|
|
822
|
-
singleArgumentUnchanged: false
|
|
823
|
-
},
|
|
824
|
-
["cardId", "stageId", "options"]
|
|
825
|
-
);
|
|
826
|
-
sideEffects?.onError?.(err);
|
|
827
|
-
throw transformedError;
|
|
828
|
-
}
|
|
829
|
-
}
|
|
830
|
-
async function deleteCard2(cardId) {
|
|
831
|
-
const { httpClient, sideEffects } = arguments[1];
|
|
832
|
-
const payload = renameKeysFromSDKRequestToRESTRequest({ cardId });
|
|
833
|
-
const reqOpts = deleteCard(payload);
|
|
834
|
-
sideEffects?.onSiteCall?.();
|
|
835
|
-
try {
|
|
836
|
-
const result = await httpClient.request(reqOpts);
|
|
837
|
-
sideEffects?.onSuccess?.(result);
|
|
838
|
-
} catch (err) {
|
|
839
|
-
const transformedError = sdkTransformError(
|
|
840
|
-
err,
|
|
841
|
-
{
|
|
842
|
-
spreadPathsToArguments: {},
|
|
843
|
-
explicitPathsToArguments: { cardId: "$[0]" },
|
|
398
|
+
explicitPathsToArguments: { pipelineId: "$[0]" },
|
|
844
399
|
singleArgumentUnchanged: false
|
|
845
400
|
},
|
|
846
|
-
["
|
|
401
|
+
["pipelineId"]
|
|
847
402
|
);
|
|
848
403
|
sideEffects?.onError?.(err);
|
|
849
404
|
throw transformedError;
|
|
850
405
|
}
|
|
851
406
|
}
|
|
852
|
-
function
|
|
407
|
+
function queryPipelines2() {
|
|
853
408
|
const { httpClient, sideEffects } = arguments[0];
|
|
854
409
|
return queryBuilder({
|
|
855
410
|
func: async (payload) => {
|
|
856
|
-
const reqOpts =
|
|
411
|
+
const reqOpts = queryPipelines(payload);
|
|
857
412
|
sideEffects?.onSiteCall?.();
|
|
858
413
|
try {
|
|
859
414
|
const result = await httpClient.request(reqOpts);
|
|
@@ -876,7 +431,7 @@ function queryCards2() {
|
|
|
876
431
|
transformPaths2(data, [])
|
|
877
432
|
);
|
|
878
433
|
return {
|
|
879
|
-
items: transformedData?.
|
|
434
|
+
items: transformedData?.pipelines,
|
|
880
435
|
pagingMetadata: transformedData?.pagingMetadata
|
|
881
436
|
};
|
|
882
437
|
},
|
|
@@ -892,10 +447,10 @@ function queryCards2() {
|
|
|
892
447
|
transformationPaths: {}
|
|
893
448
|
});
|
|
894
449
|
}
|
|
895
|
-
async function
|
|
450
|
+
async function typedQueryPipelines(query) {
|
|
896
451
|
const { httpClient, sideEffects } = arguments[1];
|
|
897
452
|
const payload = renameKeysFromSDKRequestToRESTRequest({ query });
|
|
898
|
-
const reqOpts =
|
|
453
|
+
const reqOpts = queryPipelines(payload);
|
|
899
454
|
sideEffects?.onSiteCall?.();
|
|
900
455
|
try {
|
|
901
456
|
const result = await httpClient.request(reqOpts);
|
|
@@ -918,163 +473,17 @@ async function typedQueryCards(query) {
|
|
|
918
473
|
var utils = {
|
|
919
474
|
query: {
|
|
920
475
|
...createQueryUtils()
|
|
921
|
-
},
|
|
922
|
-
search: {
|
|
923
|
-
...createSearchUtils()
|
|
924
476
|
}
|
|
925
477
|
};
|
|
926
|
-
async function
|
|
927
|
-
const { httpClient, sideEffects } = arguments[2];
|
|
928
|
-
const payload = renameKeysFromSDKRequestToRESTRequest({
|
|
929
|
-
search,
|
|
930
|
-
nameFormat: options?.nameFormat
|
|
931
|
-
});
|
|
932
|
-
const reqOpts = searchCards(payload);
|
|
933
|
-
sideEffects?.onSiteCall?.();
|
|
934
|
-
try {
|
|
935
|
-
const result = await httpClient.request(reqOpts);
|
|
936
|
-
sideEffects?.onSuccess?.(result);
|
|
937
|
-
return renameKeysFromRESTResponseToSDKResponse(result.data);
|
|
938
|
-
} catch (err) {
|
|
939
|
-
const transformedError = sdkTransformError(
|
|
940
|
-
err,
|
|
941
|
-
{
|
|
942
|
-
spreadPathsToArguments: {},
|
|
943
|
-
explicitPathsToArguments: {
|
|
944
|
-
search: "$[0]",
|
|
945
|
-
nameFormat: "$[1].nameFormat"
|
|
946
|
-
},
|
|
947
|
-
singleArgumentUnchanged: false
|
|
948
|
-
},
|
|
949
|
-
["search", "options"]
|
|
950
|
-
);
|
|
951
|
-
sideEffects?.onError?.(err);
|
|
952
|
-
throw transformedError;
|
|
953
|
-
}
|
|
954
|
-
}
|
|
955
|
-
async function searchCardsByStage2(pipelineId, options) {
|
|
956
|
-
const { httpClient, sideEffects } = arguments[2];
|
|
957
|
-
const payload = renameKeysFromSDKRequestToRESTRequest({
|
|
958
|
-
pipelineId,
|
|
959
|
-
stageIds: options?.stageIds,
|
|
960
|
-
search: options?.search,
|
|
961
|
-
nameFormat: options?.nameFormat
|
|
962
|
-
});
|
|
963
|
-
const reqOpts = searchCardsByStage(payload);
|
|
964
|
-
sideEffects?.onSiteCall?.();
|
|
965
|
-
try {
|
|
966
|
-
const result = await httpClient.request(reqOpts);
|
|
967
|
-
sideEffects?.onSuccess?.(result);
|
|
968
|
-
return renameKeysFromRESTResponseToSDKResponse(result.data);
|
|
969
|
-
} catch (err) {
|
|
970
|
-
const transformedError = sdkTransformError(
|
|
971
|
-
err,
|
|
972
|
-
{
|
|
973
|
-
spreadPathsToArguments: {},
|
|
974
|
-
explicitPathsToArguments: {
|
|
975
|
-
pipelineId: "$[0]",
|
|
976
|
-
stageIds: "$[1].stageIds",
|
|
977
|
-
search: "$[1].search",
|
|
978
|
-
nameFormat: "$[1].nameFormat"
|
|
979
|
-
},
|
|
980
|
-
singleArgumentUnchanged: false
|
|
981
|
-
},
|
|
982
|
-
["pipelineId", "options"]
|
|
983
|
-
);
|
|
984
|
-
sideEffects?.onError?.(err);
|
|
985
|
-
throw transformedError;
|
|
986
|
-
}
|
|
987
|
-
}
|
|
988
|
-
async function bulkCreateCards2(cards, options) {
|
|
989
|
-
const { httpClient, sideEffects } = arguments[2];
|
|
990
|
-
const payload = renameKeysFromSDKRequestToRESTRequest({
|
|
991
|
-
cards,
|
|
992
|
-
returnEntity: options?.returnEntity
|
|
993
|
-
});
|
|
994
|
-
const reqOpts = bulkCreateCards(payload);
|
|
995
|
-
sideEffects?.onSiteCall?.();
|
|
996
|
-
try {
|
|
997
|
-
const result = await httpClient.request(reqOpts);
|
|
998
|
-
sideEffects?.onSuccess?.(result);
|
|
999
|
-
return renameKeysFromRESTResponseToSDKResponse(result.data);
|
|
1000
|
-
} catch (err) {
|
|
1001
|
-
const transformedError = sdkTransformError(
|
|
1002
|
-
err,
|
|
1003
|
-
{
|
|
1004
|
-
spreadPathsToArguments: {},
|
|
1005
|
-
explicitPathsToArguments: {
|
|
1006
|
-
cards: "$[0]",
|
|
1007
|
-
returnEntity: "$[1].returnEntity"
|
|
1008
|
-
},
|
|
1009
|
-
singleArgumentUnchanged: false
|
|
1010
|
-
},
|
|
1011
|
-
["cards", "options"]
|
|
1012
|
-
);
|
|
1013
|
-
sideEffects?.onError?.(err);
|
|
1014
|
-
throw transformedError;
|
|
1015
|
-
}
|
|
1016
|
-
}
|
|
1017
|
-
async function bulkUpdateCards2(cards, options) {
|
|
1018
|
-
const { httpClient, sideEffects } = arguments[2];
|
|
1019
|
-
const payload = renameKeysFromSDKRequestToRESTRequest({
|
|
1020
|
-
cards,
|
|
1021
|
-
returnEntity: options?.returnEntity
|
|
1022
|
-
});
|
|
1023
|
-
const reqOpts = bulkUpdateCards(payload);
|
|
1024
|
-
sideEffects?.onSiteCall?.();
|
|
1025
|
-
try {
|
|
1026
|
-
const result = await httpClient.request(reqOpts);
|
|
1027
|
-
sideEffects?.onSuccess?.(result);
|
|
1028
|
-
return renameKeysFromRESTResponseToSDKResponse(result.data);
|
|
1029
|
-
} catch (err) {
|
|
1030
|
-
const transformedError = sdkTransformError(
|
|
1031
|
-
err,
|
|
1032
|
-
{
|
|
1033
|
-
spreadPathsToArguments: {},
|
|
1034
|
-
explicitPathsToArguments: {
|
|
1035
|
-
cards: "$[0]",
|
|
1036
|
-
returnEntity: "$[1].returnEntity"
|
|
1037
|
-
},
|
|
1038
|
-
singleArgumentUnchanged: false
|
|
1039
|
-
},
|
|
1040
|
-
["cards", "options"]
|
|
1041
|
-
);
|
|
1042
|
-
sideEffects?.onError?.(err);
|
|
1043
|
-
throw transformedError;
|
|
1044
|
-
}
|
|
1045
|
-
}
|
|
1046
|
-
async function bulkDeleteCards2(cardIds) {
|
|
1047
|
-
const { httpClient, sideEffects } = arguments[1];
|
|
1048
|
-
const payload = renameKeysFromSDKRequestToRESTRequest({ cardIds });
|
|
1049
|
-
const reqOpts = bulkDeleteCards(payload);
|
|
1050
|
-
sideEffects?.onSiteCall?.();
|
|
1051
|
-
try {
|
|
1052
|
-
const result = await httpClient.request(reqOpts);
|
|
1053
|
-
sideEffects?.onSuccess?.(result);
|
|
1054
|
-
return renameKeysFromRESTResponseToSDKResponse(result.data);
|
|
1055
|
-
} catch (err) {
|
|
1056
|
-
const transformedError = sdkTransformError(
|
|
1057
|
-
err,
|
|
1058
|
-
{
|
|
1059
|
-
spreadPathsToArguments: {},
|
|
1060
|
-
explicitPathsToArguments: { cardIds: "$[0]" },
|
|
1061
|
-
singleArgumentUnchanged: false
|
|
1062
|
-
},
|
|
1063
|
-
["cardIds"]
|
|
1064
|
-
);
|
|
1065
|
-
sideEffects?.onError?.(err);
|
|
1066
|
-
throw transformedError;
|
|
1067
|
-
}
|
|
1068
|
-
}
|
|
1069
|
-
async function bulkUpdateCardTags2(cardIds, options) {
|
|
478
|
+
async function bulkUpdatePipelineTags2(pipelineIds, options) {
|
|
1070
479
|
const { httpClient, sideEffects } = arguments[2];
|
|
1071
480
|
const payload = renameKeysFromSDKRequestToRESTRequest({
|
|
1072
|
-
|
|
481
|
+
pipelineIds,
|
|
1073
482
|
assignTags: options?.assignTags,
|
|
1074
483
|
unassignTags: options?.unassignTags,
|
|
1075
484
|
returnEntity: options?.returnEntity
|
|
1076
485
|
});
|
|
1077
|
-
const reqOpts =
|
|
486
|
+
const reqOpts = bulkUpdatePipelineTags(payload);
|
|
1078
487
|
sideEffects?.onSiteCall?.();
|
|
1079
488
|
try {
|
|
1080
489
|
const result = await httpClient.request(reqOpts);
|
|
@@ -1086,27 +495,28 @@ async function bulkUpdateCardTags2(cardIds, options) {
|
|
|
1086
495
|
{
|
|
1087
496
|
spreadPathsToArguments: {},
|
|
1088
497
|
explicitPathsToArguments: {
|
|
1089
|
-
|
|
498
|
+
pipelineIds: "$[0]",
|
|
1090
499
|
assignTags: "$[1].assignTags",
|
|
1091
500
|
unassignTags: "$[1].unassignTags",
|
|
1092
501
|
returnEntity: "$[1].returnEntity"
|
|
1093
502
|
},
|
|
1094
503
|
singleArgumentUnchanged: false
|
|
1095
504
|
},
|
|
1096
|
-
["
|
|
505
|
+
["pipelineIds", "options"]
|
|
1097
506
|
);
|
|
1098
507
|
sideEffects?.onError?.(err);
|
|
1099
508
|
throw transformedError;
|
|
1100
509
|
}
|
|
1101
510
|
}
|
|
1102
|
-
async function
|
|
511
|
+
async function bulkUpdatePipelineTagsByFilter2(filter, options) {
|
|
1103
512
|
const { httpClient, sideEffects } = arguments[2];
|
|
1104
513
|
const payload = renameKeysFromSDKRequestToRESTRequest({
|
|
1105
514
|
filter,
|
|
1106
515
|
assignTags: options?.assignTags,
|
|
1107
|
-
unassignTags: options?.unassignTags
|
|
516
|
+
unassignTags: options?.unassignTags,
|
|
517
|
+
returnEntity: options?.returnEntity
|
|
1108
518
|
});
|
|
1109
|
-
const reqOpts =
|
|
519
|
+
const reqOpts = bulkUpdatePipelineTagsByFilter(payload);
|
|
1110
520
|
sideEffects?.onSiteCall?.();
|
|
1111
521
|
try {
|
|
1112
522
|
const result = await httpClient.request(reqOpts);
|
|
@@ -1120,7 +530,8 @@ async function bulkUpdateCardTagsByFilter2(filter, options) {
|
|
|
1120
530
|
explicitPathsToArguments: {
|
|
1121
531
|
filter: "$[0]",
|
|
1122
532
|
assignTags: "$[1].assignTags",
|
|
1123
|
-
unassignTags: "$[1].unassignTags"
|
|
533
|
+
unassignTags: "$[1].unassignTags",
|
|
534
|
+
returnEntity: "$[1].returnEntity"
|
|
1124
535
|
},
|
|
1125
536
|
singleArgumentUnchanged: false
|
|
1126
537
|
},
|
|
@@ -1131,33 +542,17 @@ async function bulkUpdateCardTagsByFilter2(filter, options) {
|
|
|
1131
542
|
}
|
|
1132
543
|
}
|
|
1133
544
|
export {
|
|
1134
|
-
AggregationType,
|
|
1135
|
-
Interval,
|
|
1136
|
-
MissingValues,
|
|
1137
|
-
Mode,
|
|
1138
|
-
NameFormat,
|
|
1139
|
-
NestedAggregationType,
|
|
1140
545
|
Outcome,
|
|
1141
|
-
Priority,
|
|
1142
|
-
ScalarType,
|
|
1143
|
-
SortDirection,
|
|
1144
546
|
SortOrder,
|
|
1145
|
-
SortType,
|
|
1146
547
|
WebhookIdentityType,
|
|
1147
|
-
|
|
1148
|
-
|
|
1149
|
-
|
|
1150
|
-
|
|
1151
|
-
|
|
1152
|
-
|
|
1153
|
-
|
|
1154
|
-
|
|
1155
|
-
moveCard2 as moveCard,
|
|
1156
|
-
queryCards2 as queryCards,
|
|
1157
|
-
searchCards2 as searchCards,
|
|
1158
|
-
searchCardsByStage2 as searchCardsByStage,
|
|
1159
|
-
typedQueryCards,
|
|
1160
|
-
updateCard2 as updateCard,
|
|
548
|
+
bulkUpdatePipelineTags2 as bulkUpdatePipelineTags,
|
|
549
|
+
bulkUpdatePipelineTagsByFilter2 as bulkUpdatePipelineTagsByFilter,
|
|
550
|
+
createPipeline2 as createPipeline,
|
|
551
|
+
deletePipeline2 as deletePipeline,
|
|
552
|
+
getPipeline2 as getPipeline,
|
|
553
|
+
queryPipelines2 as queryPipelines,
|
|
554
|
+
typedQueryPipelines,
|
|
555
|
+
updatePipeline2 as updatePipeline,
|
|
1161
556
|
utils
|
|
1162
557
|
};
|
|
1163
558
|
//# sourceMappingURL=index.typings.mjs.map
|