@wix/auto_sdk_members_member-report 1.0.43 → 1.0.45
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 +12 -4
- package/build/cjs/index.js +319 -17
- package/build/cjs/index.js.map +1 -1
- package/build/cjs/index.typings.js +307 -5
- package/build/cjs/index.typings.js.map +1 -1
- package/build/es/index.d.mts +12 -4
- package/build/es/index.mjs +309 -17
- package/build/es/index.mjs.map +1 -1
- package/build/es/index.typings.mjs +297 -5
- package/build/es/index.typings.mjs.map +1 -1
- package/build/internal/cjs/index.d.ts +12 -4
- package/build/internal/cjs/index.js +319 -17
- package/build/internal/cjs/index.js.map +1 -1
- package/build/internal/cjs/index.typings.js +307 -5
- package/build/internal/cjs/index.typings.js.map +1 -1
- package/build/internal/es/index.d.mts +12 -4
- package/build/internal/es/index.mjs +309 -17
- package/build/internal/es/index.mjs.map +1 -1
- package/build/internal/es/index.typings.mjs +297 -5
- package/build/internal/es/index.typings.mjs.map +1 -1
- package/package.json +4 -4
package/build/cjs/index.d.ts
CHANGED
|
@@ -2,7 +2,9 @@ import { HttpClient, NonNullablePaths, EventDefinition, MaybeContext, BuildRESTF
|
|
|
2
2
|
import { MemberReport, ReportMemberResponse, ReportMemberApplicationErrors, ListReportedMembersOptions, ListReportedMembersResponse, QueryReportedMembersOptions, QueryReportedMembersResponse, DeleteMemberReportsApplicationErrors, MemberReportCreatedEnvelope, MemberReportDeletedEnvelope, MemberReportReportedMemberCreatedEnvelope, MemberReportReportedMemberDeletedEnvelope, MemberReportsQueryBuilder, MemberReportQuery, typedQueryMemberReports } from './index.typings.js';
|
|
3
3
|
export { AccountInfo, AccountInfoMetadata, ActionEvent, BaseEventMetadata, CannotReportBlockedMemberError, Category, CategoryWithLiterals, CommonQueryWithEntityContext, CursorPaging, Cursors, DeleteMemberReportsRequest, DeleteMemberReportsResponse, DomainEvent, DomainEventBodyOneOf, Empty, EntityCreatedEvent, EntityDeletedEvent, EntityUpdatedEvent, EventMetadata, IdentificationData, IdentificationDataIdOneOf, ListReportedMembersOptionsPagingMethodOneOf, ListReportedMembersRequest, ListReportedMembersRequestPagingMethodOneOf, MarkMemberReportsAsReviewedRequest, MarkMemberReportsAsReviewedResponse, MemberReportQuerySpec, MemberReportsQueryResult, MessageEnvelope, Paging, PagingMetadataV2, QueryMemberReportsRequest, QueryMemberReportsResponse, QueryReportedMembersRequest, QueryV2, Reason, ReportMemberRequest, ReportedMember, ReportedMemberCreated, ReportedMemberDeleted, RestoreInfo, SelfReportingForbiddenError, SortOrder, SortOrderWithLiterals, Sorting, WebhookIdentityType, WebhookIdentityTypeWithLiterals, utils } from './index.typings.js';
|
|
4
4
|
|
|
5
|
-
declare function reportMember$1(httpClient: HttpClient
|
|
5
|
+
declare function reportMember$1(httpClient: HttpClient, __options?: {
|
|
6
|
+
validateRequestSchema?: boolean;
|
|
7
|
+
}): ReportMemberSignature;
|
|
6
8
|
interface ReportMemberSignature {
|
|
7
9
|
/**
|
|
8
10
|
* Creates a report for the reported member.
|
|
@@ -12,7 +14,9 @@ interface ReportMemberSignature {
|
|
|
12
14
|
__applicationErrorsType?: ReportMemberApplicationErrors;
|
|
13
15
|
}>;
|
|
14
16
|
}
|
|
15
|
-
declare function listReportedMembers$1(httpClient: HttpClient
|
|
17
|
+
declare function listReportedMembers$1(httpClient: HttpClient, __options?: {
|
|
18
|
+
validateRequestSchema?: boolean;
|
|
19
|
+
}): ListReportedMembersSignature;
|
|
16
20
|
interface ListReportedMembersSignature {
|
|
17
21
|
/**
|
|
18
22
|
* Retrieves a list of reported members.
|
|
@@ -20,7 +24,9 @@ interface ListReportedMembersSignature {
|
|
|
20
24
|
*/
|
|
21
25
|
(options?: ListReportedMembersOptions): Promise<NonNullablePaths<ListReportedMembersResponse, `reportedMembers` | `reportedMembers.${number}.reportedMemberId` | `reportedMembers.${number}.reportCount` | `reportedMembers.${number}.reviewed`, 4>>;
|
|
22
26
|
}
|
|
23
|
-
declare function queryReportedMembers$1(httpClient: HttpClient
|
|
27
|
+
declare function queryReportedMembers$1(httpClient: HttpClient, __options?: {
|
|
28
|
+
validateRequestSchema?: boolean;
|
|
29
|
+
}): QueryReportedMembersSignature;
|
|
24
30
|
interface QueryReportedMembersSignature {
|
|
25
31
|
/**
|
|
26
32
|
* Retrieves a list of reported members, given the provided paging, filtering, and sorting.
|
|
@@ -35,7 +41,9 @@ interface QueryReportedMembersSignature {
|
|
|
35
41
|
*/
|
|
36
42
|
(options?: QueryReportedMembersOptions): Promise<NonNullablePaths<QueryReportedMembersResponse, `reportedMembers` | `reportedMembers.${number}.reportedMemberId` | `reportedMembers.${number}.reportCount` | `reportedMembers.${number}.reviewed`, 4>>;
|
|
37
43
|
}
|
|
38
|
-
declare function deleteMemberReports$1(httpClient: HttpClient
|
|
44
|
+
declare function deleteMemberReports$1(httpClient: HttpClient, __options?: {
|
|
45
|
+
validateRequestSchema?: boolean;
|
|
46
|
+
}): DeleteMemberReportsSignature;
|
|
39
47
|
interface DeleteMemberReportsSignature {
|
|
40
48
|
/**
|
|
41
49
|
* Deletes all reports of a member.
|
package/build/cjs/index.js
CHANGED
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
var __create = Object.create;
|
|
2
3
|
var __defProp = Object.defineProperty;
|
|
3
4
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
5
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
5
7
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
8
|
var __export = (target, all) => {
|
|
7
9
|
for (var name in all)
|
|
@@ -15,6 +17,14 @@ var __copyProps = (to, from, except, desc) => {
|
|
|
15
17
|
}
|
|
16
18
|
return to;
|
|
17
19
|
};
|
|
20
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
|
22
|
+
// file that has been converted to a CommonJS file using a Babel-
|
|
23
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
24
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
25
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
26
|
+
mod
|
|
27
|
+
));
|
|
18
28
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
29
|
|
|
20
30
|
// index.ts
|
|
@@ -233,6 +243,283 @@ function deleteMemberReports(payload) {
|
|
|
233
243
|
|
|
234
244
|
// src/members-v1-member-report-member-report.universal.ts
|
|
235
245
|
var import_transform_paths2 = require("@wix/sdk-runtime/transformations/transform-paths");
|
|
246
|
+
|
|
247
|
+
// src/members-v1-member-report-member-report.schemas.ts
|
|
248
|
+
var z = __toESM(require("zod"));
|
|
249
|
+
var ReportMemberRequest = z.object({
|
|
250
|
+
memberReport: z.object({
|
|
251
|
+
_id: z.string().describe("Report ID.").regex(
|
|
252
|
+
/^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
|
|
253
|
+
"Must be a valid GUID"
|
|
254
|
+
).optional().nullable(),
|
|
255
|
+
reportedMemberId: z.string().describe("ID of the reported member.").regex(
|
|
256
|
+
/^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
|
|
257
|
+
"Must be a valid GUID"
|
|
258
|
+
),
|
|
259
|
+
reportingMemberId: z.string().describe("ID of the member who created the report.").optional().nullable(),
|
|
260
|
+
reason: z.object({
|
|
261
|
+
category: z.enum(["UNKNOWN", "SPAM", "IMPERSONATION", "HARASSMENT", "OTHER"]).optional(),
|
|
262
|
+
description: z.string().describe("Explanation of why the member is being reported.").optional().nullable()
|
|
263
|
+
}).describe("Reason for reporting a member."),
|
|
264
|
+
_createdDate: z.date().describe("Date and time the report was created.").optional().nullable()
|
|
265
|
+
}).describe("Details of a member to report.")
|
|
266
|
+
});
|
|
267
|
+
var ReportMemberResponse = z.object({
|
|
268
|
+
memberReport: z.object({
|
|
269
|
+
_id: z.string().describe("Report ID.").regex(
|
|
270
|
+
/^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
|
|
271
|
+
"Must be a valid GUID"
|
|
272
|
+
).optional().nullable(),
|
|
273
|
+
reportedMemberId: z.string().describe("ID of the reported member.").regex(
|
|
274
|
+
/^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
|
|
275
|
+
"Must be a valid GUID"
|
|
276
|
+
).optional(),
|
|
277
|
+
reportingMemberId: z.string().describe("ID of the member who created the report.").optional().nullable(),
|
|
278
|
+
reason: z.object({
|
|
279
|
+
category: z.enum(["UNKNOWN", "SPAM", "IMPERSONATION", "HARASSMENT", "OTHER"]).describe("Report reason type.").optional(),
|
|
280
|
+
description: z.string().describe("Explanation of why the member is being reported.").optional().nullable()
|
|
281
|
+
}).describe("Reason for reporting a member.").optional(),
|
|
282
|
+
_createdDate: z.date().describe("Date and time the report was created.").optional().nullable()
|
|
283
|
+
}).describe("Member report.").optional()
|
|
284
|
+
});
|
|
285
|
+
var QueryMemberReportsRequest = z.object({
|
|
286
|
+
query: z.object({
|
|
287
|
+
filter: z.object({
|
|
288
|
+
_id: z.object({
|
|
289
|
+
$eq: z.string(),
|
|
290
|
+
$exists: z.boolean(),
|
|
291
|
+
$gt: z.string(),
|
|
292
|
+
$gte: z.string(),
|
|
293
|
+
$hasAll: z.array(z.string()),
|
|
294
|
+
$hasSome: z.array(z.string()),
|
|
295
|
+
$in: z.array(z.string()),
|
|
296
|
+
$lt: z.string(),
|
|
297
|
+
$lte: z.string(),
|
|
298
|
+
$ne: z.string(),
|
|
299
|
+
$nin: z.array(z.string()),
|
|
300
|
+
$startsWith: z.string()
|
|
301
|
+
}).partial().strict().optional(),
|
|
302
|
+
reportedMemberId: z.object({
|
|
303
|
+
$eq: z.string(),
|
|
304
|
+
$exists: z.boolean(),
|
|
305
|
+
$gt: z.string(),
|
|
306
|
+
$gte: z.string(),
|
|
307
|
+
$hasAll: z.array(z.string()),
|
|
308
|
+
$hasSome: z.array(z.string()),
|
|
309
|
+
$in: z.array(z.string()),
|
|
310
|
+
$lt: z.string(),
|
|
311
|
+
$lte: z.string(),
|
|
312
|
+
$ne: z.string(),
|
|
313
|
+
$nin: z.array(z.string()),
|
|
314
|
+
$startsWith: z.string()
|
|
315
|
+
}).partial().strict().optional(),
|
|
316
|
+
reportingMemberId: z.object({
|
|
317
|
+
$eq: z.string(),
|
|
318
|
+
$exists: z.boolean(),
|
|
319
|
+
$gt: z.string(),
|
|
320
|
+
$gte: z.string(),
|
|
321
|
+
$hasAll: z.array(z.string()),
|
|
322
|
+
$hasSome: z.array(z.string()),
|
|
323
|
+
$in: z.array(z.string()),
|
|
324
|
+
$lt: z.string(),
|
|
325
|
+
$lte: z.string(),
|
|
326
|
+
$ne: z.string(),
|
|
327
|
+
$nin: z.array(z.string()),
|
|
328
|
+
$startsWith: z.string()
|
|
329
|
+
}).partial().strict().optional(),
|
|
330
|
+
reason: z.object({
|
|
331
|
+
$eq: z.any(),
|
|
332
|
+
$exists: z.boolean(),
|
|
333
|
+
$gt: z.any(),
|
|
334
|
+
$gte: z.any(),
|
|
335
|
+
$hasAll: z.array(z.any()),
|
|
336
|
+
$hasSome: z.array(z.any()),
|
|
337
|
+
$in: z.array(z.any()),
|
|
338
|
+
$lt: z.any(),
|
|
339
|
+
$lte: z.any(),
|
|
340
|
+
$ne: z.any(),
|
|
341
|
+
$nin: z.array(z.any()),
|
|
342
|
+
$startsWith: z.string()
|
|
343
|
+
}).partial().strict().optional(),
|
|
344
|
+
_createdDate: z.object({
|
|
345
|
+
$eq: z.string(),
|
|
346
|
+
$exists: z.boolean(),
|
|
347
|
+
$gt: z.string(),
|
|
348
|
+
$gte: z.string(),
|
|
349
|
+
$hasAll: z.array(z.string()),
|
|
350
|
+
$hasSome: z.array(z.string()),
|
|
351
|
+
$in: z.array(z.string()),
|
|
352
|
+
$lt: z.string(),
|
|
353
|
+
$lte: z.string(),
|
|
354
|
+
$ne: z.string(),
|
|
355
|
+
$nin: z.array(z.string()),
|
|
356
|
+
$startsWith: z.string()
|
|
357
|
+
}).partial().strict().optional(),
|
|
358
|
+
$and: z.array(z.any()).optional(),
|
|
359
|
+
$or: z.array(z.any()).optional(),
|
|
360
|
+
$not: z.any().optional()
|
|
361
|
+
}).strict().optional(),
|
|
362
|
+
sort: z.array(z.object({})).optional()
|
|
363
|
+
}).catchall(z.any()).describe(
|
|
364
|
+
"Query options. See [API Query Language](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language) for more details."
|
|
365
|
+
)
|
|
366
|
+
});
|
|
367
|
+
var QueryMemberReportsResponse = z.object({
|
|
368
|
+
memberReports: z.array(
|
|
369
|
+
z.object({
|
|
370
|
+
_id: z.string().describe("Report ID.").regex(
|
|
371
|
+
/^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
|
|
372
|
+
"Must be a valid GUID"
|
|
373
|
+
).optional().nullable(),
|
|
374
|
+
reportedMemberId: z.string().describe("ID of the reported member.").regex(
|
|
375
|
+
/^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
|
|
376
|
+
"Must be a valid GUID"
|
|
377
|
+
).optional(),
|
|
378
|
+
reportingMemberId: z.string().describe("ID of the member who created the report.").optional().nullable(),
|
|
379
|
+
reason: z.object({
|
|
380
|
+
category: z.enum(["UNKNOWN", "SPAM", "IMPERSONATION", "HARASSMENT", "OTHER"]).describe("Report reason type.").optional(),
|
|
381
|
+
description: z.string().describe("Explanation of why the member is being reported.").optional().nullable()
|
|
382
|
+
}).describe("Reason for reporting a member.").optional(),
|
|
383
|
+
_createdDate: z.date().describe("Date and time the report was created.").optional().nullable()
|
|
384
|
+
})
|
|
385
|
+
).optional(),
|
|
386
|
+
pagingMetadata: z.object({
|
|
387
|
+
count: z.number().int().describe("Number of items returned in the response.").optional().nullable(),
|
|
388
|
+
offset: z.number().int().describe("Offset that was requested.").optional().nullable(),
|
|
389
|
+
total: z.number().int().describe(
|
|
390
|
+
"Total number of items that match the query. Returned if offset paging is used and the `tooManyToCount` flag is not set."
|
|
391
|
+
).optional().nullable(),
|
|
392
|
+
tooManyToCount: z.boolean().describe(
|
|
393
|
+
"Flag that indicates the server failed to calculate the `total` field."
|
|
394
|
+
).optional().nullable(),
|
|
395
|
+
cursors: z.object({
|
|
396
|
+
next: z.string().describe(
|
|
397
|
+
"Cursor string pointing to the next page in the list of results."
|
|
398
|
+
).max(16e3).optional().nullable(),
|
|
399
|
+
prev: z.string().describe(
|
|
400
|
+
"Cursor pointing to the previous page in the list of results."
|
|
401
|
+
).max(16e3).optional().nullable()
|
|
402
|
+
}).describe(
|
|
403
|
+
"Cursors to navigate through the result pages using `next` and `prev`. Returned if cursor paging is used."
|
|
404
|
+
).optional()
|
|
405
|
+
}).describe("Metadata for the paginated results.").optional()
|
|
406
|
+
});
|
|
407
|
+
var ListReportedMembersRequest = z.object({
|
|
408
|
+
options: z.intersection(
|
|
409
|
+
z.object({}),
|
|
410
|
+
z.xor([
|
|
411
|
+
z.object({ cursorPaging: z.never().optional() }),
|
|
412
|
+
z.object({
|
|
413
|
+
cursorPaging: z.object({
|
|
414
|
+
limit: z.number().int().describe("The number of items to load.\nDefault: `100`").min(0).max(1e3).optional().nullable(),
|
|
415
|
+
cursor: z.string().describe(
|
|
416
|
+
"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`."
|
|
417
|
+
).optional().nullable()
|
|
418
|
+
}).describe(
|
|
419
|
+
"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`."
|
|
420
|
+
)
|
|
421
|
+
})
|
|
422
|
+
])
|
|
423
|
+
).optional()
|
|
424
|
+
});
|
|
425
|
+
var ListReportedMembersResponse = z.object({
|
|
426
|
+
reportedMembers: z.array(
|
|
427
|
+
z.object({
|
|
428
|
+
reportedMemberId: z.string().describe("ID of the reported member.").regex(
|
|
429
|
+
/^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
|
|
430
|
+
"Must be a valid GUID"
|
|
431
|
+
).optional(),
|
|
432
|
+
reportCount: z.string().regex(/^-?\d+$/, "Must be a valid Int64 string").describe("Number of reports for this member.").optional(),
|
|
433
|
+
reviewed: z.boolean().describe("Whether reports of this member have been reviewed.").optional(),
|
|
434
|
+
lastReportDate: z.date().describe("Date and time when the most recent report was created.").optional().nullable()
|
|
435
|
+
})
|
|
436
|
+
).optional(),
|
|
437
|
+
pagingMetadata: z.object({
|
|
438
|
+
count: z.number().int().describe("Number of items returned in the response.").optional().nullable(),
|
|
439
|
+
offset: z.number().int().describe("Offset that was requested.").optional().nullable(),
|
|
440
|
+
total: z.number().int().describe(
|
|
441
|
+
"Total number of items that match the query. Returned if offset paging is used and the `tooManyToCount` flag is not set."
|
|
442
|
+
).optional().nullable(),
|
|
443
|
+
tooManyToCount: z.boolean().describe(
|
|
444
|
+
"Flag that indicates the server failed to calculate the `total` field."
|
|
445
|
+
).optional().nullable(),
|
|
446
|
+
cursors: z.object({
|
|
447
|
+
next: z.string().describe(
|
|
448
|
+
"Cursor string pointing to the next page in the list of results."
|
|
449
|
+
).max(16e3).optional().nullable(),
|
|
450
|
+
prev: z.string().describe(
|
|
451
|
+
"Cursor pointing to the previous page in the list of results."
|
|
452
|
+
).max(16e3).optional().nullable()
|
|
453
|
+
}).describe(
|
|
454
|
+
"Cursors to navigate through the result pages using `next` and `prev`. Returned if cursor paging is used."
|
|
455
|
+
).optional()
|
|
456
|
+
}).describe("Metadata for the paginated results.").optional()
|
|
457
|
+
});
|
|
458
|
+
var QueryReportedMembersRequest = z.object({
|
|
459
|
+
options: z.object({
|
|
460
|
+
query: z.object({
|
|
461
|
+
filter: z.record(z.string(), z.any()).describe(
|
|
462
|
+
'Filter object in the following format:\n`"filter" : {\n"fieldName1": "value1",\n"fieldName2":{"$operator":"value2"}\n}`\nExample of operators: `$eq`, `$ne`, `$lt`, `$lte`, `$gt`, `$gte`, `$in`, `$hasSome`, `$hasAll`, `$startsWith`, `$contains`\n\nSee [API Query Language](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language) for more details.'
|
|
463
|
+
).optional().nullable(),
|
|
464
|
+
sorting: z.array(
|
|
465
|
+
z.object({
|
|
466
|
+
fieldName: z.string().describe("Name of the field to sort by.").max(512).optional(),
|
|
467
|
+
order: z.enum(["ASC", "DESC"]).optional()
|
|
468
|
+
})
|
|
469
|
+
).optional(),
|
|
470
|
+
paging: z.object({
|
|
471
|
+
limit: z.number().int().describe("The number of items to load.\nDefault: `100`").min(0).max(1e3).optional().nullable(),
|
|
472
|
+
cursor: z.string().describe(
|
|
473
|
+
"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`."
|
|
474
|
+
).optional().nullable()
|
|
475
|
+
}).describe("Paging options to limit and skip the number of items.").optional()
|
|
476
|
+
}).describe(
|
|
477
|
+
"Query options. See [API Query Language](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language) for more details."
|
|
478
|
+
).optional()
|
|
479
|
+
}).optional()
|
|
480
|
+
});
|
|
481
|
+
var QueryReportedMembersResponse = z.object({
|
|
482
|
+
reportedMembers: z.array(
|
|
483
|
+
z.object({
|
|
484
|
+
reportedMemberId: z.string().describe("ID of the reported member.").regex(
|
|
485
|
+
/^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
|
|
486
|
+
"Must be a valid GUID"
|
|
487
|
+
).optional(),
|
|
488
|
+
reportCount: z.string().regex(/^-?\d+$/, "Must be a valid Int64 string").describe("Number of reports for this member.").optional(),
|
|
489
|
+
reviewed: z.boolean().describe("Whether reports of this member have been reviewed.").optional(),
|
|
490
|
+
lastReportDate: z.date().describe("Date and time when the most recent report was created.").optional().nullable()
|
|
491
|
+
})
|
|
492
|
+
).optional(),
|
|
493
|
+
pagingMetadata: z.object({
|
|
494
|
+
count: z.number().int().describe("Number of items returned in the response.").optional().nullable(),
|
|
495
|
+
offset: z.number().int().describe("Offset that was requested.").optional().nullable(),
|
|
496
|
+
total: z.number().int().describe(
|
|
497
|
+
"Total number of items that match the query. Returned if offset paging is used and the `tooManyToCount` flag is not set."
|
|
498
|
+
).optional().nullable(),
|
|
499
|
+
tooManyToCount: z.boolean().describe(
|
|
500
|
+
"Flag that indicates the server failed to calculate the `total` field."
|
|
501
|
+
).optional().nullable(),
|
|
502
|
+
cursors: z.object({
|
|
503
|
+
next: z.string().describe(
|
|
504
|
+
"Cursor string pointing to the next page in the list of results."
|
|
505
|
+
).max(16e3).optional().nullable(),
|
|
506
|
+
prev: z.string().describe(
|
|
507
|
+
"Cursor pointing to the previous page in the list of results."
|
|
508
|
+
).max(16e3).optional().nullable()
|
|
509
|
+
}).describe(
|
|
510
|
+
"Cursors to navigate through the result pages using `next` and `prev`. Returned if cursor paging is used."
|
|
511
|
+
).optional()
|
|
512
|
+
}).describe("Metadata for the paginated results.").optional()
|
|
513
|
+
});
|
|
514
|
+
var DeleteMemberReportsRequest = z.object({
|
|
515
|
+
memberId: z.string().describe("ID of the member whose reports are to be deleted.").regex(
|
|
516
|
+
/^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$/,
|
|
517
|
+
"Must be a valid GUID"
|
|
518
|
+
)
|
|
519
|
+
});
|
|
520
|
+
var DeleteMemberReportsResponse = z.object({});
|
|
521
|
+
|
|
522
|
+
// src/members-v1-member-report-member-report.universal.ts
|
|
236
523
|
var import_query_builder_utils = require("@wix/sdk-runtime/query-builder-utils");
|
|
237
524
|
var Category = /* @__PURE__ */ ((Category2) => {
|
|
238
525
|
Category2["UNKNOWN"] = "UNKNOWN";
|
|
@@ -256,7 +543,10 @@ var WebhookIdentityType = /* @__PURE__ */ ((WebhookIdentityType2) => {
|
|
|
256
543
|
return WebhookIdentityType2;
|
|
257
544
|
})(WebhookIdentityType || {});
|
|
258
545
|
async function reportMember2(memberReport) {
|
|
259
|
-
const { httpClient, sideEffects } = arguments[1];
|
|
546
|
+
const { httpClient, sideEffects, validateRequestSchema } = arguments[1];
|
|
547
|
+
if (validateRequestSchema) {
|
|
548
|
+
ReportMemberRequest.parse({ memberReport });
|
|
549
|
+
}
|
|
260
550
|
const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
|
|
261
551
|
memberReport
|
|
262
552
|
});
|
|
@@ -326,7 +616,10 @@ function queryMemberReports2() {
|
|
|
326
616
|
});
|
|
327
617
|
}
|
|
328
618
|
async function typedQueryMemberReports(query) {
|
|
329
|
-
const { httpClient, sideEffects } = arguments[1];
|
|
619
|
+
const { httpClient, sideEffects, validateRequestSchema } = arguments[1];
|
|
620
|
+
if (validateRequestSchema) {
|
|
621
|
+
QueryMemberReportsRequest.parse({ query });
|
|
622
|
+
}
|
|
330
623
|
const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({ query });
|
|
331
624
|
const reqOpts = queryMemberReports(payload);
|
|
332
625
|
sideEffects?.onSiteCall?.();
|
|
@@ -354,7 +647,10 @@ var utils = {
|
|
|
354
647
|
}
|
|
355
648
|
};
|
|
356
649
|
async function listReportedMembers2(options) {
|
|
357
|
-
const { httpClient, sideEffects } = arguments[1];
|
|
650
|
+
const { httpClient, sideEffects, validateRequestSchema } = arguments[1];
|
|
651
|
+
if (validateRequestSchema) {
|
|
652
|
+
ListReportedMembersRequest.parse({ options });
|
|
653
|
+
}
|
|
358
654
|
const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
|
|
359
655
|
cursorPaging: options?.cursorPaging
|
|
360
656
|
});
|
|
@@ -379,7 +675,10 @@ async function listReportedMembers2(options) {
|
|
|
379
675
|
}
|
|
380
676
|
}
|
|
381
677
|
async function queryReportedMembers2(options) {
|
|
382
|
-
const { httpClient, sideEffects } = arguments[1];
|
|
678
|
+
const { httpClient, sideEffects, validateRequestSchema } = arguments[1];
|
|
679
|
+
if (validateRequestSchema) {
|
|
680
|
+
QueryReportedMembersRequest.parse({ options });
|
|
681
|
+
}
|
|
383
682
|
const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
|
|
384
683
|
query: options?.query
|
|
385
684
|
});
|
|
@@ -404,7 +703,10 @@ async function queryReportedMembers2(options) {
|
|
|
404
703
|
}
|
|
405
704
|
}
|
|
406
705
|
async function deleteMemberReports2(memberId) {
|
|
407
|
-
const { httpClient, sideEffects } = arguments[1];
|
|
706
|
+
const { httpClient, sideEffects, validateRequestSchema } = arguments[1];
|
|
707
|
+
if (validateRequestSchema) {
|
|
708
|
+
DeleteMemberReportsRequest.parse({ memberId });
|
|
709
|
+
}
|
|
408
710
|
const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({ memberId });
|
|
409
711
|
const reqOpts = deleteMemberReports(payload);
|
|
410
712
|
sideEffects?.onSiteCall?.();
|
|
@@ -428,45 +730,45 @@ async function deleteMemberReports2(memberId) {
|
|
|
428
730
|
}
|
|
429
731
|
|
|
430
732
|
// src/members-v1-member-report-member-report.public.ts
|
|
431
|
-
function reportMember3(httpClient) {
|
|
733
|
+
function reportMember3(httpClient, __options) {
|
|
432
734
|
return (memberReport) => reportMember2(
|
|
433
735
|
memberReport,
|
|
434
736
|
// @ts-ignore
|
|
435
|
-
{ httpClient }
|
|
737
|
+
{ httpClient, validateRequestSchema: __options?.validateRequestSchema }
|
|
436
738
|
);
|
|
437
739
|
}
|
|
438
|
-
function queryMemberReports3(httpClient) {
|
|
740
|
+
function queryMemberReports3(httpClient, __options) {
|
|
439
741
|
return () => queryMemberReports2(
|
|
440
742
|
// @ts-ignore
|
|
441
|
-
{ httpClient }
|
|
743
|
+
{ httpClient, validateRequestSchema: __options?.validateRequestSchema }
|
|
442
744
|
);
|
|
443
745
|
}
|
|
444
|
-
function typedQueryMemberReports2(httpClient) {
|
|
746
|
+
function typedQueryMemberReports2(httpClient, __options) {
|
|
445
747
|
return (query) => typedQueryMemberReports(
|
|
446
748
|
query,
|
|
447
749
|
// @ts-ignore
|
|
448
|
-
{ httpClient }
|
|
750
|
+
{ httpClient, validateRequestSchema: __options?.validateRequestSchema }
|
|
449
751
|
);
|
|
450
752
|
}
|
|
451
|
-
function listReportedMembers3(httpClient) {
|
|
753
|
+
function listReportedMembers3(httpClient, __options) {
|
|
452
754
|
return (options) => listReportedMembers2(
|
|
453
755
|
options,
|
|
454
756
|
// @ts-ignore
|
|
455
|
-
{ httpClient }
|
|
757
|
+
{ httpClient, validateRequestSchema: __options?.validateRequestSchema }
|
|
456
758
|
);
|
|
457
759
|
}
|
|
458
|
-
function queryReportedMembers3(httpClient) {
|
|
760
|
+
function queryReportedMembers3(httpClient, __options) {
|
|
459
761
|
return (options) => queryReportedMembers2(
|
|
460
762
|
options,
|
|
461
763
|
// @ts-ignore
|
|
462
|
-
{ httpClient }
|
|
764
|
+
{ httpClient, validateRequestSchema: __options?.validateRequestSchema }
|
|
463
765
|
);
|
|
464
766
|
}
|
|
465
|
-
function deleteMemberReports3(httpClient) {
|
|
767
|
+
function deleteMemberReports3(httpClient, __options) {
|
|
466
768
|
return (memberId) => deleteMemberReports2(
|
|
467
769
|
memberId,
|
|
468
770
|
// @ts-ignore
|
|
469
|
-
{ httpClient }
|
|
771
|
+
{ httpClient, validateRequestSchema: __options?.validateRequestSchema }
|
|
470
772
|
);
|
|
471
773
|
}
|
|
472
774
|
var onMemberReportCreated = (0, import_sdk_types.EventDefinition)(
|