@wix/auto_sdk_crm_tasks 1.0.6 → 1.0.7

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.
Files changed (134) hide show
  1. package/build/{internal/cjs/src/crm-tasks-v2-task-tasks.universal.d.ts → crm-tasks-v2-task-tasks.universal-DHOV27KP.d.mts} +67 -238
  2. package/build/{cjs/src/crm-tasks-v2-task-tasks.universal.d.ts → crm-tasks-v2-task-tasks.universal-DHOV27KP.d.ts} +67 -238
  3. package/build/index.d.mts +115 -0
  4. package/build/index.d.ts +115 -0
  5. package/build/index.js +640 -0
  6. package/build/index.js.map +1 -0
  7. package/build/index.mjs +601 -0
  8. package/build/index.mjs.map +1 -0
  9. package/build/{es/src/crm-tasks-v2-task-tasks.universal.d.ts → internal/crm-tasks-v2-task-tasks.universal-DHOV27KP.d.mts} +67 -238
  10. package/build/internal/{es/src/crm-tasks-v2-task-tasks.universal.d.ts → crm-tasks-v2-task-tasks.universal-DHOV27KP.d.ts} +67 -238
  11. package/build/internal/index.d.mts +115 -0
  12. package/build/internal/index.d.ts +115 -0
  13. package/build/internal/index.js +640 -0
  14. package/build/internal/index.js.map +1 -0
  15. package/build/internal/index.mjs +601 -0
  16. package/build/internal/index.mjs.map +1 -0
  17. package/build/internal/meta.d.mts +290 -0
  18. package/build/internal/meta.d.ts +290 -0
  19. package/build/internal/meta.js +386 -0
  20. package/build/internal/meta.js.map +1 -0
  21. package/build/internal/meta.mjs +353 -0
  22. package/build/internal/meta.mjs.map +1 -0
  23. package/build/meta.d.mts +290 -0
  24. package/build/meta.d.ts +290 -0
  25. package/build/meta.js +386 -0
  26. package/build/meta.js.map +1 -0
  27. package/build/meta.mjs +353 -0
  28. package/build/meta.mjs.map +1 -0
  29. package/package.json +13 -12
  30. package/build/cjs/index.d.ts +0 -1
  31. package/build/cjs/index.js +0 -18
  32. package/build/cjs/index.js.map +0 -1
  33. package/build/cjs/index.typings.d.ts +0 -1
  34. package/build/cjs/index.typings.js +0 -18
  35. package/build/cjs/index.typings.js.map +0 -1
  36. package/build/cjs/meta.d.ts +0 -1
  37. package/build/cjs/meta.js +0 -18
  38. package/build/cjs/meta.js.map +0 -1
  39. package/build/cjs/src/crm-tasks-v2-task-tasks.context.d.ts +0 -32
  40. package/build/cjs/src/crm-tasks-v2-task-tasks.context.js +0 -40
  41. package/build/cjs/src/crm-tasks-v2-task-tasks.context.js.map +0 -1
  42. package/build/cjs/src/crm-tasks-v2-task-tasks.http.d.ts +0 -47
  43. package/build/cjs/src/crm-tasks-v2-task-tasks.http.js +0 -264
  44. package/build/cjs/src/crm-tasks-v2-task-tasks.http.js.map +0 -1
  45. package/build/cjs/src/crm-tasks-v2-task-tasks.meta.d.ts +0 -27
  46. package/build/cjs/src/crm-tasks-v2-task-tasks.meta.js +0 -161
  47. package/build/cjs/src/crm-tasks-v2-task-tasks.meta.js.map +0 -1
  48. package/build/cjs/src/crm-tasks-v2-task-tasks.public.d.ts +0 -94
  49. package/build/cjs/src/crm-tasks-v2-task-tasks.public.js +0 -102
  50. package/build/cjs/src/crm-tasks-v2-task-tasks.public.js.map +0 -1
  51. package/build/cjs/src/crm-tasks-v2-task-tasks.types.d.ts +0 -528
  52. package/build/cjs/src/crm-tasks-v2-task-tasks.types.js +0 -41
  53. package/build/cjs/src/crm-tasks-v2-task-tasks.types.js.map +0 -1
  54. package/build/cjs/src/crm-tasks-v2-task-tasks.universal.js +0 -363
  55. package/build/cjs/src/crm-tasks-v2-task-tasks.universal.js.map +0 -1
  56. package/build/es/index.d.ts +0 -1
  57. package/build/es/index.js +0 -2
  58. package/build/es/index.js.map +0 -1
  59. package/build/es/index.typings.d.ts +0 -1
  60. package/build/es/index.typings.js +0 -2
  61. package/build/es/index.typings.js.map +0 -1
  62. package/build/es/meta.d.ts +0 -1
  63. package/build/es/meta.js +0 -2
  64. package/build/es/meta.js.map +0 -1
  65. package/build/es/package.json +0 -3
  66. package/build/es/src/crm-tasks-v2-task-tasks.context.d.ts +0 -32
  67. package/build/es/src/crm-tasks-v2-task-tasks.context.js +0 -32
  68. package/build/es/src/crm-tasks-v2-task-tasks.context.js.map +0 -1
  69. package/build/es/src/crm-tasks-v2-task-tasks.http.d.ts +0 -47
  70. package/build/es/src/crm-tasks-v2-task-tasks.http.js +0 -254
  71. package/build/es/src/crm-tasks-v2-task-tasks.http.js.map +0 -1
  72. package/build/es/src/crm-tasks-v2-task-tasks.meta.d.ts +0 -27
  73. package/build/es/src/crm-tasks-v2-task-tasks.meta.js +0 -128
  74. package/build/es/src/crm-tasks-v2-task-tasks.meta.js.map +0 -1
  75. package/build/es/src/crm-tasks-v2-task-tasks.public.d.ts +0 -94
  76. package/build/es/src/crm-tasks-v2-task-tasks.public.js +0 -87
  77. package/build/es/src/crm-tasks-v2-task-tasks.public.js.map +0 -1
  78. package/build/es/src/crm-tasks-v2-task-tasks.types.d.ts +0 -528
  79. package/build/es/src/crm-tasks-v2-task-tasks.types.js +0 -38
  80. package/build/es/src/crm-tasks-v2-task-tasks.types.js.map +0 -1
  81. package/build/es/src/crm-tasks-v2-task-tasks.universal.js +0 -330
  82. package/build/es/src/crm-tasks-v2-task-tasks.universal.js.map +0 -1
  83. package/build/internal/cjs/index.d.ts +0 -1
  84. package/build/internal/cjs/index.js +0 -18
  85. package/build/internal/cjs/index.js.map +0 -1
  86. package/build/internal/cjs/index.typings.d.ts +0 -1
  87. package/build/internal/cjs/index.typings.js +0 -18
  88. package/build/internal/cjs/index.typings.js.map +0 -1
  89. package/build/internal/cjs/meta.d.ts +0 -1
  90. package/build/internal/cjs/meta.js +0 -18
  91. package/build/internal/cjs/meta.js.map +0 -1
  92. package/build/internal/cjs/src/crm-tasks-v2-task-tasks.context.d.ts +0 -32
  93. package/build/internal/cjs/src/crm-tasks-v2-task-tasks.context.js +0 -40
  94. package/build/internal/cjs/src/crm-tasks-v2-task-tasks.context.js.map +0 -1
  95. package/build/internal/cjs/src/crm-tasks-v2-task-tasks.http.d.ts +0 -47
  96. package/build/internal/cjs/src/crm-tasks-v2-task-tasks.http.js +0 -264
  97. package/build/internal/cjs/src/crm-tasks-v2-task-tasks.http.js.map +0 -1
  98. package/build/internal/cjs/src/crm-tasks-v2-task-tasks.meta.d.ts +0 -27
  99. package/build/internal/cjs/src/crm-tasks-v2-task-tasks.meta.js +0 -161
  100. package/build/internal/cjs/src/crm-tasks-v2-task-tasks.meta.js.map +0 -1
  101. package/build/internal/cjs/src/crm-tasks-v2-task-tasks.public.d.ts +0 -94
  102. package/build/internal/cjs/src/crm-tasks-v2-task-tasks.public.js +0 -102
  103. package/build/internal/cjs/src/crm-tasks-v2-task-tasks.public.js.map +0 -1
  104. package/build/internal/cjs/src/crm-tasks-v2-task-tasks.types.d.ts +0 -528
  105. package/build/internal/cjs/src/crm-tasks-v2-task-tasks.types.js +0 -41
  106. package/build/internal/cjs/src/crm-tasks-v2-task-tasks.types.js.map +0 -1
  107. package/build/internal/cjs/src/crm-tasks-v2-task-tasks.universal.js +0 -363
  108. package/build/internal/cjs/src/crm-tasks-v2-task-tasks.universal.js.map +0 -1
  109. package/build/internal/es/index.d.ts +0 -1
  110. package/build/internal/es/index.js +0 -2
  111. package/build/internal/es/index.js.map +0 -1
  112. package/build/internal/es/index.typings.d.ts +0 -1
  113. package/build/internal/es/index.typings.js +0 -2
  114. package/build/internal/es/index.typings.js.map +0 -1
  115. package/build/internal/es/meta.d.ts +0 -1
  116. package/build/internal/es/meta.js +0 -2
  117. package/build/internal/es/meta.js.map +0 -1
  118. package/build/internal/es/src/crm-tasks-v2-task-tasks.context.d.ts +0 -32
  119. package/build/internal/es/src/crm-tasks-v2-task-tasks.context.js +0 -32
  120. package/build/internal/es/src/crm-tasks-v2-task-tasks.context.js.map +0 -1
  121. package/build/internal/es/src/crm-tasks-v2-task-tasks.http.d.ts +0 -47
  122. package/build/internal/es/src/crm-tasks-v2-task-tasks.http.js +0 -254
  123. package/build/internal/es/src/crm-tasks-v2-task-tasks.http.js.map +0 -1
  124. package/build/internal/es/src/crm-tasks-v2-task-tasks.meta.d.ts +0 -27
  125. package/build/internal/es/src/crm-tasks-v2-task-tasks.meta.js +0 -128
  126. package/build/internal/es/src/crm-tasks-v2-task-tasks.meta.js.map +0 -1
  127. package/build/internal/es/src/crm-tasks-v2-task-tasks.public.d.ts +0 -94
  128. package/build/internal/es/src/crm-tasks-v2-task-tasks.public.js +0 -87
  129. package/build/internal/es/src/crm-tasks-v2-task-tasks.public.js.map +0 -1
  130. package/build/internal/es/src/crm-tasks-v2-task-tasks.types.d.ts +0 -528
  131. package/build/internal/es/src/crm-tasks-v2-task-tasks.types.js +0 -38
  132. package/build/internal/es/src/crm-tasks-v2-task-tasks.types.js.map +0 -1
  133. package/build/internal/es/src/crm-tasks-v2-task-tasks.universal.js +0 -330
  134. package/build/internal/es/src/crm-tasks-v2-task-tasks.universal.js.map +0 -1
@@ -0,0 +1,290 @@
1
+ import { j as CreateTaskRequest$1, k as CreateTaskResponse$1, G as GetTaskRequest$1, m as GetTaskResponse$1, n as UpdateTaskRequest$1, o as UpdateTaskResponse$1, D as DeleteTaskRequest$1, p as DeleteTaskResponse$1, Q as QueryTasksRequest$1, u as QueryTasksResponse$1, x as CountTasksRequest$1, b as CountTasksResponse$1, F as MoveTaskAfterRequest$1, H as MoveTaskAfterResponse$1 } from './crm-tasks-v2-task-tasks.universal-DHOV27KP.js';
2
+
3
+ interface Task {
4
+ /**
5
+ * Task ID.
6
+ * @format GUID
7
+ * @readonly
8
+ */
9
+ id?: string | null;
10
+ /**
11
+ * Revision number, which increments by 1 each time the task is updated. To prevent conflicting changes, the existing `revision` must be used when updating a task.
12
+ * @readonly
13
+ */
14
+ revision?: string | null;
15
+ /**
16
+ * Title of the task.
17
+ * @minLength 1
18
+ * @maxLength 250
19
+ */
20
+ title?: string | null;
21
+ /**
22
+ * Description of the task.
23
+ * @minLength 1
24
+ * @maxLength 500
25
+ */
26
+ description?: string | null;
27
+ /**
28
+ * Date and time the task was created.
29
+ * @readonly
30
+ */
31
+ createdDate?: Date | null;
32
+ /**
33
+ * Date and time the task was last updated.
34
+ * @readonly
35
+ */
36
+ updatedDate?: Date | null;
37
+ /** Due date for the task. */
38
+ dueDate?: Date | null;
39
+ /**
40
+ * Status of the task.
41
+ *
42
+ * Default: `ACTION_NEEDED`
43
+ */
44
+ status?: TaskStatus;
45
+ /** Details about the task source. */
46
+ source?: TaskSource;
47
+ /** Information about the contact associated with the task. */
48
+ contact?: ContactInfo;
49
+ }
50
+ /** Possible statuses in which the task may be. */
51
+ declare enum TaskStatus {
52
+ /** Action needed. */
53
+ ACTION_NEEDED = "ACTION_NEEDED",
54
+ /** Task completed. */
55
+ COMPLETED = "COMPLETED"
56
+ }
57
+ interface TaskSource {
58
+ /**
59
+ * How the task was created.
60
+ * @readonly
61
+ */
62
+ sourceType?: SourceType;
63
+ /**
64
+ * App ID, if the task was created by an app.
65
+ * @format GUID
66
+ * @readonly
67
+ */
68
+ appId?: string | null;
69
+ /**
70
+ * User ID, if the task was created by a Wix user.
71
+ * @format GUID
72
+ * @readonly
73
+ */
74
+ userId?: string | null;
75
+ }
76
+ /** Possible sources that can create tasks. */
77
+ declare enum SourceType {
78
+ /** Task was created by an app. */
79
+ APP = "APP",
80
+ /** Task was created by a Wix user. */
81
+ USER = "USER"
82
+ }
83
+ interface ContactInfo {
84
+ /**
85
+ * ID of the contact associated with the task.
86
+ * @format GUID
87
+ */
88
+ id?: string | null;
89
+ /**
90
+ * Contact's first name.
91
+ * @readonly
92
+ */
93
+ firstName?: string | null;
94
+ /**
95
+ * Contact's last name.
96
+ * @readonly
97
+ */
98
+ lastName?: string | null;
99
+ /**
100
+ * Contact's image URL.
101
+ * @readonly
102
+ */
103
+ imageUrl?: string | null;
104
+ /**
105
+ * Contact's primary email.
106
+ * @readonly
107
+ */
108
+ email?: string | null;
109
+ /**
110
+ * Contact's primary phone.
111
+ * @readonly
112
+ */
113
+ phone?: string | null;
114
+ }
115
+ interface CreateTaskRequest {
116
+ /** Task to create. */
117
+ task: Task;
118
+ }
119
+ interface CreateTaskResponse {
120
+ /** The created task. */
121
+ task?: Task;
122
+ }
123
+ interface GetTaskRequest {
124
+ /**
125
+ * ID of the task to retrieve.
126
+ * @format GUID
127
+ */
128
+ taskId: string;
129
+ }
130
+ interface GetTaskResponse {
131
+ /** The retrieved task. */
132
+ task?: Task;
133
+ }
134
+ interface UpdateTaskRequest {
135
+ /** Task to update. */
136
+ task: Task;
137
+ }
138
+ interface UpdateTaskResponse {
139
+ /** The updated task. */
140
+ task?: Task;
141
+ }
142
+ interface DeleteTaskRequest {
143
+ /**
144
+ * ID of the task to delete.
145
+ * @format GUID
146
+ */
147
+ taskId: string;
148
+ }
149
+ interface DeleteTaskResponse {
150
+ }
151
+ interface QueryTasksRequest {
152
+ /** Query options. */
153
+ query?: CursorQuery;
154
+ }
155
+ interface CursorQuery extends CursorQueryPagingMethodOneOf {
156
+ /** Cursor token pointing to a page of results. Not used in the first request. Following requests use the cursor token and not `filter` or `sort`. */
157
+ cursorPaging?: CursorPaging;
158
+ /**
159
+ * Filter object in the following format:
160
+ * `"filter" : {
161
+ * "fieldName1": "value1",
162
+ * "fieldName2":{"$operator":"value2"}
163
+ * }`
164
+ * Example of operators: `$eq`, `$ne`, `$lt`, `$lte`, `$gt`, `$gte`, `$in`, `$hasSome`, `$hasAll`, `$startsWith`, `$contains`
165
+ */
166
+ filter?: Record<string, any> | null;
167
+ /**
168
+ * Sort object in the following format:
169
+ * `[{"fieldName":"sortField1","order":"ASC"},{"fieldName":"sortField2","order":"DESC"}]`
170
+ */
171
+ sort?: Sorting[];
172
+ }
173
+ /** @oneof */
174
+ interface CursorQueryPagingMethodOneOf {
175
+ /** Cursor token pointing to a page of results. Not used in the first request. Following requests use the cursor token and not `filter` or `sort`. */
176
+ cursorPaging?: CursorPaging;
177
+ }
178
+ interface Sorting {
179
+ /** Name of the field to sort by. */
180
+ fieldName?: string;
181
+ /** Sort order. */
182
+ order?: SortOrder;
183
+ }
184
+ declare enum SortOrder {
185
+ /** Sort by ascending order. */
186
+ ASC = "ASC",
187
+ /** Sort by descending order. */
188
+ DESC = "DESC"
189
+ }
190
+ interface CursorPaging {
191
+ /**
192
+ * Number of items to load.
193
+ * @max 1000
194
+ */
195
+ limit?: number | null;
196
+ /**
197
+ * Pointer to the next or previous page in the list of results.
198
+ *
199
+ * You can get the relevant cursor token
200
+ * from the `pagingMetadata` object in the previous call's response.
201
+ * Not relevant for the first request.
202
+ */
203
+ cursor?: string | null;
204
+ }
205
+ interface QueryTasksResponse {
206
+ /** The retrieved tasks. */
207
+ tasks?: Task[];
208
+ /** Paging metadata. */
209
+ pagingMetadata?: CursorPagingMetadata;
210
+ }
211
+ interface CursorPagingMetadata {
212
+ /** Number of items returned in the response. */
213
+ count?: number | null;
214
+ /** Offset that was requested. */
215
+ cursors?: Cursors;
216
+ /**
217
+ * Indicates if there are more results after the current page.
218
+ * If `true`, another page of results can be retrieved.
219
+ * If `false`, this is the last page.
220
+ */
221
+ hasNext?: boolean | null;
222
+ }
223
+ interface Cursors {
224
+ /** Cursor pointing to next page in the list of results. */
225
+ next?: string | null;
226
+ /** Cursor pointing to previous page in the list of results. */
227
+ prev?: string | null;
228
+ }
229
+ interface CountTasksRequest {
230
+ /**
231
+ * Filter which tasks to count. See supported filters ([REST](https://dev.wix.com/docs/rest/api-reference/crm/tasks/task-v2/filter-and-sort)| [SDK](https://dev.wix.com/docs/sdk/backend-modules/crm/tasks/query-tasks)).
232
+ *
233
+ * Filter tasks in the following format:
234
+ *
235
+ * `"filter" : {
236
+ * "fieldName1": "value1",
237
+ * "fieldName2":{"$operator":"value2"}
238
+ * }`
239
+ *
240
+ * Example of operators: `$eq`, `$ne`, `$lt`, `$lte`, `$gt`, `$gte`, `$in`, `$hasSome`, `$hasAll`, `$startsWith`, `$contains`.
241
+ */
242
+ filter?: Record<string, any> | null;
243
+ }
244
+ interface CountTasksResponse {
245
+ /** The number of tasks that match the specified filter. */
246
+ count?: number;
247
+ }
248
+ interface MoveTaskAfterRequest {
249
+ /**
250
+ * ID of the task to move.
251
+ * @format GUID
252
+ */
253
+ taskId: string;
254
+ /**
255
+ * The ID of the task after which the moved task is positioned in the task display.
256
+ * If `beforeTaskId` is not specified, the moved task is positioned first in the task display.
257
+ * @format GUID
258
+ */
259
+ beforeTaskId?: string | null;
260
+ }
261
+ interface MoveTaskAfterResponse {
262
+ }
263
+
264
+ type __PublicMethodMetaInfo<K = string, M = unknown, T = unknown, S = unknown, Q = unknown, R = unknown> = {
265
+ getUrl: (context: any) => string;
266
+ httpMethod: K;
267
+ path: string;
268
+ pathParams: M;
269
+ __requestType: T;
270
+ __originalRequestType: S;
271
+ __responseType: Q;
272
+ __originalResponseType: R;
273
+ };
274
+ declare function createTask(): __PublicMethodMetaInfo<'POST', {}, CreateTaskRequest$1, CreateTaskRequest, CreateTaskResponse$1, CreateTaskResponse>;
275
+ declare function getTask(): __PublicMethodMetaInfo<'GET', {
276
+ taskId: string;
277
+ }, GetTaskRequest$1, GetTaskRequest, GetTaskResponse$1, GetTaskResponse>;
278
+ declare function updateTask(): __PublicMethodMetaInfo<'PATCH', {
279
+ taskId: string;
280
+ }, UpdateTaskRequest$1, UpdateTaskRequest, UpdateTaskResponse$1, UpdateTaskResponse>;
281
+ declare function deleteTask(): __PublicMethodMetaInfo<'DELETE', {
282
+ taskId: string;
283
+ }, DeleteTaskRequest$1, DeleteTaskRequest, DeleteTaskResponse$1, DeleteTaskResponse>;
284
+ declare function queryTasks(): __PublicMethodMetaInfo<'POST', {}, QueryTasksRequest$1, QueryTasksRequest, QueryTasksResponse$1, QueryTasksResponse>;
285
+ declare function countTasks(): __PublicMethodMetaInfo<'POST', {}, CountTasksRequest$1, CountTasksRequest, CountTasksResponse$1, CountTasksResponse>;
286
+ declare function moveTaskAfter(): __PublicMethodMetaInfo<'POST', {
287
+ taskId: string;
288
+ }, MoveTaskAfterRequest$1, MoveTaskAfterRequest, MoveTaskAfterResponse$1, MoveTaskAfterResponse>;
289
+
290
+ export { type __PublicMethodMetaInfo, countTasks, createTask, deleteTask, getTask, moveTaskAfter, queryTasks, updateTask };
@@ -0,0 +1,386 @@
1
+ "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __export = (target, all) => {
7
+ for (var name in all)
8
+ __defProp(target, name, { get: all[name], enumerable: true });
9
+ };
10
+ var __copyProps = (to, from, except, desc) => {
11
+ if (from && typeof from === "object" || typeof from === "function") {
12
+ for (let key of __getOwnPropNames(from))
13
+ if (!__hasOwnProp.call(to, key) && key !== except)
14
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
15
+ }
16
+ return to;
17
+ };
18
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
+
20
+ // meta.ts
21
+ var meta_exports = {};
22
+ __export(meta_exports, {
23
+ countTasks: () => countTasks2,
24
+ createTask: () => createTask2,
25
+ deleteTask: () => deleteTask2,
26
+ getTask: () => getTask2,
27
+ moveTaskAfter: () => moveTaskAfter2,
28
+ queryTasks: () => queryTasks2,
29
+ updateTask: () => updateTask2
30
+ });
31
+ module.exports = __toCommonJS(meta_exports);
32
+
33
+ // src/crm-tasks-v2-task-tasks.http.ts
34
+ var import_rest_modules = require("@wix/sdk-runtime/rest-modules");
35
+ var import_timestamp = require("@wix/sdk-runtime/transformations/timestamp");
36
+ var import_timestamp2 = require("@wix/sdk-runtime/transformations/timestamp");
37
+ var import_field_mask = require("@wix/sdk-runtime/transformations/field-mask");
38
+ var import_transform_paths = require("@wix/sdk-runtime/transformations/transform-paths");
39
+ var import_rest_modules2 = require("@wix/sdk-runtime/rest-modules");
40
+ function resolveWixCrmTasksV2TasksUrl(opts) {
41
+ const domainToMappings = {
42
+ "manage._base_domain_": [
43
+ {
44
+ srcPath: "/_api/tasks-app",
45
+ destPath: ""
46
+ }
47
+ ],
48
+ "www.wixapis.com": [
49
+ {
50
+ srcPath: "/crm/tasks/v2/tasks",
51
+ destPath: "/v2/tasks"
52
+ }
53
+ ]
54
+ };
55
+ return (0, import_rest_modules2.resolveUrl)(Object.assign(opts, { domainToMappings }));
56
+ }
57
+ var PACKAGE_NAME = "@wix/auto_sdk_crm_tasks";
58
+ function createTask(payload) {
59
+ function __createTask({ host }) {
60
+ const serializedData = (0, import_transform_paths.transformPaths)(payload, [
61
+ {
62
+ transformFn: import_timestamp.transformSDKTimestampToRESTTimestamp,
63
+ paths: [
64
+ { path: "task.createdDate" },
65
+ { path: "task.updatedDate" },
66
+ { path: "task.dueDate" }
67
+ ]
68
+ }
69
+ ]);
70
+ const metadata = {
71
+ entityFqdn: "wix.crm.tasks.v2.task",
72
+ method: "POST",
73
+ methodFqn: "wix.crm.tasks.v2.Tasks.CreateTask",
74
+ packageName: PACKAGE_NAME,
75
+ url: resolveWixCrmTasksV2TasksUrl({
76
+ protoPath: "/v2/tasks",
77
+ data: serializedData,
78
+ host
79
+ }),
80
+ data: serializedData,
81
+ transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
82
+ {
83
+ transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
84
+ paths: [
85
+ { path: "task.createdDate" },
86
+ { path: "task.updatedDate" },
87
+ { path: "task.dueDate" }
88
+ ]
89
+ }
90
+ ])
91
+ };
92
+ return metadata;
93
+ }
94
+ return __createTask;
95
+ }
96
+ function getTask(payload) {
97
+ function __getTask({ host }) {
98
+ const metadata = {
99
+ entityFqdn: "wix.crm.tasks.v2.task",
100
+ method: "GET",
101
+ methodFqn: "wix.crm.tasks.v2.Tasks.GetTask",
102
+ packageName: PACKAGE_NAME,
103
+ url: resolveWixCrmTasksV2TasksUrl({
104
+ protoPath: "/v2/tasks/{taskId}",
105
+ data: payload,
106
+ host
107
+ }),
108
+ params: (0, import_rest_modules.toURLSearchParams)(payload),
109
+ transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
110
+ {
111
+ transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
112
+ paths: [
113
+ { path: "task.createdDate" },
114
+ { path: "task.updatedDate" },
115
+ { path: "task.dueDate" }
116
+ ]
117
+ }
118
+ ])
119
+ };
120
+ return metadata;
121
+ }
122
+ return __getTask;
123
+ }
124
+ function updateTask(payload) {
125
+ function __updateTask({ host }) {
126
+ const serializedData = (0, import_transform_paths.transformPaths)(payload, [
127
+ {
128
+ transformFn: import_field_mask.transformSDKFieldMaskToRESTFieldMask,
129
+ paths: [{ path: "mask" }]
130
+ },
131
+ {
132
+ transformFn: import_timestamp.transformSDKTimestampToRESTTimestamp,
133
+ paths: [
134
+ { path: "task.createdDate" },
135
+ { path: "task.updatedDate" },
136
+ { path: "task.dueDate" }
137
+ ]
138
+ }
139
+ ]);
140
+ const metadata = {
141
+ entityFqdn: "wix.crm.tasks.v2.task",
142
+ method: "PATCH",
143
+ methodFqn: "wix.crm.tasks.v2.Tasks.UpdateTask",
144
+ packageName: PACKAGE_NAME,
145
+ url: resolveWixCrmTasksV2TasksUrl({
146
+ protoPath: "/v2/tasks/{task.id}",
147
+ data: serializedData,
148
+ host
149
+ }),
150
+ data: serializedData,
151
+ transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
152
+ {
153
+ transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
154
+ paths: [
155
+ { path: "task.createdDate" },
156
+ { path: "task.updatedDate" },
157
+ { path: "task.dueDate" }
158
+ ]
159
+ }
160
+ ])
161
+ };
162
+ return metadata;
163
+ }
164
+ return __updateTask;
165
+ }
166
+ function deleteTask(payload) {
167
+ function __deleteTask({ host }) {
168
+ const metadata = {
169
+ entityFqdn: "wix.crm.tasks.v2.task",
170
+ method: "DELETE",
171
+ methodFqn: "wix.crm.tasks.v2.Tasks.DeleteTask",
172
+ packageName: PACKAGE_NAME,
173
+ url: resolveWixCrmTasksV2TasksUrl({
174
+ protoPath: "/v2/tasks/{taskId}",
175
+ data: payload,
176
+ host
177
+ }),
178
+ params: (0, import_rest_modules.toURLSearchParams)(payload)
179
+ };
180
+ return metadata;
181
+ }
182
+ return __deleteTask;
183
+ }
184
+ function queryTasks(payload) {
185
+ function __queryTasks({ host }) {
186
+ const metadata = {
187
+ entityFqdn: "wix.crm.tasks.v2.task",
188
+ method: "POST",
189
+ methodFqn: "wix.crm.tasks.v2.Tasks.QueryTasks",
190
+ packageName: PACKAGE_NAME,
191
+ url: resolveWixCrmTasksV2TasksUrl({
192
+ protoPath: "/v2/tasks/query",
193
+ data: payload,
194
+ host
195
+ }),
196
+ data: payload,
197
+ transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
198
+ {
199
+ transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
200
+ paths: [
201
+ { path: "tasks.createdDate" },
202
+ { path: "tasks.updatedDate" },
203
+ { path: "tasks.dueDate" }
204
+ ]
205
+ }
206
+ ])
207
+ };
208
+ return metadata;
209
+ }
210
+ return __queryTasks;
211
+ }
212
+ function countTasks(payload) {
213
+ function __countTasks({ host }) {
214
+ const metadata = {
215
+ entityFqdn: "wix.crm.tasks.v2.task",
216
+ method: "POST",
217
+ methodFqn: "wix.crm.tasks.v2.Tasks.CountTasks",
218
+ packageName: PACKAGE_NAME,
219
+ url: resolveWixCrmTasksV2TasksUrl({
220
+ protoPath: "/v2/tasks/count",
221
+ data: payload,
222
+ host
223
+ }),
224
+ data: payload
225
+ };
226
+ return metadata;
227
+ }
228
+ return __countTasks;
229
+ }
230
+ function moveTaskAfter(payload) {
231
+ function __moveTaskAfter({ host }) {
232
+ const metadata = {
233
+ entityFqdn: "wix.crm.tasks.v2.task",
234
+ method: "POST",
235
+ methodFqn: "wix.crm.tasks.v2.Tasks.MoveTaskAfter",
236
+ packageName: PACKAGE_NAME,
237
+ url: resolveWixCrmTasksV2TasksUrl({
238
+ protoPath: "/v2/tasks/{taskId}/move-after",
239
+ data: payload,
240
+ host
241
+ }),
242
+ data: payload
243
+ };
244
+ return metadata;
245
+ }
246
+ return __moveTaskAfter;
247
+ }
248
+
249
+ // src/crm-tasks-v2-task-tasks.meta.ts
250
+ function createTask2() {
251
+ const payload = {};
252
+ const getRequestOptions = createTask(payload);
253
+ const getUrl = (context) => {
254
+ const { url } = getRequestOptions(context);
255
+ return url;
256
+ };
257
+ return {
258
+ getUrl,
259
+ httpMethod: "POST",
260
+ path: "/v2/tasks",
261
+ pathParams: {},
262
+ __requestType: null,
263
+ __originalRequestType: null,
264
+ __responseType: null,
265
+ __originalResponseType: null
266
+ };
267
+ }
268
+ function getTask2() {
269
+ const payload = { taskId: ":taskId" };
270
+ const getRequestOptions = getTask(payload);
271
+ const getUrl = (context) => {
272
+ const { url } = getRequestOptions(context);
273
+ return url;
274
+ };
275
+ return {
276
+ getUrl,
277
+ httpMethod: "GET",
278
+ path: "/v2/tasks/{taskId}",
279
+ pathParams: { taskId: "taskId" },
280
+ __requestType: null,
281
+ __originalRequestType: null,
282
+ __responseType: null,
283
+ __originalResponseType: null
284
+ };
285
+ }
286
+ function updateTask2() {
287
+ const payload = { task: { id: ":taskId" } };
288
+ const getRequestOptions = updateTask(payload);
289
+ const getUrl = (context) => {
290
+ const { url } = getRequestOptions(context);
291
+ return url;
292
+ };
293
+ return {
294
+ getUrl,
295
+ httpMethod: "PATCH",
296
+ path: "/v2/tasks/{task.id}",
297
+ pathParams: { taskId: "taskId" },
298
+ __requestType: null,
299
+ __originalRequestType: null,
300
+ __responseType: null,
301
+ __originalResponseType: null
302
+ };
303
+ }
304
+ function deleteTask2() {
305
+ const payload = { taskId: ":taskId" };
306
+ const getRequestOptions = deleteTask(payload);
307
+ const getUrl = (context) => {
308
+ const { url } = getRequestOptions(context);
309
+ return url;
310
+ };
311
+ return {
312
+ getUrl,
313
+ httpMethod: "DELETE",
314
+ path: "/v2/tasks/{taskId}",
315
+ pathParams: { taskId: "taskId" },
316
+ __requestType: null,
317
+ __originalRequestType: null,
318
+ __responseType: null,
319
+ __originalResponseType: null
320
+ };
321
+ }
322
+ function queryTasks2() {
323
+ const payload = {};
324
+ const getRequestOptions = queryTasks(payload);
325
+ const getUrl = (context) => {
326
+ const { url } = getRequestOptions(context);
327
+ return url;
328
+ };
329
+ return {
330
+ getUrl,
331
+ httpMethod: "POST",
332
+ path: "/v2/tasks/query",
333
+ pathParams: {},
334
+ __requestType: null,
335
+ __originalRequestType: null,
336
+ __responseType: null,
337
+ __originalResponseType: null
338
+ };
339
+ }
340
+ function countTasks2() {
341
+ const payload = {};
342
+ const getRequestOptions = countTasks(payload);
343
+ const getUrl = (context) => {
344
+ const { url } = getRequestOptions(context);
345
+ return url;
346
+ };
347
+ return {
348
+ getUrl,
349
+ httpMethod: "POST",
350
+ path: "/v2/tasks/count",
351
+ pathParams: {},
352
+ __requestType: null,
353
+ __originalRequestType: null,
354
+ __responseType: null,
355
+ __originalResponseType: null
356
+ };
357
+ }
358
+ function moveTaskAfter2() {
359
+ const payload = { taskId: ":taskId" };
360
+ const getRequestOptions = moveTaskAfter(payload);
361
+ const getUrl = (context) => {
362
+ const { url } = getRequestOptions(context);
363
+ return url;
364
+ };
365
+ return {
366
+ getUrl,
367
+ httpMethod: "POST",
368
+ path: "/v2/tasks/{taskId}/move-after",
369
+ pathParams: { taskId: "taskId" },
370
+ __requestType: null,
371
+ __originalRequestType: null,
372
+ __responseType: null,
373
+ __originalResponseType: null
374
+ };
375
+ }
376
+ // Annotate the CommonJS export names for ESM import in node:
377
+ 0 && (module.exports = {
378
+ countTasks,
379
+ createTask,
380
+ deleteTask,
381
+ getTask,
382
+ moveTaskAfter,
383
+ queryTasks,
384
+ updateTask
385
+ });
386
+ //# sourceMappingURL=meta.js.map