shred-api-client 2.4.11 → 2.4.12
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/dist/index.d.ts +33 -15
- package/dist/index.js +12 -0
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -798,9 +798,10 @@ type QueryOrderBy<T> = {
|
|
|
798
798
|
field: keyof T | "modified";
|
|
799
799
|
direction: "asc" | "desc";
|
|
800
800
|
};
|
|
801
|
+
type QueryFilterOp = "==" | "!=" | ">" | "<" | ">=" | "<=" | "in" | "not-in" | "array-contains" | "array-contains-any" | "between";
|
|
801
802
|
type QueryWhere<T> = {
|
|
802
803
|
field: keyof T | "modified";
|
|
803
|
-
operation:
|
|
804
|
+
operation: QueryFilterOp;
|
|
804
805
|
value: T[keyof T] | T[keyof T][] | {
|
|
805
806
|
from: number;
|
|
806
807
|
to: number;
|
|
@@ -821,11 +822,12 @@ type APIResponse<T> = {
|
|
|
821
822
|
};
|
|
822
823
|
|
|
823
824
|
type index$a_APIResponse<T> = APIResponse<T>;
|
|
825
|
+
type index$a_QueryFilterOp = QueryFilterOp;
|
|
824
826
|
type index$a_QueryOptions<T> = QueryOptions<T>;
|
|
825
827
|
type index$a_QueryOrderBy<T> = QueryOrderBy<T>;
|
|
826
828
|
type index$a_QueryWhere<T> = QueryWhere<T>;
|
|
827
829
|
declare namespace index$a {
|
|
828
|
-
export type { index$a_APIResponse as APIResponse, index$a_QueryOptions as QueryOptions, index$a_QueryOrderBy as QueryOrderBy, index$a_QueryWhere as QueryWhere };
|
|
830
|
+
export type { index$a_APIResponse as APIResponse, index$a_QueryFilterOp as QueryFilterOp, index$a_QueryOptions as QueryOptions, index$a_QueryOrderBy as QueryOrderBy, index$a_QueryWhere as QueryWhere };
|
|
829
831
|
}
|
|
830
832
|
|
|
831
833
|
interface IAPI$8 {
|
|
@@ -2153,6 +2155,15 @@ declare enum Frequency {
|
|
|
2153
2155
|
WEEKLY = "weekly",
|
|
2154
2156
|
MONTHLY = "monthly"
|
|
2155
2157
|
}
|
|
2158
|
+
declare enum NotificationType {
|
|
2159
|
+
INFO = "info",
|
|
2160
|
+
TIP = "tip",
|
|
2161
|
+
VIDEO_SENT = "video_sent",
|
|
2162
|
+
VIDEO_EDITING_START = "video_start_editing",
|
|
2163
|
+
VIDEO_READY = "video_ready",
|
|
2164
|
+
REVISION_SENT = "revision_sent",
|
|
2165
|
+
REVISION_COMPLETED = "revision_completed"
|
|
2166
|
+
}
|
|
2156
2167
|
declare enum WeekDay {
|
|
2157
2168
|
MONDAY = 1,
|
|
2158
2169
|
TUESDAY = 2,
|
|
@@ -2188,6 +2199,7 @@ declare const NotificationItemSchema: z.ZodObject<{
|
|
|
2188
2199
|
triggerId: z.ZodOptional<z.ZodString>;
|
|
2189
2200
|
title: z.ZodString;
|
|
2190
2201
|
body: z.ZodString;
|
|
2202
|
+
type: z.ZodOptional<z.ZodNativeEnum<typeof NotificationType>>;
|
|
2191
2203
|
status: z.ZodEnum<["failed", "delivered", "deleted"]>;
|
|
2192
2204
|
deliveredAt: z.ZodNumber;
|
|
2193
2205
|
openedAt: z.ZodOptional<z.ZodNumber>;
|
|
@@ -2213,6 +2225,7 @@ declare const NotificationItemSchema: z.ZodObject<{
|
|
|
2213
2225
|
deliveredAt: number;
|
|
2214
2226
|
metadata: Record<string, string | number>;
|
|
2215
2227
|
triggerId?: string | undefined;
|
|
2228
|
+
type?: NotificationType | undefined;
|
|
2216
2229
|
openedAt?: number | undefined;
|
|
2217
2230
|
deletedAt?: number | undefined;
|
|
2218
2231
|
cta?: {
|
|
@@ -2229,6 +2242,7 @@ declare const NotificationItemSchema: z.ZodObject<{
|
|
|
2229
2242
|
deliveredAt: number;
|
|
2230
2243
|
metadata: Record<string, string | number>;
|
|
2231
2244
|
triggerId?: string | undefined;
|
|
2245
|
+
type?: NotificationType | undefined;
|
|
2232
2246
|
openedAt?: number | undefined;
|
|
2233
2247
|
deletedAt?: number | undefined;
|
|
2234
2248
|
cta?: {
|
|
@@ -2243,6 +2257,7 @@ declare const NotificationDetailSchema: z.ZodObject<Pick<{
|
|
|
2243
2257
|
triggerId: z.ZodOptional<z.ZodString>;
|
|
2244
2258
|
title: z.ZodString;
|
|
2245
2259
|
body: z.ZodString;
|
|
2260
|
+
type: z.ZodOptional<z.ZodNativeEnum<typeof NotificationType>>;
|
|
2246
2261
|
status: z.ZodEnum<["failed", "delivered", "deleted"]>;
|
|
2247
2262
|
deliveredAt: z.ZodNumber;
|
|
2248
2263
|
openedAt: z.ZodOptional<z.ZodNumber>;
|
|
@@ -2282,11 +2297,11 @@ declare const CriteriaSchema: z.ZodObject<{
|
|
|
2282
2297
|
type: z.ZodNativeEnum<typeof CriteriaType>;
|
|
2283
2298
|
params: z.ZodRecord<z.ZodString, z.ZodAny>;
|
|
2284
2299
|
}, "strip", z.ZodTypeAny, {
|
|
2285
|
-
params: Record<string, any>;
|
|
2286
2300
|
type: CriteriaType;
|
|
2287
|
-
}, {
|
|
2288
2301
|
params: Record<string, any>;
|
|
2302
|
+
}, {
|
|
2289
2303
|
type: CriteriaType;
|
|
2304
|
+
params: Record<string, any>;
|
|
2290
2305
|
}>;
|
|
2291
2306
|
declare const HistorySchema: z.ZodObject<{
|
|
2292
2307
|
batchId: z.ZodString;
|
|
@@ -2318,7 +2333,7 @@ declare const HistorySchema: z.ZodObject<{
|
|
|
2318
2333
|
}>, "many">>;
|
|
2319
2334
|
executionTimeDuration: z.ZodOptional<z.ZodNumber>;
|
|
2320
2335
|
}, "strip", z.ZodTypeAny, {
|
|
2321
|
-
status: "
|
|
2336
|
+
status: "info" | "failed" | "success" | "warn";
|
|
2322
2337
|
batchId: string;
|
|
2323
2338
|
executedAt: number;
|
|
2324
2339
|
timezone: string;
|
|
@@ -2333,7 +2348,7 @@ declare const HistorySchema: z.ZodObject<{
|
|
|
2333
2348
|
}[] | undefined;
|
|
2334
2349
|
executionTimeDuration?: number | undefined;
|
|
2335
2350
|
}, {
|
|
2336
|
-
status: "
|
|
2351
|
+
status: "info" | "failed" | "success" | "warn";
|
|
2337
2352
|
batchId: string;
|
|
2338
2353
|
executedAt: number;
|
|
2339
2354
|
timezone: string;
|
|
@@ -2381,6 +2396,7 @@ declare const TriggerSchema: z.ZodObject<{
|
|
|
2381
2396
|
triggerId: z.ZodOptional<z.ZodString>;
|
|
2382
2397
|
title: z.ZodString;
|
|
2383
2398
|
body: z.ZodString;
|
|
2399
|
+
type: z.ZodOptional<z.ZodNativeEnum<typeof NotificationType>>;
|
|
2384
2400
|
status: z.ZodEnum<["failed", "delivered", "deleted"]>;
|
|
2385
2401
|
deliveredAt: z.ZodNumber;
|
|
2386
2402
|
openedAt: z.ZodOptional<z.ZodNumber>;
|
|
@@ -2446,7 +2462,7 @@ declare const TriggerSchema: z.ZodObject<{
|
|
|
2446
2462
|
}>, "many">>;
|
|
2447
2463
|
executionTimeDuration: z.ZodOptional<z.ZodNumber>;
|
|
2448
2464
|
}, "strip", z.ZodTypeAny, {
|
|
2449
|
-
status: "
|
|
2465
|
+
status: "info" | "failed" | "success" | "warn";
|
|
2450
2466
|
batchId: string;
|
|
2451
2467
|
executedAt: number;
|
|
2452
2468
|
timezone: string;
|
|
@@ -2461,7 +2477,7 @@ declare const TriggerSchema: z.ZodObject<{
|
|
|
2461
2477
|
}[] | undefined;
|
|
2462
2478
|
executionTimeDuration?: number | undefined;
|
|
2463
2479
|
}, {
|
|
2464
|
-
status: "
|
|
2480
|
+
status: "info" | "failed" | "success" | "warn";
|
|
2465
2481
|
batchId: string;
|
|
2466
2482
|
executedAt: number;
|
|
2467
2483
|
timezone: string;
|
|
@@ -2507,11 +2523,11 @@ declare const TriggerSchema: z.ZodObject<{
|
|
|
2507
2523
|
type: z.ZodNativeEnum<typeof CriteriaType>;
|
|
2508
2524
|
params: z.ZodRecord<z.ZodString, z.ZodAny>;
|
|
2509
2525
|
}, "strip", z.ZodTypeAny, {
|
|
2510
|
-
params: Record<string, any>;
|
|
2511
2526
|
type: CriteriaType;
|
|
2512
|
-
}, {
|
|
2513
2527
|
params: Record<string, any>;
|
|
2528
|
+
}, {
|
|
2514
2529
|
type: CriteriaType;
|
|
2530
|
+
params: Record<string, any>;
|
|
2515
2531
|
}>;
|
|
2516
2532
|
nextExecution: z.ZodOptional<z.ZodNumber>;
|
|
2517
2533
|
createdAt: z.ZodOptional<z.ZodNumber>;
|
|
@@ -2534,12 +2550,12 @@ declare const TriggerSchema: z.ZodObject<{
|
|
|
2534
2550
|
};
|
|
2535
2551
|
timeOfDay: string;
|
|
2536
2552
|
criteria: {
|
|
2537
|
-
params: Record<string, any>;
|
|
2538
2553
|
type: CriteriaType;
|
|
2554
|
+
params: Record<string, any>;
|
|
2539
2555
|
};
|
|
2540
2556
|
timezone?: string | null | undefined;
|
|
2541
2557
|
history?: {
|
|
2542
|
-
status: "
|
|
2558
|
+
status: "info" | "failed" | "success" | "warn";
|
|
2543
2559
|
batchId: string;
|
|
2544
2560
|
executedAt: number;
|
|
2545
2561
|
timezone: string;
|
|
@@ -2585,12 +2601,12 @@ declare const TriggerSchema: z.ZodObject<{
|
|
|
2585
2601
|
};
|
|
2586
2602
|
timeOfDay: string;
|
|
2587
2603
|
criteria: {
|
|
2588
|
-
params: Record<string, any>;
|
|
2589
2604
|
type: CriteriaType;
|
|
2605
|
+
params: Record<string, any>;
|
|
2590
2606
|
};
|
|
2591
2607
|
timezone?: string | null | undefined;
|
|
2592
2608
|
history?: {
|
|
2593
|
-
status: "
|
|
2609
|
+
status: "info" | "failed" | "success" | "warn";
|
|
2594
2610
|
batchId: string;
|
|
2595
2611
|
executedAt: number;
|
|
2596
2612
|
timezone: string;
|
|
@@ -2683,6 +2699,8 @@ type index$3_NotificationDetail = NotificationDetail;
|
|
|
2683
2699
|
declare const index$3_NotificationDetailSchema: typeof NotificationDetailSchema;
|
|
2684
2700
|
type index$3_NotificationItem = NotificationItem;
|
|
2685
2701
|
declare const index$3_NotificationItemSchema: typeof NotificationItemSchema;
|
|
2702
|
+
type index$3_NotificationType = NotificationType;
|
|
2703
|
+
declare const index$3_NotificationType: typeof NotificationType;
|
|
2686
2704
|
type index$3_RecurrenceRule = RecurrenceRule;
|
|
2687
2705
|
declare const index$3_RecurrenceRuleSchema: typeof RecurrenceRuleSchema;
|
|
2688
2706
|
type index$3_Status = Status;
|
|
@@ -2694,7 +2712,7 @@ declare const index$3_TriggerSchema: typeof TriggerSchema;
|
|
|
2694
2712
|
type index$3_WeekDay = WeekDay;
|
|
2695
2713
|
declare const index$3_WeekDay: typeof WeekDay;
|
|
2696
2714
|
declare namespace index$3 {
|
|
2697
|
-
export { type index$3_Criteria as Criteria, index$3_CriteriaSchema as CriteriaSchema, index$3_CriteriaType as CriteriaType, Endpoints$1 as Endpoints, index$3_Frequency as Frequency, type index$3_History as History, index$3_HistorySchema as HistorySchema, type IAPI$2 as IAPI, type index$3_NotificationDetail as NotificationDetail, index$3_NotificationDetailSchema as NotificationDetailSchema, type index$3_NotificationItem as NotificationItem, index$3_NotificationItemSchema as NotificationItemSchema, type index$3_RecurrenceRule as RecurrenceRule, index$3_RecurrenceRuleSchema as RecurrenceRuleSchema, index$3_Status as Status, index$3_TransportType as TransportType, type index$3_Trigger as Trigger, index$3_TriggerSchema as TriggerSchema, index$3_WeekDay as WeekDay };
|
|
2715
|
+
export { type index$3_Criteria as Criteria, index$3_CriteriaSchema as CriteriaSchema, index$3_CriteriaType as CriteriaType, Endpoints$1 as Endpoints, index$3_Frequency as Frequency, type index$3_History as History, index$3_HistorySchema as HistorySchema, type IAPI$2 as IAPI, type index$3_NotificationDetail as NotificationDetail, index$3_NotificationDetailSchema as NotificationDetailSchema, type index$3_NotificationItem as NotificationItem, index$3_NotificationItemSchema as NotificationItemSchema, index$3_NotificationType as NotificationType, type index$3_RecurrenceRule as RecurrenceRule, index$3_RecurrenceRuleSchema as RecurrenceRuleSchema, index$3_Status as Status, index$3_TransportType as TransportType, type index$3_Trigger as Trigger, index$3_TriggerSchema as TriggerSchema, index$3_WeekDay as WeekDay };
|
|
2698
2716
|
}
|
|
2699
2717
|
|
|
2700
2718
|
interface IAPI$1 {
|
package/dist/index.js
CHANGED
|
@@ -121,6 +121,7 @@ __export(notification_exports, {
|
|
|
121
121
|
HistorySchema: () => HistorySchema,
|
|
122
122
|
NotificationDetailSchema: () => NotificationDetailSchema,
|
|
123
123
|
NotificationItemSchema: () => NotificationItemSchema,
|
|
124
|
+
NotificationType: () => NotificationType,
|
|
124
125
|
RecurrenceRuleSchema: () => RecurrenceRuleSchema,
|
|
125
126
|
Status: () => Status,
|
|
126
127
|
TransportType: () => TransportType,
|
|
@@ -4185,6 +4186,16 @@ var Frequency = /* @__PURE__ */ ((Frequency2) => {
|
|
|
4185
4186
|
Frequency2["MONTHLY"] = "monthly";
|
|
4186
4187
|
return Frequency2;
|
|
4187
4188
|
})(Frequency || {});
|
|
4189
|
+
var NotificationType = /* @__PURE__ */ ((NotificationType2) => {
|
|
4190
|
+
NotificationType2["INFO"] = "info";
|
|
4191
|
+
NotificationType2["TIP"] = "tip";
|
|
4192
|
+
NotificationType2["VIDEO_SENT"] = "video_sent";
|
|
4193
|
+
NotificationType2["VIDEO_EDITING_START"] = "video_start_editing";
|
|
4194
|
+
NotificationType2["VIDEO_READY"] = "video_ready";
|
|
4195
|
+
NotificationType2["REVISION_SENT"] = "revision_sent";
|
|
4196
|
+
NotificationType2["REVISION_COMPLETED"] = "revision_completed";
|
|
4197
|
+
return NotificationType2;
|
|
4198
|
+
})(NotificationType || {});
|
|
4188
4199
|
var WeekDay = /* @__PURE__ */ ((WeekDay2) => {
|
|
4189
4200
|
WeekDay2[WeekDay2["MONDAY"] = 1] = "MONDAY";
|
|
4190
4201
|
WeekDay2[WeekDay2["TUESDAY"] = 2] = "TUESDAY";
|
|
@@ -4224,6 +4235,7 @@ var NotificationItemSchema = external_exports.object({
|
|
|
4224
4235
|
triggerId: external_exports.string().optional(),
|
|
4225
4236
|
title: external_exports.string(),
|
|
4226
4237
|
body: external_exports.string(),
|
|
4238
|
+
type: external_exports.nativeEnum(NotificationType).optional(),
|
|
4227
4239
|
status: external_exports.enum(["failed", "delivered", "deleted"]),
|
|
4228
4240
|
deliveredAt: external_exports.number(),
|
|
4229
4241
|
openedAt: external_exports.number().optional(),
|