@notidotbot/noti-api-client 1.9.100 → 1.9.102
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/classes/@me.d.ts +83 -0
- package/dist/classes/@me.js +44 -1
- package/dist/classes/admin.d.ts +1 -1
- package/dist/classes/client.d.ts +1 -1
- package/dist/classes/guildPlatform.d.ts +9 -2
- package/dist/classes/guildPlatformAction.d.ts +2 -2
- package/dist/classes/guildRolePanel.d.ts +12 -12
- package/dist/classes/guildStarboard.d.ts +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/other/bitfields.d.ts +5 -2
- package/dist/other/bitfields.js +2 -0
- package/dist/other/enums.d.ts +6 -0
- package/dist/other/enums.js +3 -0
- package/dist/other/features.d.ts +1 -1
- package/dist/other/features.js +3 -0
- package/dist/other/inGameAlerts.d.ts +1 -0
- package/dist/other/inGameAlerts.js +1 -0
- package/dist/other/multiDestination.d.ts +1 -0
- package/dist/other/multiDestination.js +1 -0
- package/dist/other/prisma.d.ts +4 -0
- package/dist/other/templates.d.ts +49 -0
- package/dist/other/templates.js +42 -3
- package/dist/other/types.d.ts +3 -0
- package/dist/other/zod/client.zod.d.ts +2 -0
- package/dist/other/zod/clipForward.zod.d.ts +3 -0
- package/dist/other/zod/clubStreamer.zod.d.ts +2 -0
- package/dist/other/zod/drops.zod.d.ts +1 -0
- package/dist/other/zod/gameConfig.zod.d.ts +1 -1
- package/dist/other/zod/guild.zod.d.ts +12 -0
- package/dist/other/zod/guild.zod.js +2 -0
- package/dist/other/zod/kickStreamer.zod.d.ts +2 -0
- package/dist/other/zod/rolePanels.zod.d.ts +2 -2
- package/dist/other/zod/rssFeed.zod.d.ts +153 -0
- package/dist/other/zod/rssFeed.zod.js +48 -0
- package/dist/other/zod/rumbleStreamer.zod.d.ts +2 -0
- package/dist/other/zod/schema.zod.d.ts +4 -1
- package/dist/other/zod/schema.zod.js +3 -0
- package/dist/other/zod/tiktokStreamer.zod.d.ts +2 -0
- package/dist/other/zod/twitchStreamer.zod.d.ts +2 -0
- package/dist/other/zod/twitterStreamer.zod.d.ts +2 -0
- package/dist/other/zod/whatnotStreamer.zod.d.ts +2 -0
- package/dist/other/zod/youtubeStreamer.zod.d.ts +2 -0
- package/dist/other/zod/zod.d.ts +2 -0
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +1 -1
- package/prisma/generated/ts-prisma.d.ts +2956 -0
- package/prisma/schema/models/rssFeed.prisma +131 -0
- package/prisma/schema/schema.prisma +3 -0
|
@@ -317,12 +317,27 @@ export declare const placeholders: {
|
|
|
317
317
|
twitter: {
|
|
318
318
|
platform: string;
|
|
319
319
|
postUrl: string;
|
|
320
|
+
directURL: string;
|
|
320
321
|
creatorName: string;
|
|
321
322
|
pingRole: string;
|
|
322
323
|
postText: string;
|
|
323
324
|
thumbnail: string;
|
|
324
325
|
videoUrl: string;
|
|
325
326
|
fxUrl: string;
|
|
327
|
+
defaultFixedURL: string;
|
|
328
|
+
publishDate: string;
|
|
329
|
+
randomMessage: string;
|
|
330
|
+
member: string;
|
|
331
|
+
};
|
|
332
|
+
rss: {
|
|
333
|
+
platform: string;
|
|
334
|
+
postUrl: string;
|
|
335
|
+
creatorName: string;
|
|
336
|
+
postTitle: string;
|
|
337
|
+
postAuthor: string;
|
|
338
|
+
pingRole: string;
|
|
339
|
+
postText: string;
|
|
340
|
+
thumbnail: string;
|
|
326
341
|
publishDate: string;
|
|
327
342
|
randomMessage: string;
|
|
328
343
|
member: string;
|
|
@@ -380,6 +395,7 @@ export declare const placeholders: {
|
|
|
380
395
|
userId: string;
|
|
381
396
|
userMention: string;
|
|
382
397
|
userAvatar: string;
|
|
398
|
+
guildIcon: string;
|
|
383
399
|
guildMemberCount: string;
|
|
384
400
|
};
|
|
385
401
|
leaveMessage: {
|
|
@@ -388,6 +404,7 @@ export declare const placeholders: {
|
|
|
388
404
|
userId: string;
|
|
389
405
|
userMention: string;
|
|
390
406
|
userAvatar: string;
|
|
407
|
+
guildIcon: string;
|
|
391
408
|
guildMemberCount: string;
|
|
392
409
|
};
|
|
393
410
|
boostMessage: {
|
|
@@ -396,6 +413,7 @@ export declare const placeholders: {
|
|
|
396
413
|
userId: string;
|
|
397
414
|
userMention: string;
|
|
398
415
|
userAvatar: string;
|
|
416
|
+
guildIcon: string;
|
|
399
417
|
boostCount: string;
|
|
400
418
|
boostLevel: string;
|
|
401
419
|
};
|
|
@@ -405,6 +423,7 @@ export declare const placeholders: {
|
|
|
405
423
|
userId: string;
|
|
406
424
|
userMention: string;
|
|
407
425
|
userAvatar: string;
|
|
426
|
+
guildIcon: string;
|
|
408
427
|
boostCount: string;
|
|
409
428
|
boostLevel: string;
|
|
410
429
|
boostDuration: string;
|
|
@@ -415,6 +434,7 @@ export declare const placeholders: {
|
|
|
415
434
|
userId: string;
|
|
416
435
|
userMention: string;
|
|
417
436
|
userAvatar: string;
|
|
437
|
+
guildIcon: string;
|
|
418
438
|
years: string;
|
|
419
439
|
joinedAt: string;
|
|
420
440
|
};
|
|
@@ -1220,6 +1240,35 @@ export declare const messages: {
|
|
|
1220
1240
|
url?: undefined;
|
|
1221
1241
|
})[];
|
|
1222
1242
|
};
|
|
1243
|
+
rss: {
|
|
1244
|
+
content: string;
|
|
1245
|
+
embed: {
|
|
1246
|
+
author: {
|
|
1247
|
+
name: string;
|
|
1248
|
+
url: string;
|
|
1249
|
+
};
|
|
1250
|
+
title: string;
|
|
1251
|
+
url: string;
|
|
1252
|
+
description: string;
|
|
1253
|
+
color: number;
|
|
1254
|
+
image: {
|
|
1255
|
+
url: string;
|
|
1256
|
+
};
|
|
1257
|
+
footer: {
|
|
1258
|
+
text: string;
|
|
1259
|
+
icon_url: string;
|
|
1260
|
+
};
|
|
1261
|
+
};
|
|
1262
|
+
buttons: ({
|
|
1263
|
+
label: string;
|
|
1264
|
+
style: number;
|
|
1265
|
+
url: string;
|
|
1266
|
+
} | {
|
|
1267
|
+
label: string;
|
|
1268
|
+
style: number;
|
|
1269
|
+
url?: undefined;
|
|
1270
|
+
})[];
|
|
1271
|
+
};
|
|
1223
1272
|
};
|
|
1224
1273
|
birthday: {
|
|
1225
1274
|
content: string;
|
package/dist/other/templates.js
CHANGED
|
@@ -328,12 +328,28 @@ exports.placeholders = {
|
|
|
328
328
|
twitter: {
|
|
329
329
|
'platform': 'X',
|
|
330
330
|
'postUrl': 'https://x.com/example/status/123',
|
|
331
|
+
'directURL': 'https://x.com/example/status/123',
|
|
331
332
|
'creatorName': 'Example',
|
|
332
333
|
'pingRole': '<@&123456789>',
|
|
333
334
|
'postText': 'Example post text',
|
|
334
335
|
'thumbnail': 'https://example.com',
|
|
335
336
|
'videoUrl': 'https://video.twimg.com/example.mp4',
|
|
336
|
-
'fxUrl': 'https://
|
|
337
|
+
'fxUrl': 'https://fxtwitter.com/example/status/123',
|
|
338
|
+
'defaultFixedURL': 'https://fxtwitter.com/example/status/123',
|
|
339
|
+
'publishDate': '<t:1640995200:R>',
|
|
340
|
+
'randomMessage': 'Example Message',
|
|
341
|
+
'member': '<@123456789>',
|
|
342
|
+
},
|
|
343
|
+
// RSS feeds: {creatorName} is the feed's title, {platform} the site's domain.
|
|
344
|
+
rss: {
|
|
345
|
+
'platform': 'example.com',
|
|
346
|
+
'postUrl': 'https://example.com/post',
|
|
347
|
+
'creatorName': 'Example Blog',
|
|
348
|
+
'postTitle': 'Example post title',
|
|
349
|
+
'postAuthor': 'Example Author',
|
|
350
|
+
'pingRole': '<@&123456789>',
|
|
351
|
+
'postText': 'Example post summary',
|
|
352
|
+
'thumbnail': 'https://example.com',
|
|
337
353
|
'publishDate': '<t:1640995200:R>',
|
|
338
354
|
'randomMessage': 'Example Message',
|
|
339
355
|
'member': '<@123456789>',
|
|
@@ -391,6 +407,7 @@ exports.placeholders = {
|
|
|
391
407
|
'userId': '123456789',
|
|
392
408
|
'userMention': '<@123456789>',
|
|
393
409
|
'userAvatar': 'https://example.com',
|
|
410
|
+
'guildIcon': 'https://cdn.discordapp.com/icons/123/example.png',
|
|
394
411
|
'guildMemberCount': '123',
|
|
395
412
|
},
|
|
396
413
|
leaveMessage: {
|
|
@@ -399,6 +416,7 @@ exports.placeholders = {
|
|
|
399
416
|
'userId': '123456789',
|
|
400
417
|
'userMention': '<@123456789>',
|
|
401
418
|
'userAvatar': 'https://example.com',
|
|
419
|
+
'guildIcon': 'https://cdn.discordapp.com/icons/123/example.png',
|
|
402
420
|
'guildMemberCount': '123',
|
|
403
421
|
},
|
|
404
422
|
boostMessage: {
|
|
@@ -407,6 +425,7 @@ exports.placeholders = {
|
|
|
407
425
|
'userId': '123456789',
|
|
408
426
|
'userMention': '<@123456789>',
|
|
409
427
|
'userAvatar': 'https://example.com',
|
|
428
|
+
'guildIcon': 'https://cdn.discordapp.com/icons/123/example.png',
|
|
410
429
|
'boostCount': '14',
|
|
411
430
|
'boostLevel': '2',
|
|
412
431
|
},
|
|
@@ -416,6 +435,7 @@ exports.placeholders = {
|
|
|
416
435
|
'userId': '123456789',
|
|
417
436
|
'userMention': '<@123456789>',
|
|
418
437
|
'userAvatar': 'https://example.com',
|
|
438
|
+
'guildIcon': 'https://cdn.discordapp.com/icons/123/example.png',
|
|
419
439
|
'boostCount': '13',
|
|
420
440
|
'boostLevel': '2',
|
|
421
441
|
'boostDuration': '3 months',
|
|
@@ -426,6 +446,7 @@ exports.placeholders = {
|
|
|
426
446
|
'userId': '123456789',
|
|
427
447
|
'userMention': '<@123456789>',
|
|
428
448
|
'userAvatar': 'https://example.com',
|
|
449
|
+
'guildIcon': 'https://cdn.discordapp.com/icons/123/example.png',
|
|
429
450
|
'years': '3',
|
|
430
451
|
'joinedAt': '<t:1700000000:D>',
|
|
431
452
|
},
|
|
@@ -1135,7 +1156,8 @@ exports.messages = {
|
|
|
1135
1156
|
buttons: exports.buttons.post,
|
|
1136
1157
|
},
|
|
1137
1158
|
twitter: {
|
|
1138
|
-
// {fxUrl} is the DEFAULT rendering for an X post: Discord
|
|
1159
|
+
// {defaultFixedURL} ({fxUrl} is its older name, still filled) is the DEFAULT rendering for an X post: Discord
|
|
1160
|
+
// unfurls the server's fixer (Guild.twitterFixedUrlHost, else fxtwitter) itself and shows the
|
|
1139
1161
|
// real tweet - inline video, multi-image, quotes, polls - which the embed cannot reproduce.
|
|
1140
1162
|
//
|
|
1141
1163
|
// The embed below is only sent when a server has EDITED it (AnyMessageEditor, Server Premium).
|
|
@@ -1146,7 +1168,7 @@ exports.messages = {
|
|
|
1146
1168
|
// BARE and on its own line, unlike the live and video templates which quote theirs, because
|
|
1147
1169
|
// here the unfurl IS the notification and anything wrapped around the url is one more thing
|
|
1148
1170
|
// between Discord and rendering the post.
|
|
1149
|
-
content: '{pingRole} {randomMessage}\n\n{
|
|
1171
|
+
content: '{pingRole} {randomMessage}\n\n{defaultFixedURL}',
|
|
1150
1172
|
embed: {
|
|
1151
1173
|
author: { name: '{creatorName} posted on X', url: '{postUrl}' },
|
|
1152
1174
|
url: '{postUrl}',
|
|
@@ -1160,6 +1182,23 @@ exports.messages = {
|
|
|
1160
1182
|
},
|
|
1161
1183
|
buttons: exports.buttons.post,
|
|
1162
1184
|
},
|
|
1185
|
+
// RSS feeds: the item title is the embed title, the feed is the author line. RSS orange.
|
|
1186
|
+
rss: {
|
|
1187
|
+
content: '{pingRole} {randomMessage}',
|
|
1188
|
+
embed: {
|
|
1189
|
+
author: { name: '{creatorName}', url: '{postUrl}' },
|
|
1190
|
+
title: '{postTitle}',
|
|
1191
|
+
url: '{postUrl}',
|
|
1192
|
+
description: '{postText}',
|
|
1193
|
+
color: 0xf26522,
|
|
1194
|
+
image: { url: '{thumbnail}' },
|
|
1195
|
+
footer: {
|
|
1196
|
+
text: 'Powered by Noti.',
|
|
1197
|
+
icon_url: 'https://noti.bot/logo.png',
|
|
1198
|
+
},
|
|
1199
|
+
},
|
|
1200
|
+
buttons: exports.buttons.post,
|
|
1201
|
+
},
|
|
1163
1202
|
},
|
|
1164
1203
|
birthday: {
|
|
1165
1204
|
content: '{userMention}',
|
package/dist/other/types.d.ts
CHANGED
|
@@ -38,6 +38,9 @@ export type GuildPlanType = {
|
|
|
38
38
|
defaultTiktokConnections: number | null;
|
|
39
39
|
defaultWhatnotConnections: number | null;
|
|
40
40
|
defaultClubConnections: number | null;
|
|
41
|
+
defaultRssConnections: number | null;
|
|
42
|
+
/** RSS check speed in minutes (15 / 10 / 5). */
|
|
43
|
+
rssPollMinutes: number | null;
|
|
41
44
|
defaultTwitterConnections: number | null;
|
|
42
45
|
defaultGameConnections: number | null;
|
|
43
46
|
defaultRobloxConnections: number | null;
|
|
@@ -56,6 +56,7 @@ export declare const ClientZod: {
|
|
|
56
56
|
whatnot: "whatnot";
|
|
57
57
|
club: "club";
|
|
58
58
|
twitter: "twitter";
|
|
59
|
+
rss: "rss";
|
|
59
60
|
}>;
|
|
60
61
|
}, z.core.$strip>>>;
|
|
61
62
|
twitchCredentials: z.ZodNullable<z.ZodLazy<z.ZodObject<{
|
|
@@ -117,6 +118,7 @@ export declare const ClientZod: {
|
|
|
117
118
|
whatnot: "whatnot";
|
|
118
119
|
club: "club";
|
|
119
120
|
twitter: "twitter";
|
|
121
|
+
rss: "rss";
|
|
120
122
|
}>;
|
|
121
123
|
}, z.core.$strip>;
|
|
122
124
|
};
|
|
@@ -79,6 +79,7 @@ export declare const GuildClipForwardZod: {
|
|
|
79
79
|
twitterPost: "twitterPost";
|
|
80
80
|
twitterLive: "twitterLive";
|
|
81
81
|
twitterOffline: "twitterOffline";
|
|
82
|
+
rssPost: "rssPost";
|
|
82
83
|
}>;
|
|
83
84
|
}, z.core.$strip>>>;
|
|
84
85
|
lastClipAt: z.ZodNullable<z.ZodDate>;
|
|
@@ -158,6 +159,7 @@ export declare const GuildClipForwardZod: {
|
|
|
158
159
|
twitterPost: "twitterPost";
|
|
159
160
|
twitterLive: "twitterLive";
|
|
160
161
|
twitterOffline: "twitterOffline";
|
|
162
|
+
rssPost: "rssPost";
|
|
161
163
|
}>;
|
|
162
164
|
}, z.core.$strip>>>>;
|
|
163
165
|
lastClipAt: z.ZodOptional<z.ZodNullable<z.ZodDate>>;
|
|
@@ -216,6 +218,7 @@ export declare const GuildClipForwardZod: {
|
|
|
216
218
|
twitterPost: "twitterPost";
|
|
217
219
|
twitterLive: "twitterLive";
|
|
218
220
|
twitterOffline: "twitterOffline";
|
|
221
|
+
rssPost: "rssPost";
|
|
219
222
|
}>;
|
|
220
223
|
}, z.core.$strip>;
|
|
221
224
|
};
|
|
@@ -78,6 +78,7 @@ export declare const ClubStreamerZod: {
|
|
|
78
78
|
twitterPost: "twitterPost";
|
|
79
79
|
twitterLive: "twitterLive";
|
|
80
80
|
twitterOffline: "twitterOffline";
|
|
81
|
+
rssPost: "rssPost";
|
|
81
82
|
}>;
|
|
82
83
|
}, z.core.$strip>>>;
|
|
83
84
|
notificationChannelId: z.ZodNullable<z.ZodString>;
|
|
@@ -140,6 +141,7 @@ export declare const ClubStreamerZod: {
|
|
|
140
141
|
twitterPost: "twitterPost";
|
|
141
142
|
twitterLive: "twitterLive";
|
|
142
143
|
twitterOffline: "twitterOffline";
|
|
144
|
+
rssPost: "rssPost";
|
|
143
145
|
}>;
|
|
144
146
|
}, z.core.$strip>;
|
|
145
147
|
};
|
|
@@ -11,9 +11,9 @@ export declare const GameConfigZod: {
|
|
|
11
11
|
notificationChannelId: z.ZodNullable<z.ZodString>;
|
|
12
12
|
pingRoleId: z.ZodNullable<z.ZodUnion<readonly [z.ZodString, z.ZodLiteral<"everyone">, z.ZodLiteral<"here">]>>;
|
|
13
13
|
deliveryMode: z.ZodEnum<{
|
|
14
|
+
scheduled: "scheduled";
|
|
14
15
|
instant: "instant";
|
|
15
16
|
window: "window";
|
|
16
|
-
scheduled: "scheduled";
|
|
17
17
|
}>;
|
|
18
18
|
windowStartHour: z.ZodNullable<z.ZodNumber>;
|
|
19
19
|
windowEndHour: z.ZodNullable<z.ZodNumber>;
|
|
@@ -82,6 +82,12 @@ export declare const GuildZod: {
|
|
|
82
82
|
leaveEnabled: z.ZodNullable<z.ZodBoolean>;
|
|
83
83
|
syncUsername: z.ZodNullable<z.ZodBoolean>;
|
|
84
84
|
vodDownloadStoreForHours: z.ZodNullable<z.ZodNumber>;
|
|
85
|
+
twitterFixedUrlHost: z.ZodNullable<z.ZodEnum<{
|
|
86
|
+
"fxtwitter.com": "fxtwitter.com";
|
|
87
|
+
"fixupx.com": "fixupx.com";
|
|
88
|
+
"vxtwitter.com": "vxtwitter.com";
|
|
89
|
+
"fixvx.com": "fixvx.com";
|
|
90
|
+
}>>;
|
|
85
91
|
disableDoubleVoteEntry: z.ZodNullable<z.ZodBoolean>;
|
|
86
92
|
giveawayLogsChannelId: z.ZodNullable<z.ZodString>;
|
|
87
93
|
notiLogsChannelId: z.ZodNullable<z.ZodString>;
|
|
@@ -122,6 +128,7 @@ export declare const GuildZod: {
|
|
|
122
128
|
twitterPost: "twitterPost";
|
|
123
129
|
twitterLive: "twitterLive";
|
|
124
130
|
twitterOffline: "twitterOffline";
|
|
131
|
+
rssPost: "rssPost";
|
|
125
132
|
}>;
|
|
126
133
|
messages: z.ZodArray<z.ZodString>;
|
|
127
134
|
}, z.core.$strip>>>;
|
|
@@ -169,6 +176,7 @@ export declare const GuildZod: {
|
|
|
169
176
|
whatnot: "whatnot";
|
|
170
177
|
club: "club";
|
|
171
178
|
twitter: "twitter";
|
|
179
|
+
rss: "rss";
|
|
172
180
|
}>>;
|
|
173
181
|
applyToStreamers: z.ZodArray<z.ZodString>;
|
|
174
182
|
filter: z.ZodNullable<z.ZodLazy<z.ZodObject<{
|
|
@@ -203,6 +211,7 @@ export declare const GuildZod: {
|
|
|
203
211
|
whatnot: "whatnot";
|
|
204
212
|
club: "club";
|
|
205
213
|
twitter: "twitter";
|
|
214
|
+
rss: "rss";
|
|
206
215
|
}>>;
|
|
207
216
|
applyToStreamers: z.ZodArray<z.ZodString>;
|
|
208
217
|
applyToTypes: z.ZodArray<z.ZodEnum<{
|
|
@@ -305,6 +314,7 @@ export declare const GuildZod: {
|
|
|
305
314
|
twitterPost: "twitterPost";
|
|
306
315
|
twitterLive: "twitterLive";
|
|
307
316
|
twitterOffline: "twitterOffline";
|
|
317
|
+
rssPost: "rssPost";
|
|
308
318
|
}>;
|
|
309
319
|
}, z.core.$strip>>>;
|
|
310
320
|
stickyMessages: z.ZodArray<z.ZodLazy<z.ZodObject<{
|
|
@@ -458,6 +468,7 @@ export declare const GuildZod: {
|
|
|
458
468
|
whatnot: "whatnot";
|
|
459
469
|
club: "club";
|
|
460
470
|
twitter: "twitter";
|
|
471
|
+
rss: "rss";
|
|
461
472
|
}>>;
|
|
462
473
|
applyToStreamers: z.ZodArray<z.ZodString>;
|
|
463
474
|
applyToTypes: z.ZodArray<z.ZodEnum<{
|
|
@@ -564,6 +575,7 @@ export declare const GuildZod: {
|
|
|
564
575
|
twitterPost: "twitterPost";
|
|
565
576
|
twitterLive: "twitterLive";
|
|
566
577
|
twitterOffline: "twitterOffline";
|
|
578
|
+
rssPost: "rssPost";
|
|
567
579
|
}>;
|
|
568
580
|
}, z.core.$strip>;
|
|
569
581
|
readonly GuildStickyMessageSchema: z.ZodObject<{
|
|
@@ -34,6 +34,8 @@ const GuildSchema = zod_2.z.object({
|
|
|
34
34
|
leaveEnabled: zod_2.z.boolean().nullable(),
|
|
35
35
|
syncUsername: zod_2.z.boolean().nullable(),
|
|
36
36
|
vodDownloadStoreForHours: zod_2.z.number().min(0).nullable(),
|
|
37
|
+
/** Fixer host for the X post notification link ({defaultFixedURL}). null = the bot's default (fxtwitter.com). Free. */
|
|
38
|
+
twitterFixedUrlHost: zod_2.z.enum(['fxtwitter.com', 'fixupx.com', 'vxtwitter.com', 'fixvx.com']).nullable(),
|
|
37
39
|
disableDoubleVoteEntry: zod_2.z.boolean().nullable(),
|
|
38
40
|
giveawayLogsChannelId: zod_1.SnowFlake.nullable(),
|
|
39
41
|
notiLogsChannelId: zod_1.SnowFlake.nullable(),
|
|
@@ -83,6 +83,7 @@ export declare const KickStreamerZod: {
|
|
|
83
83
|
twitterPost: "twitterPost";
|
|
84
84
|
twitterLive: "twitterLive";
|
|
85
85
|
twitterOffline: "twitterOffline";
|
|
86
|
+
rssPost: "rssPost";
|
|
86
87
|
}>;
|
|
87
88
|
}, z.core.$strip>>>;
|
|
88
89
|
clipEnabled: z.ZodNullable<z.ZodBoolean>;
|
|
@@ -214,6 +215,7 @@ export declare const KickStreamerZod: {
|
|
|
214
215
|
twitterPost: "twitterPost";
|
|
215
216
|
twitterLive: "twitterLive";
|
|
216
217
|
twitterOffline: "twitterOffline";
|
|
218
|
+
rssPost: "rssPost";
|
|
217
219
|
}>;
|
|
218
220
|
}, z.core.$strip>;
|
|
219
221
|
readonly KSRoleWithUsersSchema: z.ZodObject<{
|
|
@@ -12,9 +12,9 @@ export declare const GuildRolePanelZod: {
|
|
|
12
12
|
dropdown: "dropdown";
|
|
13
13
|
}>;
|
|
14
14
|
assignMode: z.ZodEnum<{
|
|
15
|
+
limit: "limit";
|
|
15
16
|
toggle: "toggle";
|
|
16
17
|
unique: "unique";
|
|
17
|
-
limit: "limit";
|
|
18
18
|
verify: "verify";
|
|
19
19
|
}>;
|
|
20
20
|
messageId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
@@ -67,9 +67,9 @@ export declare const GuildRolePanelZod: {
|
|
|
67
67
|
dropdown: "dropdown";
|
|
68
68
|
}>;
|
|
69
69
|
assignMode: z.ZodEnum<{
|
|
70
|
+
limit: "limit";
|
|
70
71
|
toggle: "toggle";
|
|
71
72
|
unique: "unique";
|
|
72
|
-
limit: "limit";
|
|
73
73
|
verify: "verify";
|
|
74
74
|
}>;
|
|
75
75
|
maxRoles: z.ZodNullable<z.ZodNumber>;
|
|
@@ -0,0 +1,153 @@
|
|
|
1
|
+
import { PartialZodObject } from './schema.zod';
|
|
2
|
+
import { RemoveProperties } from '../prisma';
|
|
3
|
+
import { TSPrisma } from '@prisma/client';
|
|
4
|
+
import { z } from 'zod';
|
|
5
|
+
export type RT<T extends TSPrisma.AllModelNames> = z.ZodType<RemoveProperties<TSPrisma.TSPrismaModelsFull[T], RssFeedRelations>>;
|
|
6
|
+
export type RssFeedRelations = 'db' | 'rssFeed' | 'rfCustomMessage' | 'rfMessageEmbed';
|
|
7
|
+
export declare const RssFeedZod: {
|
|
8
|
+
readonly RssFeedSchema: z.ZodObject<{
|
|
9
|
+
streamerUserName: z.ZodString;
|
|
10
|
+
position: z.ZodNullable<z.ZodNumber>;
|
|
11
|
+
createdAt: z.ZodCoercedDate<unknown>;
|
|
12
|
+
limitLocked: z.ZodBoolean;
|
|
13
|
+
guildId: z.ZodString;
|
|
14
|
+
usePerStreamerEmbeds: z.ZodNullable<z.ZodBoolean>;
|
|
15
|
+
autoPublishIfAnnouncmentChannel: z.ZodNullable<z.ZodBoolean>;
|
|
16
|
+
extraDestinations: z.ZodNullable<z.ZodArray<z.ZodObject<{
|
|
17
|
+
channelId: z.ZodString;
|
|
18
|
+
pingRoleId: z.ZodNullable<z.ZodUnion<readonly [z.ZodString, z.ZodLiteral<"everyone">, z.ZodLiteral<"here">]>>;
|
|
19
|
+
types: z.ZodArray<z.ZodEnum<{
|
|
20
|
+
post: "post";
|
|
21
|
+
}>>;
|
|
22
|
+
}, z.core.$strip>>>;
|
|
23
|
+
inGame: z.ZodBoolean;
|
|
24
|
+
inGameTypes: z.ZodArray<z.ZodEnum<{
|
|
25
|
+
post: "post";
|
|
26
|
+
}>>;
|
|
27
|
+
inGameServerIds: z.ZodArray<z.ZodString>;
|
|
28
|
+
customMessages: z.ZodArray<z.ZodLazy<z.ZodObject<{
|
|
29
|
+
content: z.ZodNullable<z.ZodString>;
|
|
30
|
+
showInviteButton: z.ZodNullable<z.ZodBoolean>;
|
|
31
|
+
showWatchButton: z.ZodNullable<z.ZodBoolean>;
|
|
32
|
+
embed: z.ZodNullable<z.ZodLazy<z.ZodObject<{
|
|
33
|
+
title: z.ZodNullable<z.ZodString>;
|
|
34
|
+
url: z.ZodNullable<z.ZodString>;
|
|
35
|
+
description: z.ZodPipe<z.ZodDefault<z.ZodNullable<z.ZodString>>, z.ZodTransform<string | null, string | null>>;
|
|
36
|
+
color: z.ZodNullable<z.ZodString>;
|
|
37
|
+
footer: z.ZodNullable<z.ZodString>;
|
|
38
|
+
footerIcon: z.ZodNullable<z.ZodString>;
|
|
39
|
+
image: z.ZodNullable<z.ZodString>;
|
|
40
|
+
thumbnail: z.ZodNullable<z.ZodString>;
|
|
41
|
+
author: z.ZodNullable<z.ZodString>;
|
|
42
|
+
authorIcon: z.ZodNullable<z.ZodString>;
|
|
43
|
+
fields: z.ZodArray<z.ZodLazy<z.ZodObject<{
|
|
44
|
+
name: z.ZodString;
|
|
45
|
+
value: z.ZodNullable<z.ZodString>;
|
|
46
|
+
inline: z.ZodNullable<z.ZodBoolean>;
|
|
47
|
+
}, z.core.$strip>>>;
|
|
48
|
+
}, z.core.$strip>>>;
|
|
49
|
+
buttons: z.ZodArray<z.ZodLazy<z.ZodObject<{
|
|
50
|
+
title: z.ZodString;
|
|
51
|
+
url: z.ZodNullable<z.ZodString>;
|
|
52
|
+
emojiUnicodeOrId: z.ZodNullable<z.ZodString>;
|
|
53
|
+
}, z.core.$strip>>>;
|
|
54
|
+
webhook: z.ZodNullable<z.ZodLazy<z.ZodObject<{
|
|
55
|
+
enabled: z.ZodNullable<z.ZodBoolean>;
|
|
56
|
+
username: z.ZodNullable<z.ZodString>;
|
|
57
|
+
avatarUrl: z.ZodNullable<z.ZodString>;
|
|
58
|
+
}, z.core.$strip>>>;
|
|
59
|
+
type: z.ZodEnum<{
|
|
60
|
+
clip: "clip";
|
|
61
|
+
clipForward: "clipForward";
|
|
62
|
+
vod: "vod";
|
|
63
|
+
kickLive: "kickLive";
|
|
64
|
+
kickOffline: "kickOffline";
|
|
65
|
+
twitchLive: "twitchLive";
|
|
66
|
+
twitchOffline: "twitchOffline";
|
|
67
|
+
rumbleLive: "rumbleLive";
|
|
68
|
+
rumbleOffline: "rumbleOffline";
|
|
69
|
+
rumbleVideo: "rumbleVideo";
|
|
70
|
+
tiktokLive: "tiktokLive";
|
|
71
|
+
tiktokOffline: "tiktokOffline";
|
|
72
|
+
tiktokVideo: "tiktokVideo";
|
|
73
|
+
youtubeLive: "youtubeLive";
|
|
74
|
+
youtubeVideo: "youtubeVideo";
|
|
75
|
+
whatnotLive: "whatnotLive";
|
|
76
|
+
whatnotOffline: "whatnotOffline";
|
|
77
|
+
clubPost: "clubPost";
|
|
78
|
+
twitterPost: "twitterPost";
|
|
79
|
+
twitterLive: "twitterLive";
|
|
80
|
+
twitterOffline: "twitterOffline";
|
|
81
|
+
rssPost: "rssPost";
|
|
82
|
+
}>;
|
|
83
|
+
}, z.core.$strip>>>;
|
|
84
|
+
notificationChannelId: z.ZodNullable<z.ZodString>;
|
|
85
|
+
showNotifyButton: z.ZodNullable<z.ZodBoolean>;
|
|
86
|
+
pingRoleId: z.ZodNullable<z.ZodUnion<readonly [z.ZodString, z.ZodLiteral<"everyone">, z.ZodLiteral<"here">]>>;
|
|
87
|
+
customCoolDownBeforeNextPost: z.ZodNullable<z.ZodNumber>;
|
|
88
|
+
feedUrl: z.ZodString;
|
|
89
|
+
feedTitle: z.ZodNullable<z.ZodString>;
|
|
90
|
+
lastItemId: z.ZodNullable<z.ZodString>;
|
|
91
|
+
lastPostAt: z.ZodNullable<z.ZodDate>;
|
|
92
|
+
failCount: z.ZodNumber;
|
|
93
|
+
lastError: z.ZodNullable<z.ZodString>;
|
|
94
|
+
failingSince: z.ZodNullable<z.ZodDate>;
|
|
95
|
+
}, z.core.$strip>;
|
|
96
|
+
readonly RFCustomMessageSchema: z.ZodObject<{
|
|
97
|
+
content: z.ZodNullable<z.ZodString>;
|
|
98
|
+
showInviteButton: z.ZodNullable<z.ZodBoolean>;
|
|
99
|
+
showWatchButton: z.ZodNullable<z.ZodBoolean>;
|
|
100
|
+
embed: z.ZodNullable<z.ZodLazy<z.ZodObject<{
|
|
101
|
+
title: z.ZodNullable<z.ZodString>;
|
|
102
|
+
url: z.ZodNullable<z.ZodString>;
|
|
103
|
+
description: z.ZodPipe<z.ZodDefault<z.ZodNullable<z.ZodString>>, z.ZodTransform<string | null, string | null>>;
|
|
104
|
+
color: z.ZodNullable<z.ZodString>;
|
|
105
|
+
footer: z.ZodNullable<z.ZodString>;
|
|
106
|
+
footerIcon: z.ZodNullable<z.ZodString>;
|
|
107
|
+
image: z.ZodNullable<z.ZodString>;
|
|
108
|
+
thumbnail: z.ZodNullable<z.ZodString>;
|
|
109
|
+
author: z.ZodNullable<z.ZodString>;
|
|
110
|
+
authorIcon: z.ZodNullable<z.ZodString>;
|
|
111
|
+
fields: z.ZodArray<z.ZodLazy<z.ZodObject<{
|
|
112
|
+
name: z.ZodString;
|
|
113
|
+
value: z.ZodNullable<z.ZodString>;
|
|
114
|
+
inline: z.ZodNullable<z.ZodBoolean>;
|
|
115
|
+
}, z.core.$strip>>>;
|
|
116
|
+
}, z.core.$strip>>>;
|
|
117
|
+
buttons: z.ZodArray<z.ZodLazy<z.ZodObject<{
|
|
118
|
+
title: z.ZodString;
|
|
119
|
+
url: z.ZodNullable<z.ZodString>;
|
|
120
|
+
emojiUnicodeOrId: z.ZodNullable<z.ZodString>;
|
|
121
|
+
}, z.core.$strip>>>;
|
|
122
|
+
webhook: z.ZodNullable<z.ZodLazy<z.ZodObject<{
|
|
123
|
+
enabled: z.ZodNullable<z.ZodBoolean>;
|
|
124
|
+
username: z.ZodNullable<z.ZodString>;
|
|
125
|
+
avatarUrl: z.ZodNullable<z.ZodString>;
|
|
126
|
+
}, z.core.$strip>>>;
|
|
127
|
+
type: z.ZodEnum<{
|
|
128
|
+
clip: "clip";
|
|
129
|
+
clipForward: "clipForward";
|
|
130
|
+
vod: "vod";
|
|
131
|
+
kickLive: "kickLive";
|
|
132
|
+
kickOffline: "kickOffline";
|
|
133
|
+
twitchLive: "twitchLive";
|
|
134
|
+
twitchOffline: "twitchOffline";
|
|
135
|
+
rumbleLive: "rumbleLive";
|
|
136
|
+
rumbleOffline: "rumbleOffline";
|
|
137
|
+
rumbleVideo: "rumbleVideo";
|
|
138
|
+
tiktokLive: "tiktokLive";
|
|
139
|
+
tiktokOffline: "tiktokOffline";
|
|
140
|
+
tiktokVideo: "tiktokVideo";
|
|
141
|
+
youtubeLive: "youtubeLive";
|
|
142
|
+
youtubeVideo: "youtubeVideo";
|
|
143
|
+
whatnotLive: "whatnotLive";
|
|
144
|
+
whatnotOffline: "whatnotOffline";
|
|
145
|
+
clubPost: "clubPost";
|
|
146
|
+
twitterPost: "twitterPost";
|
|
147
|
+
twitterLive: "twitterLive";
|
|
148
|
+
twitterOffline: "twitterOffline";
|
|
149
|
+
rssPost: "rssPost";
|
|
150
|
+
}>;
|
|
151
|
+
}, z.core.$strip>;
|
|
152
|
+
};
|
|
153
|
+
export declare const RssFeedZodPartial: PartialZodObject<typeof RssFeedZod>;
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.RssFeedZodPartial = exports.RssFeedZod = void 0;
|
|
4
|
+
const schema_zod_1 = require("./schema.zod");
|
|
5
|
+
const multiDestination_1 = require("../multiDestination");
|
|
6
|
+
const inGameAlerts_1 = require("../inGameAlerts");
|
|
7
|
+
const zod_1 = require("./zod");
|
|
8
|
+
const zod_2 = require("zod");
|
|
9
|
+
const RssFeedSchema = zod_2.z.object({
|
|
10
|
+
// The normalised feed URL (phases/rss/) - the unique key with guildId, like a handle on other platforms.
|
|
11
|
+
streamerUserName: zod_2.z.string().url().max(2000),
|
|
12
|
+
// Creator order (phases/creator-order/): server-managed - stripped from every save (filters.ts *InternalKeys).
|
|
13
|
+
position: zod_2.z.number().int().nullable(),
|
|
14
|
+
createdAt: zod_2.z.coerce.date(),
|
|
15
|
+
limitLocked: zod_2.z.boolean(),
|
|
16
|
+
guildId: zod_1.SnowFlake,
|
|
17
|
+
usePerStreamerEmbeds: zod_2.z.boolean().nullable(),
|
|
18
|
+
autoPublishIfAnnouncmentChannel: zod_2.z.boolean().nullable(),
|
|
19
|
+
// Premium Plus (`MultiDestination`): up to 2 extra channels, each with its own ping role and post types.
|
|
20
|
+
extraDestinations: zod_1.CentralZod.ExtraDestinations(multiDestination_1.DESTINATION_TYPES.rss).nullable(),
|
|
21
|
+
// Minecraft (phases/in-game/ P3). The creator routes refuse these without the `inGame` flag.
|
|
22
|
+
inGame: zod_2.z.boolean(),
|
|
23
|
+
inGameTypes: (0, zod_1.NoDuplicate)(zod_2.z.array(zod_2.z.enum(inGameAlerts_1.IN_GAME_TYPES.rss))),
|
|
24
|
+
inGameServerIds: (0, zod_1.NoDuplicate)(zod_2.z.array(zod_2.z.string().uuid())).max(inGameAlerts_1.MAX_IN_GAME_SERVER_PICKS),
|
|
25
|
+
customMessages: (0, zod_1.NoDuplicate)(zod_2.z.array(zod_2.z.lazy(() => RFCustomMessageSchema)), ['type']),
|
|
26
|
+
notificationChannelId: zod_1.SnowFlake.nullable(),
|
|
27
|
+
showNotifyButton: zod_2.z.boolean().nullable(),
|
|
28
|
+
pingRoleId: zod_1.SnowFlakeOrEveryone.nullable(),
|
|
29
|
+
customCoolDownBeforeNextPost: zod_2.z.number().min(0).max(360).nullable(),
|
|
30
|
+
// The fetchable URL, case kept (streamerUserName is the lower-cased key). Set on add, never by a save.
|
|
31
|
+
feedUrl: zod_2.z.string().url().max(2000),
|
|
32
|
+
// Feed state (phases/rss/): written by the poller, stripped from every save like the other internals.
|
|
33
|
+
feedTitle: zod_2.z.string().max(300).nullable(),
|
|
34
|
+
lastItemId: zod_2.z.string().nullable(),
|
|
35
|
+
lastPostAt: zod_2.z.date().nullable(),
|
|
36
|
+
failCount: zod_2.z.number().int(),
|
|
37
|
+
lastError: zod_2.z.string().nullable(),
|
|
38
|
+
failingSince: zod_2.z.date().nullable(),
|
|
39
|
+
});
|
|
40
|
+
const RFCustomMessageSchema = zod_2.z.object({
|
|
41
|
+
type: schema_zod_1.StreamerMessageTypeEnum,
|
|
42
|
+
...zod_1.CentralZod.Message(),
|
|
43
|
+
});
|
|
44
|
+
exports.RssFeedZod = {
|
|
45
|
+
RssFeedSchema,
|
|
46
|
+
RFCustomMessageSchema,
|
|
47
|
+
};
|
|
48
|
+
exports.RssFeedZodPartial = Object.fromEntries(Object.entries(exports.RssFeedZod).map(([key, value]) => [key, (0, schema_zod_1.deepPartialify)(value)]));
|
|
@@ -88,6 +88,7 @@ export declare const RumbleStreamerZod: {
|
|
|
88
88
|
twitterPost: "twitterPost";
|
|
89
89
|
twitterLive: "twitterLive";
|
|
90
90
|
twitterOffline: "twitterOffline";
|
|
91
|
+
rssPost: "rssPost";
|
|
91
92
|
}>;
|
|
92
93
|
}, z.core.$strip>>>;
|
|
93
94
|
notificationChannelId: z.ZodNullable<z.ZodString>;
|
|
@@ -173,6 +174,7 @@ export declare const RumbleStreamerZod: {
|
|
|
173
174
|
twitterPost: "twitterPost";
|
|
174
175
|
twitterLive: "twitterLive";
|
|
175
176
|
twitterOffline: "twitterOffline";
|
|
177
|
+
rssPost: "rssPost";
|
|
176
178
|
}>;
|
|
177
179
|
}, z.core.$strip>;
|
|
178
180
|
readonly RSStatsChannelIdSchema: z.ZodObject<{
|
|
@@ -42,6 +42,7 @@ export declare const StreamerMessageTypeEnum: z.ZodEnum<{
|
|
|
42
42
|
twitterPost: "twitterPost";
|
|
43
43
|
twitterLive: "twitterLive";
|
|
44
44
|
twitterOffline: "twitterOffline";
|
|
45
|
+
rssPost: "rssPost";
|
|
45
46
|
}>;
|
|
46
47
|
export declare const GuildMessageTypeEnum: z.ZodEnum<{
|
|
47
48
|
birthday: "birthday";
|
|
@@ -77,6 +78,7 @@ export declare const GuildMessageTypeEnum: z.ZodEnum<{
|
|
|
77
78
|
twitterPost: "twitterPost";
|
|
78
79
|
twitterLive: "twitterLive";
|
|
79
80
|
twitterOffline: "twitterOffline";
|
|
81
|
+
rssPost: "rssPost";
|
|
80
82
|
}>;
|
|
81
83
|
export declare const GuildSingleMessageTypeEnum: z.ZodEnum<{
|
|
82
84
|
autoLiveRoleAdded: "autoLiveRoleAdded";
|
|
@@ -106,6 +108,7 @@ export declare const PlatformEnum: z.ZodEnum<{
|
|
|
106
108
|
whatnot: "whatnot";
|
|
107
109
|
club: "club";
|
|
108
110
|
twitter: "twitter";
|
|
111
|
+
rss: "rss";
|
|
109
112
|
}>;
|
|
110
113
|
export declare const ClipForwardPlatformEnum: z.ZodEnum<{
|
|
111
114
|
kick: "kick";
|
|
@@ -202,9 +205,9 @@ export declare const GameDeliveryEnum: z.ZodEnum<{
|
|
|
202
205
|
instant: "instant";
|
|
203
206
|
}>;
|
|
204
207
|
export declare const NotificationDeliveryEnum: z.ZodEnum<{
|
|
208
|
+
scheduled: "scheduled";
|
|
205
209
|
instant: "instant";
|
|
206
210
|
window: "window";
|
|
207
|
-
scheduled: "scheduled";
|
|
208
211
|
}>;
|
|
209
212
|
export declare const GameRobloxKindEnum: z.ZodEnum<{
|
|
210
213
|
updates: "updates";
|