@distilled.cloud/twitch 0.0.0 → 1.0.0-rc.21

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 (214) hide show
  1. package/LICENSE +201 -0
  2. package/README.md +79 -4
  3. package/lib/.lazy.json +1 -0
  4. package/lib/_bundle/lazy.js +4 -0
  5. package/lib/_bundle/sdk.js +2 -0
  6. package/lib/_bundle/sdk.js.map +1 -0
  7. package/lib/credentials.d.ts +31 -0
  8. package/lib/credentials.d.ts.map +1 -0
  9. package/lib/credentials.js +1 -0
  10. package/lib/errors.d.ts +49 -0
  11. package/lib/errors.d.ts.map +1 -0
  12. package/lib/errors.js +1 -0
  13. package/lib/index.d.ts +46 -0
  14. package/lib/index.d.ts.map +1 -0
  15. package/lib/index.js +6 -0
  16. package/lib/pagination.d.ts +10 -0
  17. package/lib/pagination.d.ts.map +1 -0
  18. package/lib/pagination.js +1 -0
  19. package/lib/protocol.d.ts +19 -0
  20. package/lib/protocol.d.ts.map +1 -0
  21. package/lib/protocol.js +1 -0
  22. package/lib/retry.d.ts +50 -0
  23. package/lib/retry.d.ts.map +1 -0
  24. package/lib/retry.js +1 -0
  25. package/lib/services/ads.d.ts +75 -0
  26. package/lib/services/ads.d.ts.map +1 -0
  27. package/lib/services/ads.js +2 -0
  28. package/lib/services/ads.js.map +1 -0
  29. package/lib/services/analytics.d.ts +90 -0
  30. package/lib/services/analytics.d.ts.map +1 -0
  31. package/lib/services/analytics.js +2 -0
  32. package/lib/services/analytics.js.map +1 -0
  33. package/lib/services/bits.d.ts +284 -0
  34. package/lib/services/bits.d.ts.map +1 -0
  35. package/lib/services/bits.js +2 -0
  36. package/lib/services/bits.js.map +1 -0
  37. package/lib/services/ccls.d.ts +26 -0
  38. package/lib/services/ccls.d.ts.map +1 -0
  39. package/lib/services/ccls.js +2 -0
  40. package/lib/services/ccls.js.map +1 -0
  41. package/lib/services/channel_points.d.ts +416 -0
  42. package/lib/services/channel_points.d.ts.map +1 -0
  43. package/lib/services/channel_points.js +2 -0
  44. package/lib/services/channel_points.js.map +1 -0
  45. package/lib/services/channels.d.ts +173 -0
  46. package/lib/services/channels.d.ts.map +1 -0
  47. package/lib/services/channels.js +2 -0
  48. package/lib/services/channels.js.map +1 -0
  49. package/lib/services/charity.d.ts +97 -0
  50. package/lib/services/charity.d.ts.map +1 -0
  51. package/lib/services/charity.js +2 -0
  52. package/lib/services/charity.js.map +1 -0
  53. package/lib/services/chat.d.ts +638 -0
  54. package/lib/services/chat.d.ts.map +1 -0
  55. package/lib/services/chat.js +33 -0
  56. package/lib/services/chat.js.map +1 -0
  57. package/lib/services/clips.d.ts +153 -0
  58. package/lib/services/clips.d.ts.map +1 -0
  59. package/lib/services/clips.js +2 -0
  60. package/lib/services/clips.js.map +1 -0
  61. package/lib/services/conduits.d.ts +172 -0
  62. package/lib/services/conduits.d.ts.map +1 -0
  63. package/lib/services/conduits.js +2 -0
  64. package/lib/services/conduits.js.map +1 -0
  65. package/lib/services/entitlements.d.ts +76 -0
  66. package/lib/services/entitlements.d.ts.map +1 -0
  67. package/lib/services/entitlements.js +2 -0
  68. package/lib/services/entitlements.js.map +1 -0
  69. package/lib/services/eventsub.d.ts +158 -0
  70. package/lib/services/eventsub.d.ts.map +1 -0
  71. package/lib/services/eventsub.js +2 -0
  72. package/lib/services/eventsub.js.map +1 -0
  73. package/lib/services/extensions.d.ts +497 -0
  74. package/lib/services/extensions.d.ts.map +1 -0
  75. package/lib/services/extensions.js +2 -0
  76. package/lib/services/extensions.js.map +1 -0
  77. package/lib/services/games.d.ts +57 -0
  78. package/lib/services/games.d.ts.map +1 -0
  79. package/lib/services/games.js +2 -0
  80. package/lib/services/games.js.map +1 -0
  81. package/lib/services/goals.d.ts +37 -0
  82. package/lib/services/goals.d.ts.map +1 -0
  83. package/lib/services/goals.js +2 -0
  84. package/lib/services/goals.js.map +1 -0
  85. package/lib/services/guest_star.d.ts +314 -0
  86. package/lib/services/guest_star.d.ts.map +1 -0
  87. package/lib/services/guest_star.js +2 -0
  88. package/lib/services/guest_star.js.map +1 -0
  89. package/lib/services/hype_train.d.ts +91 -0
  90. package/lib/services/hype_train.d.ts.map +1 -0
  91. package/lib/services/hype_train.js +2 -0
  92. package/lib/services/hype_train.js.map +1 -0
  93. package/lib/services/index.d.ts +30 -0
  94. package/lib/services/index.d.ts.map +1 -0
  95. package/lib/services/index.js +29 -0
  96. package/lib/services/moderation.d.ts +731 -0
  97. package/lib/services/moderation.d.ts.map +1 -0
  98. package/lib/services/moderation.js +41 -0
  99. package/lib/services/moderation.js.map +1 -0
  100. package/lib/services/polls.d.ts +173 -0
  101. package/lib/services/polls.d.ts.map +1 -0
  102. package/lib/services/polls.js +2 -0
  103. package/lib/services/polls.js.map +1 -0
  104. package/lib/services/predictions.d.ts +221 -0
  105. package/lib/services/predictions.d.ts.map +1 -0
  106. package/lib/services/predictions.js +2 -0
  107. package/lib/services/predictions.js.map +1 -0
  108. package/lib/services/raids.d.ts +34 -0
  109. package/lib/services/raids.d.ts.map +1 -0
  110. package/lib/services/raids.js +2 -0
  111. package/lib/services/raids.js.map +1 -0
  112. package/lib/services/schedule.d.ts +223 -0
  113. package/lib/services/schedule.d.ts.map +1 -0
  114. package/lib/services/schedule.js +2 -0
  115. package/lib/services/schedule.js.map +1 -0
  116. package/lib/services/search.d.ts +89 -0
  117. package/lib/services/search.d.ts.map +1 -0
  118. package/lib/services/search.js +2 -0
  119. package/lib/services/search.js.map +1 -0
  120. package/lib/services/streams.d.ts +235 -0
  121. package/lib/services/streams.d.ts.map +1 -0
  122. package/lib/services/streams.js +2 -0
  123. package/lib/services/streams.js.map +1 -0
  124. package/lib/services/subscriptions.d.ts +96 -0
  125. package/lib/services/subscriptions.d.ts.map +1 -0
  126. package/lib/services/subscriptions.js +2 -0
  127. package/lib/services/subscriptions.js.map +1 -0
  128. package/lib/services/teams.d.ts +90 -0
  129. package/lib/services/teams.d.ts.map +1 -0
  130. package/lib/services/teams.js +2 -0
  131. package/lib/services/teams.js.map +1 -0
  132. package/lib/services/users.d.ts +324 -0
  133. package/lib/services/users.d.ts.map +1 -0
  134. package/lib/services/users.js +2 -0
  135. package/lib/services/users.js.map +1 -0
  136. package/lib/services/videos.d.ts +101 -0
  137. package/lib/services/videos.d.ts.map +1 -0
  138. package/lib/services/videos.js +2 -0
  139. package/lib/services/videos.js.map +1 -0
  140. package/lib/services/whispers.d.ts +17 -0
  141. package/lib/services/whispers.d.ts.map +1 -0
  142. package/lib/services/whispers.js +2 -0
  143. package/lib/services/whispers.js.map +1 -0
  144. package/lib/services.lazy/ads.js +1 -0
  145. package/lib/services.lazy/analytics.js +1 -0
  146. package/lib/services.lazy/bits.js +1 -0
  147. package/lib/services.lazy/ccls.js +1 -0
  148. package/lib/services.lazy/channel_points.js +1 -0
  149. package/lib/services.lazy/channels.js +1 -0
  150. package/lib/services.lazy/charity.js +1 -0
  151. package/lib/services.lazy/chat.js +3 -0
  152. package/lib/services.lazy/clips.js +1 -0
  153. package/lib/services.lazy/conduits.js +1 -0
  154. package/lib/services.lazy/entitlements.js +1 -0
  155. package/lib/services.lazy/eventsub.js +1 -0
  156. package/lib/services.lazy/extensions.js +1 -0
  157. package/lib/services.lazy/games.js +1 -0
  158. package/lib/services.lazy/goals.js +1 -0
  159. package/lib/services.lazy/guest_star.js +1 -0
  160. package/lib/services.lazy/hype_train.js +1 -0
  161. package/lib/services.lazy/index.js +3 -0
  162. package/lib/services.lazy/moderation.js +3 -0
  163. package/lib/services.lazy/polls.js +1 -0
  164. package/lib/services.lazy/predictions.js +1 -0
  165. package/lib/services.lazy/raids.js +1 -0
  166. package/lib/services.lazy/schedule.js +1 -0
  167. package/lib/services.lazy/search.js +1 -0
  168. package/lib/services.lazy/streams.js +1 -0
  169. package/lib/services.lazy/subscriptions.js +1 -0
  170. package/lib/services.lazy/teams.js +1 -0
  171. package/lib/services.lazy/users.js +1 -0
  172. package/lib/services.lazy/videos.js +1 -0
  173. package/lib/services.lazy/whispers.js +1 -0
  174. package/lib/traits.d.ts +10 -0
  175. package/lib/traits.d.ts.map +1 -0
  176. package/lib/traits.js +1 -0
  177. package/package.json +82 -2
  178. package/src/credentials.ts +79 -0
  179. package/src/errors.ts +78 -0
  180. package/src/index.ts +45 -0
  181. package/src/pagination.ts +9 -0
  182. package/src/protocol.ts +43 -0
  183. package/src/retry.ts +69 -0
  184. package/src/services/ads.ts +228 -0
  185. package/src/services/analytics.ts +253 -0
  186. package/src/services/bits.ts +631 -0
  187. package/src/services/ccls.ts +96 -0
  188. package/src/services/channel_points.ts +804 -0
  189. package/src/services/channels.ts +471 -0
  190. package/src/services/charity.ts +250 -0
  191. package/src/services/chat.ts +1547 -0
  192. package/src/services/clips.ts +385 -0
  193. package/src/services/conduits.ts +453 -0
  194. package/src/services/entitlements.ts +219 -0
  195. package/src/services/eventsub.ts +372 -0
  196. package/src/services/extensions.ts +1098 -0
  197. package/src/services/games.ts +184 -0
  198. package/src/services/goals.ts +110 -0
  199. package/src/services/guest_star.ts +762 -0
  200. package/src/services/hype_train.ts +214 -0
  201. package/src/services/index.ts +30 -0
  202. package/src/services/moderation.ts +1817 -0
  203. package/src/services/polls.ts +363 -0
  204. package/src/services/predictions.ts +432 -0
  205. package/src/services/raids.ts +127 -0
  206. package/src/services/schedule.ts +539 -0
  207. package/src/services/search.ts +248 -0
  208. package/src/services/streams.ts +579 -0
  209. package/src/services/subscriptions.ts +247 -0
  210. package/src/services/teams.ts +225 -0
  211. package/src/services/users.ts +729 -0
  212. package/src/services/videos.ts +257 -0
  213. package/src/services/whispers.ts +71 -0
  214. package/src/traits.ts +47 -0
@@ -0,0 +1,1817 @@
1
+ import * as API from "@distilled.cloud/core/api";
2
+ // AUTO-GENERATED by scripts/generate.ts from .generated-specs (specs/spec-mirror-twitch/specs/api/reference). Do not edit.
3
+ import * as S from "@distilled.cloud/core/schema-lite";
4
+ import * as __L from "@distilled.cloud/core/schema-lite";
5
+ import { TwitchServiceErrors } from "../errors.ts";
6
+ import { paginateCursor } from "../pagination.ts";
7
+ import { TwitchProtocol, type TwitchOpError, type TwitchOpContext } from "../protocol.ts";
8
+ import * as Retry from "../retry.ts";
9
+ import * as T from "../traits.ts";
10
+ // Schema table, filled on first reach (see __S at the end).
11
+ const __s: any[] = [];
12
+
13
+ export type { TwitchOpError, TwitchOpContext };
14
+
15
+ /** Span facts shared by every operation (com.distilled.telemetry#service). */
16
+ const TELEMETRY = {
17
+ system: "twitch-api",
18
+ responseHeaders: [
19
+ { header: "x-request-id", name: "http.response.header.x-request-id", transform: "list" },
20
+ { header: "request-id", name: "http.response.header.request-id", transform: "list" },
21
+ ],
22
+ prefix: "Twitch",
23
+ service: "Moderation",
24
+ propagate: "w3c",
25
+ } as const;
26
+
27
+ export interface AddBlockedTermRequest {
28
+ /** The ID of the broadcaster that owns the list of blocked terms. */
29
+ broadcaster_id: string;
30
+ /** The ID of the broadcaster or a user that has permission to moderate the broadcaster's chat room. This ID must match the user ID in the user access token. */
31
+ moderator_id: string;
32
+ /** The word or phrase to block from being used in the broadcaster's chat room. The term may contain up to a maximum of 500 characters. Not counting spaces and wildcard characters, the term must contain a minimum of 2 characters, or 3 characters if it includes a wildcard character. Terms may include a wildcard character (*). The wildcard character must appear at the beginning or end of a word or set of characters. For example, *foo or foo*. If the blocked term already exists, the response contains the existing blocked term. */
33
+ text: string;
34
+ }
35
+ export interface AddBlockedTermResponseDataItem {
36
+ /** The broadcaster that owns the list of blocked terms. */
37
+ broadcaster_id?: string | undefined;
38
+ /** The moderator that blocked the word or phrase from being used in the broadcaster's chat room. */
39
+ moderator_id?: string | undefined;
40
+ /** An ID that identifies this blocked term. */
41
+ id?: string | undefined;
42
+ /** The blocked word or phrase. */
43
+ text?: string | undefined;
44
+ /** The UTC date and time (in RFC3339 format) that the term was blocked. */
45
+ created_at?: string | undefined;
46
+ /** The UTC date and time (in RFC3339 format) that the term was updated. When the term is added, this timestamp is the same as `created_at`. The timestamp changes as AutoMod continues to deny the term. */
47
+ updated_at?: string | undefined;
48
+ /** The UTC date and time (in RFC3339 format) that the blocked term is set to expire. After the block expires, users may use the term in the broadcaster's chat room. This field is **null** if the term was added manually or was permanently blocked by AutoMod. */
49
+ expires_at?: string | undefined;
50
+ }
51
+ /** A list that contains the single blocked term that the broadcaster added. */
52
+ export type AddBlockedTermResponseDataList = Array<AddBlockedTermResponseDataItem>;
53
+ export interface AddBlockedTermResponse {
54
+ /** A list that contains the single blocked term that the broadcaster added. */
55
+ data?: AddBlockedTermResponseDataList | undefined;
56
+ }
57
+ export interface AddChannelModeratorRequest {
58
+ /** The ID of the broadcaster that owns the chat room. This ID must match the user ID in the access token. */
59
+ broadcaster_id: string;
60
+ /** The ID of the user to add as a moderator in the broadcaster's chat room. */
61
+ user_id: string;
62
+ }
63
+ export interface AddChannelModeratorResponse {}
64
+ export interface AddChannelVipRequest {
65
+ /** The ID of the user to give VIP status to. */
66
+ user_id: string;
67
+ /** The ID of the broadcaster that's adding the user as a VIP. This ID must match the user ID in the access token. */
68
+ broadcaster_id: string;
69
+ }
70
+ export interface AddChannelVipResponse {}
71
+ export interface AddSuspiciousStatusToChatUserRequest {
72
+ /** The user ID of the broadcaster, indicating the channel where the status is being applied. */
73
+ broadcaster_id: string;
74
+ /** The user ID of the moderator who is applying the status. This ID must match the user ID in the user access token. */
75
+ moderator_id: string;
76
+ /** The ID of the user being given the suspicious status. */
77
+ user_id: string;
78
+ /** The type of suspicious status. Possible values: - `ACTIVE_MONITORING` - `RESTRICTED` */
79
+ status: string;
80
+ }
81
+ /** An array of strings representing the type(s) of suspicious user this is. Possible values: - `MANUALLY_ADDED` - `DETECTED_BAN_EVADER` - `DETECTED_SUS_CHATTER` - `BANNED_IN_SHARED_CHANNEL` - `UNKNOWN_TYPE` */
82
+ export type AddSuspiciousStatusToChatUserResponseDataItemTypesList = Array<string>;
83
+ export interface AddSuspiciousStatusToChatUserResponseDataItem {
84
+ /** The ID of the user being given the suspicious status. */
85
+ user_id?: string | undefined;
86
+ /** The user ID of the broadcaster indicating in which channel the status is being applied. */
87
+ broadcaster_id?: string | undefined;
88
+ /** The user ID of the moderator who applied the last status. */
89
+ moderator_id?: string | undefined;
90
+ /** The UTC date and time (in RFC3339 format) of the last time this user's status was updated. */
91
+ updated_at?: string | undefined;
92
+ /** The type of suspicious status. Possible values: - `ACTIVE_MONITORING` - `RESTRICTED` */
93
+ status?: string | undefined;
94
+ /** An array of strings representing the type(s) of suspicious user this is. Possible values: - `MANUALLY_ADDED` - `DETECTED_BAN_EVADER` - `DETECTED_SUS_CHATTER` - `BANNED_IN_SHARED_CHANNEL` - `UNKNOWN_TYPE` */
95
+ types?: AddSuspiciousStatusToChatUserResponseDataItemTypesList | undefined;
96
+ }
97
+ /** An array with one object containing information about the suspicious user action. */
98
+ export type AddSuspiciousStatusToChatUserResponseDataList =
99
+ Array<AddSuspiciousStatusToChatUserResponseDataItem>;
100
+ export interface AddSuspiciousStatusToChatUserResponse {
101
+ /** An array with one object containing information about the suspicious user action. */
102
+ data?: AddSuspiciousStatusToChatUserResponseDataList | undefined;
103
+ }
104
+ /** Identifies the user and type of ban. */
105
+ export interface BanUserRequestData {
106
+ /** The ID of the user to ban or put in a timeout. */
107
+ user_id: string;
108
+ /** To ban a user indefinitely, don't include this field or set it to 0. To put a user in a timeout, include this field and specify the timeout period, in seconds. The minimum timeout is 1 second and the maximum is 1,209,600 seconds (2 weeks). To end a user's timeout early, set this field to 1, or use the [Unban user](#unban-user) endpoint. */
109
+ duration?: number | undefined;
110
+ /** The reason the you're banning the user or putting them in a timeout. The text is user defined and is limited to a maximum of 500 characters. */
111
+ reason?: string | undefined;
112
+ }
113
+ export interface BanUserRequest {
114
+ /** The ID of the broadcaster whose chat room the user is being banned from. */
115
+ broadcaster_id: string;
116
+ /** The ID of the broadcaster or a user that has permission to moderate the broadcaster's chat room. This ID must match the user ID in the user access token. */
117
+ moderator_id: string;
118
+ /** Identifies the user and type of ban. */
119
+ data: BanUserRequestData;
120
+ }
121
+ export interface BanUserResponseDataItem {
122
+ /** The broadcaster whose chat room the user was banned from chatting in. */
123
+ broadcaster_id?: string | undefined;
124
+ /** The moderator that banned or put the user in the timeout. */
125
+ moderator_id?: string | undefined;
126
+ /** The user that was banned or put in a timeout. */
127
+ user_id?: string | undefined;
128
+ /** The UTC date and time (in RFC3339 format) that the ban or timeout was placed. */
129
+ created_at?: string | undefined;
130
+ /** The UTC date and time (in RFC3339 format) that the timeout will end. Is **null** if the user was banned instead of being put in a timeout. */
131
+ end_time?: string | undefined;
132
+ }
133
+ /** A list that contains the user you successfully banned or put in a timeout. */
134
+ export type BanUserResponseDataList = Array<BanUserResponseDataItem>;
135
+ export interface BanUserResponse {
136
+ /** A list that contains the user you successfully banned or put in a timeout. */
137
+ data?: BanUserResponseDataList | undefined;
138
+ }
139
+ export interface CheckAutomodStatusRequestDataItem {
140
+ /** A caller-defined ID used to correlate this message with the same message in the response. Use a unique ID for each message; if messages share an ID, only the last of them is checked. */
141
+ msg_id: string;
142
+ /** The message to check. The message may contain a maximum of 500 characters. */
143
+ msg_text: string;
144
+ }
145
+ /** The list of messages to check. The list must contain at least one message and may contain up to a maximum of 100 messages. */
146
+ export type CheckAutomodStatusRequestDataList = Array<CheckAutomodStatusRequestDataItem>;
147
+ export interface CheckAutomodStatusRequest {
148
+ /** The ID of the broadcaster whose AutoMod settings and list of blocked terms are used to check the message. This ID must match the user ID in the access token. */
149
+ broadcaster_id: string;
150
+ /** The list of messages to check. The list must contain at least one message and may contain up to a maximum of 100 messages. */
151
+ data: CheckAutomodStatusRequestDataList;
152
+ }
153
+ export interface CheckAutomodStatusResponseDataItem {
154
+ /** The caller-defined ID passed in the request. */
155
+ msg_id?: string | undefined;
156
+ /** A Boolean value that indicates whether Twitch would approve the message for chat or hold it for moderator review or block it from chat. Is **true** if Twitch would approve the message; otherwise, **false** if Twitch would hold the message for moderator review or block it from chat. */
157
+ is_permitted?: boolean | undefined;
158
+ }
159
+ /** The list of messages and whether Twitch would approve them for chat. The list is in no particular order. */
160
+ export type CheckAutomodStatusResponseDataList = Array<CheckAutomodStatusResponseDataItem>;
161
+ export interface CheckAutomodStatusResponse {
162
+ /** The list of messages and whether Twitch would approve them for chat. The list is in no particular order. */
163
+ data?: CheckAutomodStatusResponseDataList | undefined;
164
+ }
165
+ export interface DeleteChatMessagesRequest {
166
+ /** The ID of the broadcaster that owns the chat room to remove messages from. */
167
+ broadcaster_id: string;
168
+ /** The ID of the broadcaster or a user that has permission to moderate the broadcaster's chat room. This ID must match the user ID in the user access token. */
169
+ moderator_id: string;
170
+ /** The ID of the message to remove. The `id` tag in the [PRIVMSG](https://dev.twitch.tv/docs/chat/irc.md#privmsg-tags) tag contains the message's ID. Restrictions: - The message must have been created within the last 6 hours. - The message must not belong to the broadcaster. - The message must not belong to another moderator. If you don't specify this parameter, the request removes all messages in the broadcaster's chat room. */
171
+ message_id?: string | undefined;
172
+ }
173
+ export interface DeleteChatMessagesResponse {}
174
+ export interface GetAutomodSettingsRequest {
175
+ /** The ID of the broadcaster whose AutoMod settings you want to get. */
176
+ broadcaster_id: string;
177
+ /** The ID of the broadcaster or a user that has permission to moderate the broadcaster's chat room. This ID must match the user ID in the user access token. */
178
+ moderator_id: string;
179
+ }
180
+ export interface GetAutomodSettingsResponseDataItem {
181
+ /** The broadcaster's ID. */
182
+ broadcaster_id?: string | undefined;
183
+ /** The moderator's ID. */
184
+ moderator_id?: string | undefined;
185
+ /** The default AutoMod level for the broadcaster. This field is **null** if the individual settings don't match one of the default levels, such as when the broadcaster has set one or more of the individual settings. It's also **null**, and every individual setting is 0, if the broadcaster hasn't configured AutoMod. */
186
+ overall_level?: number | null | undefined;
187
+ /** The Automod level for discrimination against disability. */
188
+ disability?: number | undefined;
189
+ /** The Automod level for hostility involving aggression. */
190
+ aggression?: number | undefined;
191
+ /** The AutoMod level for discrimination based on sexuality, sex, or gender. */
192
+ sexuality_sex_or_gender?: number | undefined;
193
+ /** The Automod level for discrimination against women. */
194
+ misogyny?: number | undefined;
195
+ /** The Automod level for hostility involving name calling or insults. */
196
+ bullying?: number | undefined;
197
+ /** The Automod level for profanity. */
198
+ swearing?: number | undefined;
199
+ /** The Automod level for racial discrimination. */
200
+ race_ethnicity_or_religion?: number | undefined;
201
+ /** The Automod level for sexual content. */
202
+ sex_based_terms?: number | undefined;
203
+ }
204
+ /** The list of AutoMod settings. The list contains a single object that contains all the AutoMod settings. */
205
+ export type GetAutomodSettingsResponseDataList = Array<GetAutomodSettingsResponseDataItem>;
206
+ export interface GetAutomodSettingsResponse {
207
+ /** The list of AutoMod settings. The list contains a single object that contains all the AutoMod settings. */
208
+ data?: GetAutomodSettingsResponseDataList | undefined;
209
+ }
210
+ export type GetBannedUsersRequestUserIdList = Array<string>;
211
+ export interface GetBannedUsersRequest {
212
+ /** The ID of the broadcaster whose list of banned users you want to get. This ID must match the user ID in the access token. */
213
+ broadcaster_id: string;
214
+ /** A list of user IDs used to filter the results. To specify more than one ID, include this parameter for each user you want to get. For example, 'user_id=1234&user_id=5678'. You may specify a maximum of 100 IDs. The returned list includes only those users that were banned or put in a timeout. If you specify this parameter, the *first* and *after* query parameters are ignored and the response's `pagination` object is empty. */
215
+ user_id?: GetBannedUsersRequestUserIdList | undefined;
216
+ /** The maximum number of items to return per page in the response. The minimum page size is 1 item per page and the maximum is 100 items per page. The default is 20. */
217
+ first?: number | undefined;
218
+ /** The cursor used to get the next page of results. The **Pagination** object in the response contains the cursor's value. [Read More](https://dev.twitch.tv/docs/api/guide.md#pagination) */
219
+ after?: string | undefined;
220
+ }
221
+ export interface GetBannedUsersResponseDataItem {
222
+ /** The ID of the banned user. */
223
+ user_id?: string | undefined;
224
+ /** The banned user's login name. */
225
+ user_login?: string | undefined;
226
+ /** The banned user's display name. */
227
+ user_name?: string | undefined;
228
+ /** The UTC date and time (in RFC3339 format) of when the timeout expires, or an empty string if the user is permanently banned. */
229
+ expires_at?: string | undefined;
230
+ /** The UTC date and time (in RFC3339 format) of when the user was banned. */
231
+ created_at?: string | undefined;
232
+ /** The reason the user was banned or put in a timeout if the moderator provided one. */
233
+ reason?: string | undefined;
234
+ /** The ID of the moderator that banned the user or put them in a timeout. */
235
+ moderator_id?: string | undefined;
236
+ /** The moderator's login name. */
237
+ moderator_login?: string | undefined;
238
+ /** The moderator's display name. */
239
+ moderator_name?: string | undefined;
240
+ }
241
+ /** The list of users that were banned or put in a timeout. The users in each page are in lexicographical order of user ID. */
242
+ export type GetBannedUsersResponseDataList = Array<GetBannedUsersResponseDataItem>;
243
+ /** Contains the information used to page through the list of results. The object is empty if there are no more pages left to page through. [Read More](https://dev.twitch.tv/docs/api/guide.md#pagination) */
244
+ export interface GetBannedUsersResponsePagination {
245
+ /** The cursor used to get the next page of results. Use the cursor to set the request's *after* query parameter. */
246
+ cursor?: string | undefined;
247
+ }
248
+ export interface GetBannedUsersResponse {
249
+ /** The list of users that were banned or put in a timeout. The users in each page are in lexicographical order of user ID. */
250
+ data: GetBannedUsersResponseDataList;
251
+ /** Contains the information used to page through the list of results. The object is empty if there are no more pages left to page through. [Read More](https://dev.twitch.tv/docs/api/guide.md#pagination) */
252
+ pagination?: GetBannedUsersResponsePagination | undefined;
253
+ }
254
+ export interface GetBlockedTermsRequest {
255
+ /** The ID of the broadcaster whose blocked terms you're getting. */
256
+ broadcaster_id: string;
257
+ /** The ID of the broadcaster or a user that has permission to moderate the broadcaster's chat room. This ID must match the user ID in the user access token. */
258
+ moderator_id: string;
259
+ /** The maximum number of items to return per page in the response. The minimum page size is 1 item per page and the maximum is 100 items per page. The default is 20. */
260
+ first?: number | undefined;
261
+ /** The cursor used to get the next page of results. The **Pagination** object in the response contains the cursor's value. */
262
+ after?: string | undefined;
263
+ }
264
+ export type GetBlockedTermsResponseDataItem = AddBlockedTermResponseDataItem;
265
+ /** The list of blocked terms. The list is in descending order of when they were created (see the `created_at` timestamp). */
266
+ export type GetBlockedTermsResponseDataList = Array<AddBlockedTermResponseDataItem>;
267
+ /** Contains the information used to page through the list of results. The object is empty if the page contains fewer terms than the page size (see *first*). A full page includes a cursor even if no more terms remain, in which case the next page is empty. [Read More](https://dev.twitch.tv/docs/api/guide.md#pagination) */
268
+ export type GetBlockedTermsResponsePagination = GetBannedUsersResponsePagination;
269
+ export interface GetBlockedTermsResponse {
270
+ /** The list of blocked terms. The list is in descending order of when they were created (see the `created_at` timestamp). */
271
+ data: GetBlockedTermsResponseDataList;
272
+ /** Contains the information used to page through the list of results. The object is empty if the page contains fewer terms than the page size (see *first*). A full page includes a cursor even if no more terms remain, in which case the next page is empty. [Read More](https://dev.twitch.tv/docs/api/guide.md#pagination) */
273
+ pagination?: GetBannedUsersResponsePagination | undefined;
274
+ }
275
+ export interface GetModeratedChannelsRequest {
276
+ /** A user's ID. Returns the list of channels that this user has moderator privileges in. This ID must match the user ID in the user OAuth token */
277
+ user_id: string;
278
+ /** The cursor used to get the next page of results. The Pagination object in the response contains the cursor's value. */
279
+ after?: string | undefined;
280
+ /** The maximum number of items to return per page in the response. Minimum page size is 1 item per page and the maximum is 100. The default is 20. */
281
+ first?: number | undefined;
282
+ }
283
+ export interface GetModeratedChannelsResponseDataItem {
284
+ /** An ID that uniquely identifies the channel this user can moderate. */
285
+ broadcaster_id?: string | undefined;
286
+ /** The channel's login name. */
287
+ broadcaster_login?: string | undefined;
288
+ /** The channels' display name. */
289
+ broadcaster_name?: string | undefined;
290
+ }
291
+ /** The list of channels that the user has moderator privileges in. The list doesn't include the user's own channel or channels that are deleted or suspended. */
292
+ export type GetModeratedChannelsResponseDataList = Array<GetModeratedChannelsResponseDataItem>;
293
+ /** Contains the information used to page through the list of results. The object is empty if there are no more pages left to page through. */
294
+ export interface GetModeratedChannelsResponsePagination {
295
+ /** The cursor used to get the next page of results. Use the cursor to set the request's after query parameter. */
296
+ cursor?: string | undefined;
297
+ }
298
+ export interface GetModeratedChannelsResponse {
299
+ /** The list of channels that the user has moderator privileges in. The list doesn't include the user's own channel or channels that are deleted or suspended. */
300
+ data: GetModeratedChannelsResponseDataList;
301
+ /** Contains the information used to page through the list of results. The object is empty if there are no more pages left to page through. */
302
+ pagination?: GetModeratedChannelsResponsePagination | undefined;
303
+ }
304
+ export type GetModeratorsRequestUserIdList = Array<string>;
305
+ export interface GetModeratorsRequest {
306
+ /** The ID of the broadcaster whose list of moderators you want to get. This ID must match the user ID in the access token. */
307
+ broadcaster_id: string;
308
+ /** A list of user IDs used to filter the results. To specify more than one ID, include this parameter for each moderator you want to get. For example, 'user_id=1234&user_id=5678'. You may specify a maximum of 100 IDs. The returned list includes only the users from the list who are moderators in the broadcaster's channel. The list is in no particular order, and duplicate IDs are ignored. If you specify this parameter, the *first* and *after* query parameters are ignored and the response's `pagination` object is empty. */
309
+ user_id?: GetModeratorsRequestUserIdList | undefined;
310
+ /** The maximum number of items to return per page in the response. The minimum page size is 1 item per page and the maximum is 100 items per page. The default is 20. */
311
+ first?: number | undefined;
312
+ /** The cursor used to get the next page of results. The **Pagination** object in the response contains the cursor's value. [Read More](https://dev.twitch.tv/docs/api/guide.md#pagination) */
313
+ after?: string | undefined;
314
+ }
315
+ export interface GetModeratorsResponseDataItem {
316
+ /** The ID of the user that has permission to moderate the broadcaster's channel. */
317
+ user_id?: string | undefined;
318
+ /** The user's login name. */
319
+ user_login?: string | undefined;
320
+ /** The user's display name. */
321
+ user_name?: string | undefined;
322
+ }
323
+ /** The list of moderators. */
324
+ export type GetModeratorsResponseDataList = Array<GetModeratorsResponseDataItem>;
325
+ /** Contains the information used to page through the list of results. The object is empty if there are no more pages left to page through. [Read More](https://dev.twitch.tv/docs/api/guide.md#pagination) */
326
+ export type GetModeratorsResponsePagination = GetBannedUsersResponsePagination;
327
+ export interface GetModeratorsResponse {
328
+ /** The list of moderators. */
329
+ data: GetModeratorsResponseDataList;
330
+ /** Contains the information used to page through the list of results. The object is empty if there are no more pages left to page through. [Read More](https://dev.twitch.tv/docs/api/guide.md#pagination) */
331
+ pagination?: GetBannedUsersResponsePagination | undefined;
332
+ }
333
+ export interface GetShieldModeStatusRequest {
334
+ /** The ID of the broadcaster whose Shield Mode activation status you want to get. */
335
+ broadcaster_id: string;
336
+ /** The ID of the broadcaster or a user that is one of the broadcaster's moderators. This ID must match the user ID in the access token. */
337
+ moderator_id: string;
338
+ }
339
+ export interface GetShieldModeStatusResponseDataItem {
340
+ /** A Boolean value that determines whether Shield Mode is active. Is **true** if the broadcaster activated Shield Mode; otherwise, **false**. */
341
+ is_active?: boolean | undefined;
342
+ /** An ID that identifies the moderator that last activated Shield Mode. Is an empty string if Shield Mode hasn't been previously activated. */
343
+ moderator_id?: string | undefined;
344
+ /** The moderator's login name. Is an empty string if Shield Mode hasn't been previously activated. */
345
+ moderator_login?: string | undefined;
346
+ /** The moderator's display name. Is an empty string if Shield Mode hasn't been previously activated. */
347
+ moderator_name?: string | undefined;
348
+ /** The UTC timestamp (in RFC3339 format) of when Shield Mode was last activated. Is an empty string if Shield Mode hasn't been previously activated. */
349
+ last_activated_at?: string | undefined;
350
+ }
351
+ /** A list that contains a single object with the broadcaster's Shield Mode status. */
352
+ export type GetShieldModeStatusResponseDataList = Array<GetShieldModeStatusResponseDataItem>;
353
+ export interface GetShieldModeStatusResponse {
354
+ /** A list that contains a single object with the broadcaster's Shield Mode status. */
355
+ data?: GetShieldModeStatusResponseDataList | undefined;
356
+ }
357
+ export interface GetUnbanRequestsRequest {
358
+ /** The ID of the broadcaster whose channel is receiving unban requests. */
359
+ broadcaster_id: string;
360
+ /** The ID of the broadcaster or a user that has permission to moderate the broadcaster's unban requests. This ID must match the user ID in the user access token. To get your own unban requests, set this parameter and *user_id* to your user ID; the *moderator_id*, `moderator_login` and `moderator_name` fields in the response are then **null**. */
361
+ moderator_id: string;
362
+ /** Filter by a status. The value is case sensitive. - pending - approved - denied - acknowledged - canceled */
363
+ status: string;
364
+ /** The ID used to filter what unban requests are returned. */
365
+ user_id?: string | undefined;
366
+ /** Cursor used to get next page of results. Pagination object in response contains cursor value. */
367
+ after?: string | undefined;
368
+ /** The maximum number of items to return per page in the response. The minimum page size is 1 item per page and the maximum is 100. The default is 20. */
369
+ first?: number | undefined;
370
+ }
371
+ export interface GetUnbanRequestsResponseDataItem {
372
+ /** Unban request ID. */
373
+ id?: string | undefined;
374
+ /** User ID of broadcaster whose channel is receiving the unban request. */
375
+ broadcaster_id?: string | undefined;
376
+ /** The broadcaster's login name. */
377
+ broadcaster_login?: string | undefined;
378
+ /** The broadcaster's display name. */
379
+ broadcaster_name?: string | undefined;
380
+ /** User ID of moderator who approved/denied the request. If the request was canceled, this is the requesting user's ID. */
381
+ moderator_id?: string | null | undefined;
382
+ /** The moderator's login name. */
383
+ moderator_login?: string | null | undefined;
384
+ /** The moderator's display name. */
385
+ moderator_name?: string | null | undefined;
386
+ /** User ID of the requestor who is asking for an unban. */
387
+ user_id?: string | undefined;
388
+ /** The user's login name. */
389
+ user_login?: string | undefined;
390
+ /** The user's display name. */
391
+ user_name?: string | undefined;
392
+ /** Text of the request from the requesting user. */
393
+ text?: string | undefined;
394
+ /** Status of the request. One of: - pending - approved - denied - acknowledged - canceled */
395
+ status?: string | undefined;
396
+ /** Timestamp of when the unban request was created. */
397
+ created_at?: string | undefined;
398
+ /** Timestamp of when moderator/broadcaster approved or denied the request. */
399
+ resolved_at?: string | null | undefined;
400
+ /** Text input by the resolver (moderator) of the unban request */
401
+ resolution_text?: string | null | undefined;
402
+ }
403
+ /** A list that contains information about the channel's unban requests. The list is empty if the user in *moderator_id* doesn't have permission to view the broadcaster's unban requests. Requests from users whose accounts are deleted or suspended aren't included, so a page may contain fewer than *first* items. */
404
+ export type GetUnbanRequestsResponseDataList = Array<GetUnbanRequestsResponseDataItem>;
405
+ /** Contains information used to page through a list of results. The object is empty if there are no more pages left to page through. */
406
+ export type GetUnbanRequestsResponsePagination = GetModeratedChannelsResponsePagination;
407
+ export interface GetUnbanRequestsResponse {
408
+ /** A list that contains information about the channel's unban requests. The list is empty if the user in *moderator_id* doesn't have permission to view the broadcaster's unban requests. Requests from users whose accounts are deleted or suspended aren't included, so a page may contain fewer than *first* items. */
409
+ data: GetUnbanRequestsResponseDataList;
410
+ /** Contains information used to page through a list of results. The object is empty if there are no more pages left to page through. */
411
+ pagination?: GetModeratedChannelsResponsePagination | undefined;
412
+ }
413
+ export type GetVipsRequestUserIdList = Array<string>;
414
+ export interface GetVipsRequest {
415
+ /** Filters the list for specific VIPs. To specify more than one user, include the *user_id* parameter for each user to get. For example, '&user_id=1234&user_id=5678'. The maximum number of IDs that you may specify is 100. Ignores the ID of those users in the list that aren't VIPs. */
416
+ user_id?: GetVipsRequestUserIdList | undefined;
417
+ /** The ID of the broadcaster whose list of VIPs you want to get. This ID must match the user ID in the access token. */
418
+ broadcaster_id: string;
419
+ /** The maximum number of items to return per page in the response. The minimum page size is 1 item per page and the maximum is 100. The default is 20. Ignored if you specify *user_id*. */
420
+ first?: number | undefined;
421
+ /** The cursor used to get the next page of results. The **Pagination** object in the response contains the cursor's value. Ignored if you specify *user_id*. [Read More](https://dev.twitch.tv/docs/api/guide.md#pagination) */
422
+ after?: string | undefined;
423
+ }
424
+ export interface GetVipsResponseDataItem {
425
+ /** An ID that uniquely identifies the VIP user. */
426
+ user_id?: string | undefined;
427
+ /** The user's display name. */
428
+ user_name?: string | undefined;
429
+ /** The user's login name. */
430
+ user_login?: string | undefined;
431
+ }
432
+ /** The list of VIPs. The list is empty if the broadcaster doesn't have VIP users. */
433
+ export type GetVipsResponseDataList = Array<GetVipsResponseDataItem>;
434
+ /** Contains the information used to page through the list of results. The object is empty if the page contains no VIPs or you specified *user_id*. The last page of VIPs still contains a cursor; using it returns an empty page. [Read More](https://dev.twitch.tv/docs/api/guide.md#pagination) */
435
+ export type GetVipsResponsePagination = GetBannedUsersResponsePagination;
436
+ export interface GetVipsResponse {
437
+ /** The list of VIPs. The list is empty if the broadcaster doesn't have VIP users. */
438
+ data: GetVipsResponseDataList;
439
+ /** Contains the information used to page through the list of results. The object is empty if the page contains no VIPs or you specified *user_id*. The last page of VIPs still contains a cursor; using it returns an empty page. [Read More](https://dev.twitch.tv/docs/api/guide.md#pagination) */
440
+ pagination?: GetBannedUsersResponsePagination | undefined;
441
+ }
442
+ export interface ManageHeldAutomodMessagesRequest {
443
+ /** The moderator who is approving or denying the held message. This ID must match the user ID in the access token. */
444
+ user_id: string;
445
+ /** The ID of the message to allow or deny. */
446
+ msg_id: string;
447
+ /** The action to take for the message. The value is case insensitive. Possible values: - `ALLOW` - `DENY` */
448
+ action: string;
449
+ }
450
+ export interface ManageHeldAutomodMessagesResponse {}
451
+ export interface RemoveBlockedTermRequest {
452
+ /** The ID of the broadcaster that owns the list of blocked terms. */
453
+ broadcaster_id: string;
454
+ /** The ID of the broadcaster or a user that has permission to moderate the broadcaster's chat room. This ID must match the user ID in the user access token. */
455
+ moderator_id: string;
456
+ /** The ID of the blocked term to remove from the broadcaster's list of blocked terms. */
457
+ id: string;
458
+ }
459
+ export interface RemoveBlockedTermResponse {}
460
+ export interface RemoveChannelModeratorRequest {
461
+ /** The ID of the broadcaster that owns the chat room. This ID must match the user ID in the access token, unless a moderator is removing themselves; in that case, the ID in *user_id* must match the user ID in the access token. */
462
+ broadcaster_id: string;
463
+ /** The ID of the user to remove as a moderator from the broadcaster's chat room. */
464
+ user_id: string;
465
+ }
466
+ export interface RemoveChannelModeratorResponse {}
467
+ export interface RemoveChannelVipRequest {
468
+ /** The ID of the user to remove VIP status from. */
469
+ user_id: string;
470
+ /** The ID of the broadcaster who owns the channel where the user has VIP status. */
471
+ broadcaster_id: string;
472
+ }
473
+ export interface RemoveChannelVipResponse {}
474
+ export interface RemoveSuspiciousStatusFromChatUserRequest {
475
+ /** The user ID of the broadcaster, indicating the channel where the status is being removed. */
476
+ broadcaster_id: string;
477
+ /** The user ID of the moderator who is removing the status. This ID must match the user ID in the user access token. */
478
+ moderator_id: string;
479
+ /** The ID of the user having the suspicious status removed. */
480
+ user_id: string;
481
+ }
482
+ /** An array of strings representing the type(s) of suspicious user this is. Possible values: - `MANUALLY_ADDED` - `DETECTED_BAN_EVADER` - `DETECTED_SUS_CHATTER` - `BANNED_IN_SHARED_CHANNEL` - `UNKNOWN_TYPE` */
483
+ export type RemoveSuspiciousStatusFromChatUserResponseDataItemTypesList = Array<string>;
484
+ export interface RemoveSuspiciousStatusFromChatUserResponseDataItem {
485
+ /** The ID of the user having the suspicious status removed. */
486
+ user_id?: string | undefined;
487
+ /** The user ID of the broadcaster indicating in which channel the status is being removed. */
488
+ broadcaster_id?: string | undefined;
489
+ /** The user ID of the moderator who modified the last status. */
490
+ moderator_id?: string | undefined;
491
+ /** The timestamp of the last time this user's status was updated. */
492
+ updated_at?: string | undefined;
493
+ /** The type of suspicious status. Possible values: - `NO_TREATMENT` */
494
+ status?: string | undefined;
495
+ /** An array of strings representing the type(s) of suspicious user this is. Possible values: - `MANUALLY_ADDED` - `DETECTED_BAN_EVADER` - `DETECTED_SUS_CHATTER` - `BANNED_IN_SHARED_CHANNEL` - `UNKNOWN_TYPE` */
496
+ types?: RemoveSuspiciousStatusFromChatUserResponseDataItemTypesList | undefined;
497
+ }
498
+ /** An array with one object containing information about the suspicious user action. */
499
+ export type RemoveSuspiciousStatusFromChatUserResponseDataList =
500
+ Array<RemoveSuspiciousStatusFromChatUserResponseDataItem>;
501
+ export interface RemoveSuspiciousStatusFromChatUserResponse {
502
+ /** An array with one object containing information about the suspicious user action. */
503
+ data?: RemoveSuspiciousStatusFromChatUserResponseDataList | undefined;
504
+ }
505
+ export interface ResolveUnbanRequestsRequest {
506
+ /** The ID of the broadcaster whose channel is approving or denying the unban request. The request is identified by *unban_request_id* alone; the response's `broadcaster_id` echoes this ID, and `broadcaster_login` and `broadcaster_name` are empty strings if it isn't the request's broadcaster. */
507
+ broadcaster_id: string;
508
+ /** The ID of the broadcaster or a user that has permission to moderate the broadcaster's unban requests. This ID must match the user ID in the user access token. */
509
+ moderator_id: string;
510
+ /** The ID of the Unban Request to resolve. */
511
+ unban_request_id: string;
512
+ /** Resolution status. - approved - denied */
513
+ status: string;
514
+ /** Message supplied by the unban request resolver. The message is limited to a maximum of 500 characters. */
515
+ resolution_text?: string | undefined;
516
+ }
517
+ export interface ResolveUnbanRequestsResponseDataItem {
518
+ /** Unban request ID. */
519
+ id?: string | undefined;
520
+ /** User ID of broadcaster whose channel is receiving the unban request. */
521
+ broadcaster_id?: string | undefined;
522
+ /** The broadcaster's login name. */
523
+ broadcaster_login?: string | undefined;
524
+ /** The broadcaster's display name. */
525
+ broadcaster_name?: string | undefined;
526
+ /** User ID of moderator who approved/denied the request. */
527
+ moderator_id?: string | null | undefined;
528
+ /** The moderator's login name. */
529
+ moderator_login?: string | null | undefined;
530
+ /** The moderator's display name. */
531
+ moderator_name?: string | null | undefined;
532
+ /** User ID of the requestor who is asking for an unban. */
533
+ user_id?: string | undefined;
534
+ /** The user's login name. */
535
+ user_login?: string | undefined;
536
+ /** The user's display name. */
537
+ user_name?: string | undefined;
538
+ /** Text of the request from the requesting user. */
539
+ text?: string | undefined;
540
+ /** Status of the request. One of: - approved - denied - pending The status is **pending** if you approved the request but the user couldn't be unbanned. The request stays pending, and the `moderator_id`, `moderator_login`, `moderator_name`, `resolved_at` and `resolution_text` fields are **null**. */
541
+ status?: string | undefined;
542
+ /** Timestamp of when the unban request was created. */
543
+ created_at?: string | undefined;
544
+ /** Timestamp of when moderator/broadcaster approved or denied the request. */
545
+ resolved_at?: string | null | undefined;
546
+ /** Text input by the resolver (moderator) of the unban request. */
547
+ resolution_text?: string | null | undefined;
548
+ }
549
+ export type ResolveUnbanRequestsResponseDataList = Array<ResolveUnbanRequestsResponseDataItem>;
550
+ export interface ResolveUnbanRequestsResponse {
551
+ data?: ResolveUnbanRequestsResponseDataList | undefined;
552
+ }
553
+ export interface UnbanUserRequest {
554
+ /** The ID of the broadcaster whose chat room the user is banned from chatting in. */
555
+ broadcaster_id: string;
556
+ /** The ID of the broadcaster or a user that has permission to moderate the broadcaster's chat room. This ID must match the user ID in the user access token. */
557
+ moderator_id: string;
558
+ /** The ID of the user to remove the ban or timeout from. */
559
+ user_id: string;
560
+ }
561
+ export interface UnbanUserResponse {}
562
+ export interface UpdateAutomodSettingsRequest {
563
+ /** The ID of the broadcaster whose AutoMod settings you want to update. */
564
+ broadcaster_id: string;
565
+ /** The ID of the broadcaster or a user that has permission to moderate the broadcaster's chat room. This ID must match the user ID in the user access token. */
566
+ moderator_id: string;
567
+ /** The Automod level for hostility involving aggression. */
568
+ aggression?: number | undefined;
569
+ /** The Automod level for hostility involving name calling or insults. */
570
+ bullying?: number | undefined;
571
+ /** The Automod level for discrimination against disability. */
572
+ disability?: number | undefined;
573
+ /** The Automod level for discrimination against women. */
574
+ misogyny?: number | undefined;
575
+ /** The default AutoMod level for the broadcaster. */
576
+ overall_level?: number | undefined;
577
+ /** The Automod level for racial discrimination. */
578
+ race_ethnicity_or_religion?: number | undefined;
579
+ /** The Automod level for sexual content. */
580
+ sex_based_terms?: number | undefined;
581
+ /** The AutoMod level for discrimination based on sexuality, sex, or gender. */
582
+ sexuality_sex_or_gender?: number | undefined;
583
+ /** The Automod level for profanity. */
584
+ swearing?: number | undefined;
585
+ }
586
+ export interface UpdateAutomodSettingsResponseDataItem {
587
+ /** The broadcaster's ID. */
588
+ broadcaster_id?: string | undefined;
589
+ /** The moderator's ID. */
590
+ moderator_id?: string | undefined;
591
+ /** The default AutoMod level for the broadcaster. This field is **null** if the broadcaster has set one or more of the individual settings. */
592
+ overall_level?: number | null | undefined;
593
+ /** The Automod level for discrimination against disability. */
594
+ disability?: number | undefined;
595
+ /** The Automod level for hostility involving aggression. */
596
+ aggression?: number | undefined;
597
+ /** The AutoMod level for discrimination based on sexuality, sex, or gender. */
598
+ sexuality_sex_or_gender?: number | undefined;
599
+ /** The Automod level for discrimination against women. */
600
+ misogyny?: number | undefined;
601
+ /** The Automod level for hostility involving name calling or insults. */
602
+ bullying?: number | undefined;
603
+ /** The Automod level for profanity. */
604
+ swearing?: number | undefined;
605
+ /** The Automod level for racial discrimination. */
606
+ race_ethnicity_or_religion?: number | undefined;
607
+ /** The Automod level for sexual content. */
608
+ sex_based_terms?: number | undefined;
609
+ }
610
+ /** The list of AutoMod settings. The list contains a single object that contains all the AutoMod settings. */
611
+ export type UpdateAutomodSettingsResponseDataList = Array<UpdateAutomodSettingsResponseDataItem>;
612
+ export interface UpdateAutomodSettingsResponse {
613
+ /** The list of AutoMod settings. The list contains a single object that contains all the AutoMod settings. */
614
+ data?: UpdateAutomodSettingsResponseDataList | undefined;
615
+ }
616
+ export interface UpdateShieldModeStatusRequest {
617
+ /** The ID of the broadcaster whose Shield Mode you want to activate or deactivate. */
618
+ broadcaster_id: string;
619
+ /** The ID of the broadcaster or a user that is one of the broadcaster's moderators. This ID must match the user ID in the access token. */
620
+ moderator_id: string;
621
+ /** A Boolean value that determines whether to activate Shield Mode. Set to **true** to activate Shield Mode; otherwise, **false** to deactivate Shield Mode. */
622
+ is_active: boolean;
623
+ }
624
+ export interface UpdateShieldModeStatusResponseDataItem {
625
+ /** A Boolean value that determines whether Shield Mode is active. Is **true** if Shield Mode is active; otherwise, **false**. */
626
+ is_active?: boolean | undefined;
627
+ /** An ID that identifies the moderator that last activated Shield Mode. Is an empty string if Shield Mode hasn't been previously activated. */
628
+ moderator_id?: string | undefined;
629
+ /** The moderator's login name. Is an empty string if Shield Mode hasn't been previously activated. */
630
+ moderator_login?: string | undefined;
631
+ /** The moderator's display name. Is an empty string if Shield Mode hasn't been previously activated. */
632
+ moderator_name?: string | undefined;
633
+ /** The UTC timestamp (in RFC3339 format) of when Shield Mode was last activated. Is an empty string if Shield Mode hasn't been previously activated. */
634
+ last_activated_at?: string | undefined;
635
+ }
636
+ /** A list that contains a single object with the broadcaster's updated Shield Mode status. */
637
+ export type UpdateShieldModeStatusResponseDataList = Array<UpdateShieldModeStatusResponseDataItem>;
638
+ export interface UpdateShieldModeStatusResponse {
639
+ /** A list that contains a single object with the broadcaster's updated Shield Mode status. */
640
+ data?: UpdateShieldModeStatusResponseDataList | undefined;
641
+ }
642
+ /** An object that contains information about the warning. */
643
+ export interface WarnChatUserRequestData {
644
+ /** The ID of the twitch user to be warned. */
645
+ user_id: string;
646
+ /** A custom reason for the warning. **Max 500 chars.** */
647
+ reason: string;
648
+ }
649
+ export interface WarnChatUserRequest {
650
+ /** The ID of the channel in which the warning will take effect. */
651
+ broadcaster_id: string;
652
+ /** The ID of the twitch user who requested the warning. */
653
+ moderator_id: string;
654
+ /** An object that contains information about the warning. */
655
+ data: WarnChatUserRequestData;
656
+ }
657
+ export interface WarnChatUserResponseDataItem {
658
+ /** The ID of the channel in which the warning will take effect. */
659
+ broadcaster_id?: string | undefined;
660
+ /** The ID of the warned user. */
661
+ user_id?: string | undefined;
662
+ /** The ID of the user who applied the warning. */
663
+ moderator_id?: string | undefined;
664
+ /** The reason provided for warning. */
665
+ reason?: string | undefined;
666
+ }
667
+ /** A list that contains information about the warning. */
668
+ export type WarnChatUserResponseDataList = Array<WarnChatUserResponseDataItem>;
669
+ export interface WarnChatUserResponse {
670
+ /** A list that contains information about the warning. */
671
+ data?: WarnChatUserResponseDataList | undefined;
672
+ }
673
+ export type AddBlockedTermError = TwitchOpError;
674
+ /** Add Blocked Term Adds a word or phrase to the broadcaster's list of blocked terms. These are the terms that the broadcaster doesn't want used in their chat room. Authorization: Requires one of the following: - A [user access token](https://dev.twitch.tv/docs/authentication.md#user-access-tokens) that includes the **moderator:manage:blocked_terms** scope. - An [app access token](https://dev.twitch.tv/docs/authentication.md#app-access-tokens). The application, through prior authorization, must have been granted: - The **moderator:manage:blocked_terms** scope for the user represented by the *moderator_id* query parameter. Reference: https://dev.twitch.tv/docs/api/reference/moderation/#add-blocked-term */
675
+ export const addBlockedTerm: API.OperationMethod<
676
+ AddBlockedTermRequest,
677
+ AddBlockedTermResponse,
678
+ AddBlockedTermError,
679
+ TwitchOpContext
680
+ > = /*@__PURE__*/ API.make(() => ({
681
+ input: __S(0, __c0, 0) as any as S.Schema<AddBlockedTermRequest>,
682
+ output: __S(1, __c0, 1) as any as S.Schema<AddBlockedTermResponse>,
683
+ errors: [],
684
+ serviceErrors: TwitchServiceErrors,
685
+ protocol: TwitchProtocol,
686
+ retry: Retry.Retry,
687
+ telemetry: TELEMETRY,
688
+ span: "AddBlockedTerm",
689
+ }));
690
+
691
+ export type AddChannelModeratorError = TwitchOpError;
692
+ /** Add Channel Moderator Adds a moderator to the broadcaster's chat room. **Rate Limits**: The broadcaster may add a maximum of 10 moderators within a 10-second window. Authorization: Requires one of the following: - A [user access token](https://dev.twitch.tv/docs/authentication.md#user-access-tokens) that includes the **channel:manage:moderators** scope. Reference: https://dev.twitch.tv/docs/api/reference/moderation/#add-channel-moderator */
693
+ export const addChannelModerator: API.OperationMethod<
694
+ AddChannelModeratorRequest,
695
+ AddChannelModeratorResponse,
696
+ AddChannelModeratorError,
697
+ TwitchOpContext
698
+ > = /*@__PURE__*/ API.make(() => ({
699
+ input: __S(16, __c2, 0) as any as S.Schema<AddChannelModeratorRequest>,
700
+ output: __S(24, __c3, 0) as any as S.Schema<AddChannelModeratorResponse>,
701
+ errors: [],
702
+ serviceErrors: TwitchServiceErrors,
703
+ protocol: TwitchProtocol,
704
+ retry: Retry.Retry,
705
+ telemetry: TELEMETRY,
706
+ span: "AddChannelModerator",
707
+ }));
708
+
709
+ export type AddChannelVipError = TwitchOpError;
710
+ /** Add Channel VIP Adds the specified user as a VIP in the broadcaster's channel. **Rate Limits**: The broadcaster may add a maximum of 10 VIPs within a 10-second window. Authorization: Requires one of the following: - A [user access token](https://dev.twitch.tv/docs/authentication.md#user-access-tokens) that includes the **channel:manage:vips** scope. Reference: https://dev.twitch.tv/docs/api/reference/moderation/#add-channel-vip */
711
+ export const addChannelVip: API.OperationMethod<
712
+ AddChannelVipRequest,
713
+ AddChannelVipResponse,
714
+ AddChannelVipError,
715
+ TwitchOpContext
716
+ > = /*@__PURE__*/ API.make(() => ({
717
+ input: __S(128, __c16, 0) as any as S.Schema<AddChannelVipRequest>,
718
+ output: __S(24, __c3, 0) as any as S.Schema<AddChannelVipResponse>,
719
+ errors: [],
720
+ serviceErrors: TwitchServiceErrors,
721
+ protocol: TwitchProtocol,
722
+ retry: Retry.Retry,
723
+ telemetry: TELEMETRY,
724
+ span: "AddChannelVip",
725
+ }));
726
+
727
+ export type AddSuspiciousStatusToChatUserError = TwitchOpError;
728
+ /** Add Suspicious Status to Chat User Adds a suspicious user status to a chatter on the broadcaster's channel. Authorization: Requires one of the following: - A [user access token](https://dev.twitch.tv/docs/authentication.md#user-access-tokens) that includes the **moderator:manage:suspicious_users** scope. - An [app access token](https://dev.twitch.tv/docs/authentication.md#app-access-tokens). The application, through prior authorization, must have been granted: - The **moderator:manage:suspicious_users** scope for the user represented by the *moderator_id* query parameter. Reference: https://dev.twitch.tv/docs/api/reference/moderation/#add-suspicious-status-to-chat-user */
729
+ export const addSuspiciousStatusToChatUser: API.OperationMethod<
730
+ AddSuspiciousStatusToChatUserRequest,
731
+ AddSuspiciousStatusToChatUserResponse,
732
+ AddSuspiciousStatusToChatUserError,
733
+ TwitchOpContext
734
+ > = /*@__PURE__*/ API.make(() => ({
735
+ input: __S(176, __c22, 0) as any as S.Schema<AddSuspiciousStatusToChatUserRequest>,
736
+ output: __S(186, __c23, 2) as any as S.Schema<AddSuspiciousStatusToChatUserResponse>,
737
+ errors: [],
738
+ serviceErrors: TwitchServiceErrors,
739
+ protocol: TwitchProtocol,
740
+ retry: Retry.Retry,
741
+ telemetry: TELEMETRY,
742
+ span: "AddSuspiciousStatusToChatUser",
743
+ }));
744
+
745
+ export type BanUserError = TwitchOpError;
746
+ /** Ban User Bans a user from participating in the specified broadcaster's chat room or puts them in a timeout. For information about banning or putting users in a timeout, see [Ban a User](https://help.twitch.tv/s/article/how-to-manage-harassment-in-chat#TheBanFeature) and [Timeout a User](https://help.twitch.tv/s/article/how-to-manage-harassment-in-chat#TheTimeoutFeature) If the user is currently in a timeout, you can call this endpoint to change the duration of the timeout or ban them altogether. If the user is currently banned, you cannot call this method to put them in a timeout instead. To remove a ban or end a timeout, see [Unban user](#unban-user). Authorization: Requires one of the following: - A [user access token](https://dev.twitch.tv/docs/authentication.md#user-access-tokens) that includes the **moderator:manage:banned_users** scope. - An [app access token](https://dev.twitch.tv/docs/authentication.md#app-access-tokens). The application, through prior authorization, must have been granted: - The **moderator:manage:banned_users**, **user:bot** scopes for the user represented by the *moderator_id* query parameter. Reference: https://dev.twitch.tv/docs/api/reference/moderation/#ban-user */
747
+ export const banUser: API.OperationMethod<
748
+ BanUserRequest,
749
+ BanUserResponse,
750
+ BanUserError,
751
+ TwitchOpContext
752
+ > = /*@__PURE__*/ API.make(() => ({
753
+ input: __S(201, __c25, 1) as any as S.Schema<BanUserRequest>,
754
+ output: __S(204, __c25, 4) as any as S.Schema<BanUserResponse>,
755
+ errors: [],
756
+ serviceErrors: TwitchServiceErrors,
757
+ protocol: TwitchProtocol,
758
+ retry: Retry.Retry,
759
+ telemetry: TELEMETRY,
760
+ span: "BanUser",
761
+ }));
762
+
763
+ export type CheckAutomodStatusError = TwitchOpError;
764
+ /** Check AutoMod Status Checks whether AutoMod would flag the specified message for review. AutoMod is a moderation tool that holds inappropriate or harassing chat messages for moderators to review. Moderators approve or deny the messages that AutoMod flags; only approved messages are released to chat. AutoMod detects misspellings and evasive language automatically. For information about AutoMod, see [How to Use AutoMod](https://help.twitch.tv/s/article/how-to-use-automod). **Rate Limits**: Rates are limited per channel based on the account type rather than per access token. Each message in the request counts toward the limits, and the request fails if checking any one of the messages would exceed a limit. The above limits are in addition to the standard [Twitch API rate limits](https://dev.twitch.tv/docs/api/guide.md#twitch-rate-limits). The rate limit headers in the response represent the Twitch rate limits and not the above limits. Authorization: Requires one of the following: - A [user access token](https://dev.twitch.tv/docs/authentication.md#user-access-tokens) that includes the **moderation:read** scope. - An [app access token](https://dev.twitch.tv/docs/authentication.md#app-access-tokens). The application, through prior authorization, must have been granted: - The **moderation:read** scope for the user represented by the *broadcaster_id* query parameter. Reference: https://dev.twitch.tv/docs/api/reference/moderation/#check-automod-status */
765
+ export const checkAutomodStatus: API.OperationMethod<
766
+ CheckAutomodStatusRequest,
767
+ CheckAutomodStatusResponse,
768
+ CheckAutomodStatusError,
769
+ TwitchOpContext
770
+ > = /*@__PURE__*/ API.make(() => ({
771
+ input: __S(210, __c26, 2) as any as S.Schema<CheckAutomodStatusRequest>,
772
+ output: __S(213, __c26, 5) as any as S.Schema<CheckAutomodStatusResponse>,
773
+ errors: [],
774
+ serviceErrors: TwitchServiceErrors,
775
+ protocol: TwitchProtocol,
776
+ retry: Retry.Retry,
777
+ telemetry: TELEMETRY,
778
+ span: "CheckAutomodStatus",
779
+ }));
780
+
781
+ export type DeleteChatMessagesError = TwitchOpError;
782
+ /** Delete Chat Messages Removes a single chat message or all chat messages from the broadcaster's chat room. Authorization: Requires one of the following: - A [user access token](https://dev.twitch.tv/docs/authentication.md#user-access-tokens) that includes the **moderator:manage:chat_messages** scope. - An [app access token](https://dev.twitch.tv/docs/authentication.md#app-access-tokens). The application, through prior authorization, must have been granted: - The **moderator:manage:chat_messages** scope for the user represented by the *moderator_id* query parameter. Reference: https://dev.twitch.tv/docs/api/reference/moderation/#delete-chat-messages */
783
+ export const deleteChatMessages: API.OperationMethod<
784
+ DeleteChatMessagesRequest,
785
+ DeleteChatMessagesResponse,
786
+ DeleteChatMessagesError,
787
+ TwitchOpContext
788
+ > = /*@__PURE__*/ API.make(() => ({
789
+ input: __S(216, __c27, 0) as any as S.Schema<DeleteChatMessagesRequest>,
790
+ output: __S(24, __c3, 0) as any as S.Schema<DeleteChatMessagesResponse>,
791
+ errors: [],
792
+ serviceErrors: TwitchServiceErrors,
793
+ protocol: TwitchProtocol,
794
+ retry: Retry.Retry,
795
+ telemetry: TELEMETRY,
796
+ span: "DeleteChatMessages",
797
+ }));
798
+
799
+ export type GetAutomodSettingsError = TwitchOpError;
800
+ /** Get AutoMod Settings Gets the broadcaster's AutoMod settings. These settings are used to automatically block inappropriate or harassing messages from appearing in the broadcaster's chat room. Authorization: Requires one of the following: - A [user access token](https://dev.twitch.tv/docs/authentication.md#user-access-tokens) that includes the **moderator:read:automod_settings** or **moderator:manage:automod_settings** scope. - An [app access token](https://dev.twitch.tv/docs/authentication.md#app-access-tokens). The application, through prior authorization, must have been granted: - The **moderator:read:automod_settings** or **moderator:manage:automod_settings** scope for the user represented by the *moderator_id* query parameter. Reference: https://dev.twitch.tv/docs/api/reference/moderation/#get-automod-settings */
801
+ export const getAutomodSettings: API.OperationMethod<
802
+ GetAutomodSettingsRequest,
803
+ GetAutomodSettingsResponse,
804
+ GetAutomodSettingsError,
805
+ TwitchOpContext
806
+ > = /*@__PURE__*/ API.make(() => ({
807
+ input: __S(224, __c28, 0) as any as S.Schema<GetAutomodSettingsRequest>,
808
+ output: __S(234, __c29, 2) as any as S.Schema<GetAutomodSettingsResponse>,
809
+ errors: [],
810
+ serviceErrors: TwitchServiceErrors,
811
+ protocol: TwitchProtocol,
812
+ retry: Retry.Retry,
813
+ telemetry: TELEMETRY,
814
+ span: "GetAutomodSettings",
815
+ }));
816
+
817
+ export type GetBannedUsersError = TwitchOpError;
818
+ /** Get Banned Users Gets all users that the broadcaster banned or put in a timeout. Authorization: Requires one of the following: - A [user access token](https://dev.twitch.tv/docs/authentication.md#user-access-tokens) that includes the **moderation:read** or **moderator:manage:banned_users** scope. - An [app access token](https://dev.twitch.tv/docs/authentication.md#app-access-tokens). The application, through prior authorization, must have been granted: - The **moderation:read** or **moderator:manage:banned_users** scope for the user represented by the *broadcaster_id* query parameter. Reference: https://dev.twitch.tv/docs/api/reference/moderation/#get-banned-users */
819
+ export const getBannedUsers: API.PaginatedOperationMethod<
820
+ GetBannedUsersRequest,
821
+ GetBannedUsersResponse,
822
+ GetBannedUsersError,
823
+ TwitchOpContext,
824
+ GetBannedUsersResponseDataItem
825
+ > = /*@__PURE__*/ API.makePaginated(
826
+ () => ({
827
+ input: __S(240, __c30, 0) as any as S.Schema<GetBannedUsersRequest>,
828
+ output: __S(243, __c30, 3) as any as S.Schema<GetBannedUsersResponse>,
829
+ errors: [],
830
+ serviceErrors: TwitchServiceErrors,
831
+ protocol: TwitchProtocol,
832
+ retry: Retry.Retry,
833
+ telemetry: TELEMETRY,
834
+ span: "GetBannedUsers",
835
+ pagination: {
836
+ mode: "cursor",
837
+ inputToken: "after",
838
+ outputToken: "pagination.cursor",
839
+ items: "data",
840
+ pageSize: "first",
841
+ } as const,
842
+ }),
843
+ paginateCursor,
844
+ ) as any;
845
+
846
+ export type GetBlockedTermsError = TwitchOpError;
847
+ /** Get Blocked Terms Gets the broadcaster's list of blocked words or phrases. These are the terms that the broadcaster or moderator added manually or that were denied by AutoMod. The list includes the broadcaster's private terms only if the ID in *moderator_id* is the broadcaster's ID. The response doesn't indicate which terms are private. Authorization: Requires one of the following: - A [user access token](https://dev.twitch.tv/docs/authentication.md#user-access-tokens) that includes the **moderator:read:blocked_terms** or **moderator:manage:blocked_terms** scope. - An [app access token](https://dev.twitch.tv/docs/authentication.md#app-access-tokens). The application, through prior authorization, must have been granted: - The **moderator:read:blocked_terms** or **moderator:manage:blocked_terms** scope for the user represented by the *moderator_id* query parameter. Reference: https://dev.twitch.tv/docs/api/reference/moderation/#get-blocked-terms */
848
+ export const getBlockedTerms: API.PaginatedOperationMethod<
849
+ GetBlockedTermsRequest,
850
+ GetBlockedTermsResponse,
851
+ GetBlockedTermsError,
852
+ TwitchOpContext,
853
+ AddBlockedTermResponseDataItem
854
+ > = /*@__PURE__*/ API.makePaginated(
855
+ () => ({
856
+ input: __S(256, __c32, 0) as any as S.Schema<GetBlockedTermsRequest>,
857
+ output: __S(257, __c32, 1) as any as S.Schema<GetBlockedTermsResponse>,
858
+ errors: [],
859
+ serviceErrors: TwitchServiceErrors,
860
+ protocol: TwitchProtocol,
861
+ retry: Retry.Retry,
862
+ telemetry: TELEMETRY,
863
+ span: "GetBlockedTerms",
864
+ pagination: {
865
+ mode: "cursor",
866
+ inputToken: "after",
867
+ outputToken: "pagination.cursor",
868
+ items: "data",
869
+ pageSize: "first",
870
+ } as const,
871
+ }),
872
+ paginateCursor,
873
+ ) as any;
874
+
875
+ export type GetModeratedChannelsError = TwitchOpError;
876
+ /** Get Moderated Channels Gets a list of channels that the specified user has moderator privileges in. Authorization: Requires one of the following: - A [user access token](https://dev.twitch.tv/docs/authentication.md#user-access-tokens) that includes the **user:read:moderated_channels** scope. That includes the **user:read:moderated_channels**. The user ID associated with the token must match the _user_id_ in the query parameter. - An [app access token](https://dev.twitch.tv/docs/authentication.md#app-access-tokens). The application, through prior authorization, must have been granted: - The **user:read:moderated_channels** scope for the user represented by the *user_id* query parameter. Reference: https://dev.twitch.tv/docs/api/reference/moderation/#get-moderated-channels */
877
+ export const getModeratedChannels: API.PaginatedOperationMethod<
878
+ GetModeratedChannelsRequest,
879
+ GetModeratedChannelsResponse,
880
+ GetModeratedChannelsError,
881
+ TwitchOpContext,
882
+ GetModeratedChannelsResponseDataItem
883
+ > = /*@__PURE__*/ API.makePaginated(
884
+ () => ({
885
+ input: __S(32, __c4, 0) as any as S.Schema<GetModeratedChannelsRequest>,
886
+ output: __S(35, __c4, 3) as any as S.Schema<GetModeratedChannelsResponse>,
887
+ errors: [],
888
+ serviceErrors: TwitchServiceErrors,
889
+ protocol: TwitchProtocol,
890
+ retry: Retry.Retry,
891
+ telemetry: TELEMETRY,
892
+ span: "GetModeratedChannels",
893
+ pagination: {
894
+ mode: "cursor",
895
+ inputToken: "after",
896
+ outputToken: "pagination.cursor",
897
+ items: "data",
898
+ pageSize: "first",
899
+ } as const,
900
+ }),
901
+ paginateCursor,
902
+ ) as any;
903
+
904
+ export type GetModeratorsError = TwitchOpError;
905
+ /** Get Moderators Gets all users allowed to moderate the broadcaster's chat room. Authorization: Requires one of the following: - A [user access token](https://dev.twitch.tv/docs/authentication.md#user-access-tokens) that includes the **moderation:read** or **channel:manage:moderators** scope. Reference: https://dev.twitch.tv/docs/api/reference/moderation/#get-moderators */
906
+ export const getModerators: API.PaginatedOperationMethod<
907
+ GetModeratorsRequest,
908
+ GetModeratorsResponse,
909
+ GetModeratorsError,
910
+ TwitchOpContext,
911
+ GetModeratorsResponseDataItem
912
+ > = /*@__PURE__*/ API.makePaginated(
913
+ () => ({
914
+ input: __S(40, __c5, 0) as any as S.Schema<GetModeratorsRequest>,
915
+ output: __S(43, __c5, 3) as any as S.Schema<GetModeratorsResponse>,
916
+ errors: [],
917
+ serviceErrors: TwitchServiceErrors,
918
+ protocol: TwitchProtocol,
919
+ retry: Retry.Retry,
920
+ telemetry: TELEMETRY,
921
+ span: "GetModerators",
922
+ pagination: {
923
+ mode: "cursor",
924
+ inputToken: "after",
925
+ outputToken: "pagination.cursor",
926
+ items: "data",
927
+ pageSize: "first",
928
+ } as const,
929
+ }),
930
+ paginateCursor,
931
+ ) as any;
932
+
933
+ export type GetShieldModeStatusError = TwitchOpError;
934
+ /** Get Shield Mode Status Gets the broadcaster's Shield Mode activation status. To receive notification when the broadcaster activates and deactivates Shield Mode, subscribe to the [channel.shield_mode.begin](https://dev.twitch.tv/docs/eventsub/reference/channel-moderation.md#channel-shield-mode-begin) and [channel.shield_mode.end](https://dev.twitch.tv/docs/eventsub/reference/channel-moderation.md#channel-shield-mode-end) subscription types. Authorization: Requires one of the following: - A [user access token](https://dev.twitch.tv/docs/authentication.md#user-access-tokens) that includes the **moderator:read:shield_mode** or **moderator:manage:shield_mode** scope. The user ID associated with the token must match the *moderator_id* in the query parameter. - An [app access token](https://dev.twitch.tv/docs/authentication.md#app-access-tokens). The application, through prior authorization, must have been granted: - The **moderator:read:shield_mode** or **moderator:manage:shield_mode** scope for the user represented by the *moderator_id* query parameter. Reference: https://dev.twitch.tv/docs/api/reference/moderation/#get-shield-mode-status */
935
+ export const getShieldModeStatus: API.OperationMethod<
936
+ GetShieldModeStatusRequest,
937
+ GetShieldModeStatusResponse,
938
+ GetShieldModeStatusError,
939
+ TwitchOpContext
940
+ > = /*@__PURE__*/ API.make(() => ({
941
+ input: __S(48, __c6, 0) as any as S.Schema<GetShieldModeStatusRequest>,
942
+ output: __S(58, __c7, 2) as any as S.Schema<GetShieldModeStatusResponse>,
943
+ errors: [],
944
+ serviceErrors: TwitchServiceErrors,
945
+ protocol: TwitchProtocol,
946
+ retry: Retry.Retry,
947
+ telemetry: TELEMETRY,
948
+ span: "GetShieldModeStatus",
949
+ }));
950
+
951
+ export type GetUnbanRequestsError = TwitchOpError;
952
+ /** Get Unban Requests Gets a list of unban requests for a broadcaster's channel. Authorization: Requires one of the following: - A [user access token](https://dev.twitch.tv/docs/authentication.md#user-access-tokens) that includes the **moderator:read:unban_requests** or **moderator:manage:unban_requests** scope. The User ID associated with the token must match the _moderator_id_ in the query parameter. Reference: https://dev.twitch.tv/docs/api/reference/moderation/#get-unban-requests */
953
+ export const getUnbanRequests: API.PaginatedOperationMethod<
954
+ GetUnbanRequestsRequest,
955
+ GetUnbanRequestsResponse,
956
+ GetUnbanRequestsError,
957
+ TwitchOpContext,
958
+ GetUnbanRequestsResponseDataItem
959
+ > = /*@__PURE__*/ API.makePaginated(
960
+ () => ({
961
+ input: __S(64, __c8, 0) as any as S.Schema<GetUnbanRequestsRequest>,
962
+ output: __S(65, __c8, 1) as any as S.Schema<GetUnbanRequestsResponse>,
963
+ errors: [],
964
+ serviceErrors: TwitchServiceErrors,
965
+ protocol: TwitchProtocol,
966
+ retry: Retry.Retry,
967
+ telemetry: TELEMETRY,
968
+ span: "GetUnbanRequests",
969
+ pagination: {
970
+ mode: "cursor",
971
+ inputToken: "after",
972
+ outputToken: "pagination.cursor",
973
+ items: "data",
974
+ pageSize: "first",
975
+ } as const,
976
+ }),
977
+ paginateCursor,
978
+ ) as any;
979
+
980
+ export type GetVipsError = TwitchOpError;
981
+ /** Get VIPs Gets a list of the broadcaster's VIPs. Authorization: Requires one of the following: - A [user access token](https://dev.twitch.tv/docs/authentication.md#user-access-tokens) that includes the **channel:read:vips** or **channel:manage:vips** scope. Reference: https://dev.twitch.tv/docs/api/reference/moderation/#get-vips */
982
+ export const getVips: API.PaginatedOperationMethod<
983
+ GetVipsRequest,
984
+ GetVipsResponse,
985
+ GetVipsError,
986
+ TwitchOpContext,
987
+ GetVipsResponseDataItem
988
+ > = /*@__PURE__*/ API.makePaginated(
989
+ () => ({
990
+ input: __S(80, __c10, 0) as any as S.Schema<GetVipsRequest>,
991
+ output: __S(83, __c10, 3) as any as S.Schema<GetVipsResponse>,
992
+ errors: [],
993
+ serviceErrors: TwitchServiceErrors,
994
+ protocol: TwitchProtocol,
995
+ retry: Retry.Retry,
996
+ telemetry: TELEMETRY,
997
+ span: "GetVips",
998
+ pagination: {
999
+ mode: "cursor",
1000
+ inputToken: "after",
1001
+ outputToken: "pagination.cursor",
1002
+ items: "data",
1003
+ pageSize: "first",
1004
+ } as const,
1005
+ }),
1006
+ paginateCursor,
1007
+ ) as any;
1008
+
1009
+ export type ManageHeldAutomodMessagesError = TwitchOpError;
1010
+ /** Manage Held AutoMod Messages Allow or deny the message that AutoMod flagged for review. For information about AutoMod, see [How to Use AutoMod](https://help.twitch.tv/s/article/how-to-use-automod). Authorization: Requires one of the following: - A [user access token](https://dev.twitch.tv/docs/authentication.md#user-access-tokens) that includes the **moderator:manage:automod** scope. - An [app access token](https://dev.twitch.tv/docs/authentication.md#app-access-tokens). The application, through prior authorization, must have been granted: - The **moderator:manage:automod** scope for the user represented by the *user_id* body field. Reference: https://dev.twitch.tv/docs/api/reference/moderation/#manage-held-automod-messages */
1011
+ export const manageHeldAutomodMessages: API.OperationMethod<
1012
+ ManageHeldAutomodMessagesRequest,
1013
+ ManageHeldAutomodMessagesResponse,
1014
+ ManageHeldAutomodMessagesError,
1015
+ TwitchOpContext
1016
+ > = /*@__PURE__*/ API.make(() => ({
1017
+ input: __S(88, __c11, 0) as any as S.Schema<ManageHeldAutomodMessagesRequest>,
1018
+ output: __S(24, __c3, 0) as any as S.Schema<ManageHeldAutomodMessagesResponse>,
1019
+ errors: [],
1020
+ serviceErrors: TwitchServiceErrors,
1021
+ protocol: TwitchProtocol,
1022
+ retry: Retry.Retry,
1023
+ telemetry: TELEMETRY,
1024
+ span: "ManageHeldAutomodMessages",
1025
+ }));
1026
+
1027
+ export type RemoveBlockedTermError = TwitchOpError;
1028
+ /** Remove Blocked Term Removes the word or phrase from the broadcaster's list of blocked terms. Authorization: Requires one of the following: - A [user access token](https://dev.twitch.tv/docs/authentication.md#user-access-tokens) that includes the **moderator:manage:blocked_terms** scope. - An [app access token](https://dev.twitch.tv/docs/authentication.md#app-access-tokens). The application, through prior authorization, must have been granted: - The **moderator:manage:blocked_terms** scope for the user represented by the *moderator_id* query parameter. Reference: https://dev.twitch.tv/docs/api/reference/moderation/#remove-blocked-term */
1029
+ export const removeBlockedTerm: API.OperationMethod<
1030
+ RemoveBlockedTermRequest,
1031
+ RemoveBlockedTermResponse,
1032
+ RemoveBlockedTermError,
1033
+ TwitchOpContext
1034
+ > = /*@__PURE__*/ API.make(() => ({
1035
+ input: __S(96, __c12, 0) as any as S.Schema<RemoveBlockedTermRequest>,
1036
+ output: __S(24, __c3, 0) as any as S.Schema<RemoveBlockedTermResponse>,
1037
+ errors: [],
1038
+ serviceErrors: TwitchServiceErrors,
1039
+ protocol: TwitchProtocol,
1040
+ retry: Retry.Retry,
1041
+ telemetry: TELEMETRY,
1042
+ span: "RemoveBlockedTerm",
1043
+ }));
1044
+
1045
+ export type RemoveChannelModeratorError = TwitchOpError;
1046
+ /** Remove Channel Moderator Removes a moderator from the broadcaster's chat room. **Rate Limits**: The broadcaster may remove a maximum of 10 moderators within a 10-second window. Authorization: Requires one of the following: - A [user access token](https://dev.twitch.tv/docs/authentication.md#user-access-tokens) that includes the **channel:manage:moderators** scope. Reference: https://dev.twitch.tv/docs/api/reference/moderation/#remove-channel-moderator */
1047
+ export const removeChannelModerator: API.OperationMethod<
1048
+ RemoveChannelModeratorRequest,
1049
+ RemoveChannelModeratorResponse,
1050
+ RemoveChannelModeratorError,
1051
+ TwitchOpContext
1052
+ > = /*@__PURE__*/ API.make(() => ({
1053
+ input: __S(104, __c13, 0) as any as S.Schema<RemoveChannelModeratorRequest>,
1054
+ output: __S(24, __c3, 0) as any as S.Schema<RemoveChannelModeratorResponse>,
1055
+ errors: [],
1056
+ serviceErrors: TwitchServiceErrors,
1057
+ protocol: TwitchProtocol,
1058
+ retry: Retry.Retry,
1059
+ telemetry: TELEMETRY,
1060
+ span: "RemoveChannelModerator",
1061
+ }));
1062
+
1063
+ export type RemoveChannelVipError = TwitchOpError;
1064
+ /** Remove Channel VIP Removes the specified user as a VIP in the broadcaster's channel. If the broadcaster is removing the user's VIP status, the ID in the *broadcaster_id* query parameter must match the user ID in the access token; otherwise, if the user is removing their VIP status themselves, the ID in the *user_id* query parameter must match the user ID in the access token. **Rate Limits**: The broadcaster may remove a maximum of 10 VIPs within a 10-second window. Authorization: Requires one of the following: - A [user access token](https://dev.twitch.tv/docs/authentication.md#user-access-tokens) that includes the **channel:manage:vips** scope. Reference: https://dev.twitch.tv/docs/api/reference/moderation/#remove-channel-vip */
1065
+ export const removeChannelVip: API.OperationMethod<
1066
+ RemoveChannelVipRequest,
1067
+ RemoveChannelVipResponse,
1068
+ RemoveChannelVipError,
1069
+ TwitchOpContext
1070
+ > = /*@__PURE__*/ API.make(() => ({
1071
+ input: __S(112, __c14, 0) as any as S.Schema<RemoveChannelVipRequest>,
1072
+ output: __S(24, __c3, 0) as any as S.Schema<RemoveChannelVipResponse>,
1073
+ errors: [],
1074
+ serviceErrors: TwitchServiceErrors,
1075
+ protocol: TwitchProtocol,
1076
+ retry: Retry.Retry,
1077
+ telemetry: TELEMETRY,
1078
+ span: "RemoveChannelVip",
1079
+ }));
1080
+
1081
+ export type RemoveSuspiciousStatusFromChatUserError = TwitchOpError;
1082
+ /** Remove Suspicious Status From Chat User Remove a suspicious user status from a chatter on broadcaster's channel. Authorization: Requires one of the following: - A [user access token](https://dev.twitch.tv/docs/authentication.md#user-access-tokens) that includes the **moderator:manage:suspicious_users** scope. - An [app access token](https://dev.twitch.tv/docs/authentication.md#app-access-tokens). The application, through prior authorization, must have been granted: - The **moderator:manage:suspicious_users** scope for the user represented by the *moderator_id* query parameter. Reference: https://dev.twitch.tv/docs/api/reference/moderation/#remove-suspicious-status-from-chat-user */
1083
+ export const removeSuspiciousStatusFromChatUser: API.OperationMethod<
1084
+ RemoveSuspiciousStatusFromChatUserRequest,
1085
+ RemoveSuspiciousStatusFromChatUserResponse,
1086
+ RemoveSuspiciousStatusFromChatUserError,
1087
+ TwitchOpContext
1088
+ > = /*@__PURE__*/ API.make(() => ({
1089
+ input: __S(120, __c15, 0) as any as S.Schema<RemoveSuspiciousStatusFromChatUserRequest>,
1090
+ output: __S(186, __c23, 2) as any as S.Schema<RemoveSuspiciousStatusFromChatUserResponse>,
1091
+ errors: [],
1092
+ serviceErrors: TwitchServiceErrors,
1093
+ protocol: TwitchProtocol,
1094
+ retry: Retry.Retry,
1095
+ telemetry: TELEMETRY,
1096
+ span: "RemoveSuspiciousStatusFromChatUser",
1097
+ }));
1098
+
1099
+ export type ResolveUnbanRequestsError = TwitchOpError;
1100
+ /** Resolve Unban Requests Resolves an unban request by approving or denying it. Authorization: Requires one of the following: - A [user access token](https://dev.twitch.tv/docs/authentication.md#user-access-tokens) that includes the **moderator:manage:unban_requests** scope. The User ID associated with the token must match the _moderator_id_ in the query parameter. Reference: https://dev.twitch.tv/docs/api/reference/moderation/#resolve-unban-requests */
1101
+ export const resolveUnbanRequests: API.OperationMethod<
1102
+ ResolveUnbanRequestsRequest,
1103
+ ResolveUnbanRequestsResponse,
1104
+ ResolveUnbanRequestsError,
1105
+ TwitchOpContext
1106
+ > = /*@__PURE__*/ API.make(() => ({
1107
+ input: __S(136, __c17, 0) as any as S.Schema<ResolveUnbanRequestsRequest>,
1108
+ output: __S(137, __c17, 1) as any as S.Schema<ResolveUnbanRequestsResponse>,
1109
+ errors: [],
1110
+ serviceErrors: TwitchServiceErrors,
1111
+ protocol: TwitchProtocol,
1112
+ retry: Retry.Retry,
1113
+ telemetry: TELEMETRY,
1114
+ span: "ResolveUnbanRequests",
1115
+ }));
1116
+
1117
+ export type UnbanUserError = TwitchOpError;
1118
+ /** Unban User Removes the ban or timeout that was placed on the specified user. To ban a user, see [Ban user](#ban-user). Authorization: Requires one of the following: - A [user access token](https://dev.twitch.tv/docs/authentication.md#user-access-tokens) that includes the **moderator:manage:banned_users** scope. - An [app access token](https://dev.twitch.tv/docs/authentication.md#app-access-tokens). The application, through prior authorization, must have been granted: - The **moderator:manage:banned_users**, **user:bot** scopes for the user represented by the *moderator_id* query parameter. Reference: https://dev.twitch.tv/docs/api/reference/moderation/#unban-user */
1119
+ export const unbanUser: API.OperationMethod<
1120
+ UnbanUserRequest,
1121
+ UnbanUserResponse,
1122
+ UnbanUserError,
1123
+ TwitchOpContext
1124
+ > = /*@__PURE__*/ API.make(() => ({
1125
+ input: __S(144, __c18, 0) as any as S.Schema<UnbanUserRequest>,
1126
+ output: __S(24, __c3, 0) as any as S.Schema<UnbanUserResponse>,
1127
+ errors: [],
1128
+ serviceErrors: TwitchServiceErrors,
1129
+ protocol: TwitchProtocol,
1130
+ retry: Retry.Retry,
1131
+ telemetry: TELEMETRY,
1132
+ span: "UnbanUser",
1133
+ }));
1134
+
1135
+ export type UpdateAutomodSettingsError = TwitchOpError;
1136
+ /** Update AutoMod Settings Updates the broadcaster's AutoMod settings. The settings are used to automatically block inappropriate or harassing messages from appearing in the broadcaster's chat room. Each setting, including *overall_level*, accepts a level from 0 through 4. If you set individual settings, any individual setting that you don't include is set to 0. To change only some settings, get the current settings with [Get AutoMod Settings](https://dev.twitch.tv/docs/api/reference/moderation.md#get-automod-settings) and include all of them in the request. Authorization: Requires one of the following: - A [user access token](https://dev.twitch.tv/docs/authentication.md#user-access-tokens) that includes the **moderator:manage:automod_settings** scope. - An [app access token](https://dev.twitch.tv/docs/authentication.md#app-access-tokens). The application, through prior authorization, must have been granted: - The **moderator:manage:automod_settings** scope for the user represented by the *moderator_id* query parameter. Reference: https://dev.twitch.tv/docs/api/reference/moderation/#update-automod-settings */
1137
+ export const updateAutomodSettings: API.OperationMethod<
1138
+ UpdateAutomodSettingsRequest,
1139
+ UpdateAutomodSettingsResponse,
1140
+ UpdateAutomodSettingsError,
1141
+ TwitchOpContext
1142
+ > = /*@__PURE__*/ API.make(() => ({
1143
+ input: __S(152, __c19, 0) as any as S.Schema<UpdateAutomodSettingsRequest>,
1144
+ output: __S(234, __c29, 2) as any as S.Schema<UpdateAutomodSettingsResponse>,
1145
+ errors: [],
1146
+ serviceErrors: TwitchServiceErrors,
1147
+ protocol: TwitchProtocol,
1148
+ retry: Retry.Retry,
1149
+ telemetry: TELEMETRY,
1150
+ span: "UpdateAutomodSettings",
1151
+ }));
1152
+
1153
+ export type UpdateShieldModeStatusError = TwitchOpError;
1154
+ /** Update Shield Mode Status Activates or deactivates the broadcaster's Shield Mode. Twitch's Shield Mode feature is like a panic button that broadcasters can push to protect themselves from chat abuse coming from one or more accounts. When activated, Shield Mode applies the overrides that the broadcaster configured in the Twitch UX. If the broadcaster hasn't configured Shield Mode, it applies default overrides. Authorization: Requires one of the following: - A [user access token](https://dev.twitch.tv/docs/authentication.md#user-access-tokens) that includes the **moderator:manage:shield_mode** scope. The user ID associated with the token must match the *moderator_id* in the query parameter. - An [app access token](https://dev.twitch.tv/docs/authentication.md#app-access-tokens). The application, through prior authorization, must have been granted: - The **moderator:manage:shield_mode** scope for the user represented by the *moderator_id* query parameter. Reference: https://dev.twitch.tv/docs/api/reference/moderation/#update-shield-mode-status */
1155
+ export const updateShieldModeStatus: API.OperationMethod<
1156
+ UpdateShieldModeStatusRequest,
1157
+ UpdateShieldModeStatusResponse,
1158
+ UpdateShieldModeStatusError,
1159
+ TwitchOpContext
1160
+ > = /*@__PURE__*/ API.make(() => ({
1161
+ input: __S(160, __c20, 0) as any as S.Schema<UpdateShieldModeStatusRequest>,
1162
+ output: __S(58, __c7, 2) as any as S.Schema<UpdateShieldModeStatusResponse>,
1163
+ errors: [],
1164
+ serviceErrors: TwitchServiceErrors,
1165
+ protocol: TwitchProtocol,
1166
+ retry: Retry.Retry,
1167
+ telemetry: TELEMETRY,
1168
+ span: "UpdateShieldModeStatus",
1169
+ }));
1170
+
1171
+ export type WarnChatUserError = TwitchOpError;
1172
+ /** Warn Chat User Warns a user in the specified broadcaster's chat room, preventing them from chat interaction until the warning is acknowledged. New warnings can be issued to a user when they already have a warning in the channel (new warning will replace old warning). Authorization: Requires one of the following: - A [user access token](https://dev.twitch.tv/docs/authentication.md#user-access-tokens) that includes the **moderator:manage:warnings** scope. The user ID associated with the token must match the *moderator_id* in the query parameter. - An [app access token](https://dev.twitch.tv/docs/authentication.md#app-access-tokens). The application, through prior authorization, must have been granted: - The **moderator:manage:warnings** scope for the user represented by the *moderator_id* query parameter. Reference: https://dev.twitch.tv/docs/api/reference/moderation/#warn-chat-user */
1173
+ export const warnChatUser: API.OperationMethod<
1174
+ WarnChatUserRequest,
1175
+ WarnChatUserResponse,
1176
+ WarnChatUserError,
1177
+ TwitchOpContext
1178
+ > = /*@__PURE__*/ API.make(() => ({
1179
+ input: __S(169, __c21, 1) as any as S.Schema<WarnChatUserRequest>,
1180
+ output: __S(172, __c21, 4) as any as S.Schema<WarnChatUserResponse>,
1181
+ errors: [],
1182
+ serviceErrors: TwitchServiceErrors,
1183
+ protocol: TwitchProtocol,
1184
+ retry: Retry.Retry,
1185
+ telemetry: TELEMETRY,
1186
+ span: "WarnChatUser",
1187
+ }));
1188
+
1189
+ // Schema builders: each runs one schema initializer, on that schema's first use.
1190
+ function __c0(j: number): any {
1191
+ switch (j) {
1192
+ case 0:
1193
+ return S.suspend(() =>
1194
+ S.Struct({
1195
+ broadcaster_id: S.String.pipe(T.Query()),
1196
+ moderator_id: S.String.pipe(T.Query()),
1197
+ text: S.String,
1198
+ }).pipe(T.Http({ method: "POST", uri: "/moderation/blocked_terms", code: 200 })),
1199
+ ).annotate({ identifier: "AddBlockedTermRequest" });
1200
+ case 1:
1201
+ return S.suspend(() =>
1202
+ S.Struct({
1203
+ data: S.optional(__S(9, __c1, 1)),
1204
+ }),
1205
+ ).annotate({ identifier: "AddBlockedTermResponse" });
1206
+ }
1207
+ }
1208
+ function __c1(j: number): any {
1209
+ switch (j) {
1210
+ case 0:
1211
+ return S.suspend(() =>
1212
+ S.Struct({
1213
+ broadcaster_id: S.optional(S.String),
1214
+ moderator_id: S.optional(S.String),
1215
+ id: S.optional(S.String),
1216
+ text: S.optional(S.String),
1217
+ created_at: S.optional(S.String),
1218
+ updated_at: S.optional(S.String),
1219
+ expires_at: S.optional(S.String),
1220
+ }),
1221
+ ).annotate({ identifier: "AddBlockedTermResponseDataItem" });
1222
+ case 1:
1223
+ return S.Array(__S(8, __c1, 0));
1224
+ }
1225
+ }
1226
+ function __c2(j: number): any {
1227
+ switch (j) {
1228
+ case 0:
1229
+ return S.suspend(() =>
1230
+ S.Struct({
1231
+ broadcaster_id: S.String.pipe(T.Query()),
1232
+ user_id: S.String.pipe(T.Query()),
1233
+ }).pipe(T.Http({ method: "POST", uri: "/moderation/moderators", code: 200 })),
1234
+ ).annotate({ identifier: "AddChannelModeratorRequest" });
1235
+ }
1236
+ }
1237
+ function __c3(j: number): any {
1238
+ switch (j) {
1239
+ case 0:
1240
+ return S.suspend(() => S.Struct({})).annotate({ identifier: "AddChannelModeratorResponse" });
1241
+ }
1242
+ }
1243
+ function __c4(j: number): any {
1244
+ switch (j) {
1245
+ case 0:
1246
+ return S.suspend(() =>
1247
+ S.Struct({
1248
+ user_id: S.String.pipe(T.Query()),
1249
+ after: S.optional(S.String.pipe(T.Query())),
1250
+ first: S.optional(S.Number.pipe(T.Query())),
1251
+ }).pipe(T.Http({ method: "GET", uri: "/moderation/channels", code: 200 })),
1252
+ ).annotate({ identifier: "GetModeratedChannelsRequest" });
1253
+ case 1:
1254
+ return S.suspend(() =>
1255
+ S.Struct({
1256
+ broadcaster_id: S.optional(S.String),
1257
+ broadcaster_login: S.optional(S.String),
1258
+ broadcaster_name: S.optional(S.String),
1259
+ }),
1260
+ ).annotate({ identifier: "GetModeratedChannelsResponseDataItem" });
1261
+ case 2:
1262
+ return S.Array(__S(33, __c4, 1));
1263
+ case 3:
1264
+ return S.suspend(() =>
1265
+ S.Struct({
1266
+ data: __S(34, __c4, 2),
1267
+ pagination: S.optional(__S(248, __c31, 0)),
1268
+ }),
1269
+ ).annotate({ identifier: "GetModeratedChannelsResponse" });
1270
+ }
1271
+ }
1272
+ function __c5(j: number): any {
1273
+ switch (j) {
1274
+ case 0:
1275
+ return S.suspend(() =>
1276
+ S.Struct({
1277
+ broadcaster_id: S.String.pipe(T.Query()),
1278
+ user_id: S.optional(__S(192, __c24, 0).pipe(T.Query())),
1279
+ first: S.optional(S.Number.pipe(T.Query())),
1280
+ after: S.optional(S.String.pipe(T.Query())),
1281
+ }).pipe(T.Http({ method: "GET", uri: "/moderation/moderators", code: 200 })),
1282
+ ).annotate({ identifier: "GetModeratorsRequest" });
1283
+ case 1:
1284
+ return S.suspend(() =>
1285
+ S.Struct({
1286
+ user_id: S.optional(S.String),
1287
+ user_login: S.optional(S.String),
1288
+ user_name: S.optional(S.String),
1289
+ }),
1290
+ ).annotate({ identifier: "GetModeratorsResponseDataItem" });
1291
+ case 2:
1292
+ return S.Array(__S(41, __c5, 1));
1293
+ case 3:
1294
+ return S.suspend(() =>
1295
+ S.Struct({
1296
+ data: __S(42, __c5, 2),
1297
+ pagination: S.optional(__S(248, __c31, 0)),
1298
+ }),
1299
+ ).annotate({ identifier: "GetModeratorsResponse" });
1300
+ }
1301
+ }
1302
+ function __c6(j: number): any {
1303
+ switch (j) {
1304
+ case 0:
1305
+ return S.suspend(() =>
1306
+ S.Struct({
1307
+ broadcaster_id: S.String.pipe(T.Query()),
1308
+ moderator_id: S.String.pipe(T.Query()),
1309
+ }).pipe(T.Http({ method: "GET", uri: "/moderation/shield_mode", code: 200 })),
1310
+ ).annotate({ identifier: "GetShieldModeStatusRequest" });
1311
+ }
1312
+ }
1313
+ function __c7(j: number): any {
1314
+ switch (j) {
1315
+ case 0:
1316
+ return S.suspend(() =>
1317
+ S.Struct({
1318
+ is_active: S.optional(S.Boolean),
1319
+ moderator_id: S.optional(S.String),
1320
+ moderator_login: S.optional(S.String),
1321
+ moderator_name: S.optional(S.String),
1322
+ last_activated_at: S.optional(S.String),
1323
+ }),
1324
+ ).annotate({ identifier: "GetShieldModeStatusResponseDataItem" });
1325
+ case 1:
1326
+ return S.Array(__S(56, __c7, 0));
1327
+ case 2:
1328
+ return S.suspend(() =>
1329
+ S.Struct({
1330
+ data: S.optional(__S(57, __c7, 1)),
1331
+ }),
1332
+ ).annotate({ identifier: "GetShieldModeStatusResponse" });
1333
+ }
1334
+ }
1335
+ function __c8(j: number): any {
1336
+ switch (j) {
1337
+ case 0:
1338
+ return S.suspend(() =>
1339
+ S.Struct({
1340
+ broadcaster_id: S.String.pipe(T.Query()),
1341
+ moderator_id: S.String.pipe(T.Query()),
1342
+ status: S.String.pipe(T.Query()),
1343
+ user_id: S.optional(S.String.pipe(T.Query())),
1344
+ after: S.optional(S.String.pipe(T.Query())),
1345
+ first: S.optional(S.Number.pipe(T.Query())),
1346
+ }).pipe(T.Http({ method: "GET", uri: "/moderation/unban_requests", code: 200 })),
1347
+ ).annotate({ identifier: "GetUnbanRequestsRequest" });
1348
+ case 1:
1349
+ return S.suspend(() =>
1350
+ S.Struct({
1351
+ data: __S(73, __c9, 1),
1352
+ pagination: S.optional(__S(248, __c31, 0)),
1353
+ }),
1354
+ ).annotate({ identifier: "GetUnbanRequestsResponse" });
1355
+ }
1356
+ }
1357
+ function __c9(j: number): any {
1358
+ switch (j) {
1359
+ case 0:
1360
+ return S.suspend(() =>
1361
+ S.Struct({
1362
+ id: S.optional(S.String),
1363
+ broadcaster_id: S.optional(S.String),
1364
+ broadcaster_login: S.optional(S.String),
1365
+ broadcaster_name: S.optional(S.String),
1366
+ moderator_id: S.optional(S.NullOr(S.String)),
1367
+ moderator_login: S.optional(S.NullOr(S.String)),
1368
+ moderator_name: S.optional(S.NullOr(S.String)),
1369
+ user_id: S.optional(S.String),
1370
+ user_login: S.optional(S.String),
1371
+ user_name: S.optional(S.String),
1372
+ text: S.optional(S.String),
1373
+ status: S.optional(S.String),
1374
+ created_at: S.optional(S.String),
1375
+ resolved_at: S.optional(S.NullOr(S.String)),
1376
+ resolution_text: S.optional(S.NullOr(S.String)),
1377
+ }),
1378
+ ).annotate({ identifier: "GetUnbanRequestsResponseDataItem" });
1379
+ case 1:
1380
+ return S.Array(__S(72, __c9, 0));
1381
+ }
1382
+ }
1383
+ function __c10(j: number): any {
1384
+ switch (j) {
1385
+ case 0:
1386
+ return S.suspend(() =>
1387
+ S.Struct({
1388
+ user_id: S.optional(__S(192, __c24, 0).pipe(T.Query())),
1389
+ broadcaster_id: S.String.pipe(T.Query()),
1390
+ first: S.optional(S.Number.pipe(T.Query())),
1391
+ after: S.optional(S.String.pipe(T.Query())),
1392
+ }).pipe(T.Http({ method: "GET", uri: "/channels/vips", code: 200 })),
1393
+ ).annotate({ identifier: "GetVipsRequest" });
1394
+ case 1:
1395
+ return S.suspend(() =>
1396
+ S.Struct({
1397
+ user_id: S.optional(S.String),
1398
+ user_name: S.optional(S.String),
1399
+ user_login: S.optional(S.String),
1400
+ }),
1401
+ ).annotate({ identifier: "GetVipsResponseDataItem" });
1402
+ case 2:
1403
+ return S.Array(__S(81, __c10, 1));
1404
+ case 3:
1405
+ return S.suspend(() =>
1406
+ S.Struct({
1407
+ data: __S(82, __c10, 2),
1408
+ pagination: S.optional(__S(248, __c31, 0)),
1409
+ }),
1410
+ ).annotate({ identifier: "GetVipsResponse" });
1411
+ }
1412
+ }
1413
+ function __c11(j: number): any {
1414
+ switch (j) {
1415
+ case 0:
1416
+ return S.suspend(() =>
1417
+ S.Struct({
1418
+ user_id: S.String,
1419
+ msg_id: S.String,
1420
+ action: S.String,
1421
+ }).pipe(T.Http({ method: "POST", uri: "/moderation/automod/message", code: 200 })),
1422
+ ).annotate({ identifier: "ManageHeldAutomodMessagesRequest" });
1423
+ }
1424
+ }
1425
+ function __c12(j: number): any {
1426
+ switch (j) {
1427
+ case 0:
1428
+ return S.suspend(() =>
1429
+ S.Struct({
1430
+ broadcaster_id: S.String.pipe(T.Query()),
1431
+ moderator_id: S.String.pipe(T.Query()),
1432
+ id: S.String.pipe(T.Query()),
1433
+ }).pipe(T.Http({ method: "DELETE", uri: "/moderation/blocked_terms", code: 200 })),
1434
+ ).annotate({ identifier: "RemoveBlockedTermRequest" });
1435
+ }
1436
+ }
1437
+ function __c13(j: number): any {
1438
+ switch (j) {
1439
+ case 0:
1440
+ return S.suspend(() =>
1441
+ S.Struct({
1442
+ broadcaster_id: S.String.pipe(T.Query()),
1443
+ user_id: S.String.pipe(T.Query()),
1444
+ }).pipe(T.Http({ method: "DELETE", uri: "/moderation/moderators", code: 200 })),
1445
+ ).annotate({ identifier: "RemoveChannelModeratorRequest" });
1446
+ }
1447
+ }
1448
+ function __c14(j: number): any {
1449
+ switch (j) {
1450
+ case 0:
1451
+ return S.suspend(() =>
1452
+ S.Struct({
1453
+ user_id: S.String.pipe(T.Query()),
1454
+ broadcaster_id: S.String.pipe(T.Query()),
1455
+ }).pipe(T.Http({ method: "DELETE", uri: "/channels/vips", code: 200 })),
1456
+ ).annotate({ identifier: "RemoveChannelVipRequest" });
1457
+ }
1458
+ }
1459
+ function __c15(j: number): any {
1460
+ switch (j) {
1461
+ case 0:
1462
+ return S.suspend(() =>
1463
+ S.Struct({
1464
+ broadcaster_id: S.String.pipe(T.Query()),
1465
+ moderator_id: S.String.pipe(T.Query()),
1466
+ user_id: S.String.pipe(T.Query()),
1467
+ }).pipe(T.Http({ method: "DELETE", uri: "/moderation/suspicious_users", code: 200 })),
1468
+ ).annotate({ identifier: "RemoveSuspiciousStatusFromChatUserRequest" });
1469
+ }
1470
+ }
1471
+ function __c16(j: number): any {
1472
+ switch (j) {
1473
+ case 0:
1474
+ return S.suspend(() =>
1475
+ S.Struct({
1476
+ user_id: S.String.pipe(T.Query()),
1477
+ broadcaster_id: S.String.pipe(T.Query()),
1478
+ }).pipe(T.Http({ method: "POST", uri: "/channels/vips", code: 200 })),
1479
+ ).annotate({ identifier: "AddChannelVipRequest" });
1480
+ }
1481
+ }
1482
+ function __c17(j: number): any {
1483
+ switch (j) {
1484
+ case 0:
1485
+ return S.suspend(() =>
1486
+ S.Struct({
1487
+ broadcaster_id: S.String.pipe(T.Query()),
1488
+ moderator_id: S.String.pipe(T.Query()),
1489
+ unban_request_id: S.String.pipe(T.Query()),
1490
+ status: S.String.pipe(T.Query()),
1491
+ resolution_text: S.optional(S.String.pipe(T.Query())),
1492
+ }).pipe(T.Http({ method: "PATCH", uri: "/moderation/unban_requests", code: 200 })),
1493
+ ).annotate({ identifier: "ResolveUnbanRequestsRequest" });
1494
+ case 1:
1495
+ return S.suspend(() =>
1496
+ S.Struct({
1497
+ data: S.optional(__S(73, __c9, 1)),
1498
+ }),
1499
+ ).annotate({ identifier: "ResolveUnbanRequestsResponse" });
1500
+ }
1501
+ }
1502
+ function __c18(j: number): any {
1503
+ switch (j) {
1504
+ case 0:
1505
+ return S.suspend(() =>
1506
+ S.Struct({
1507
+ broadcaster_id: S.String.pipe(T.Query()),
1508
+ moderator_id: S.String.pipe(T.Query()),
1509
+ user_id: S.String.pipe(T.Query()),
1510
+ }).pipe(T.Http({ method: "DELETE", uri: "/moderation/bans", code: 200 })),
1511
+ ).annotate({ identifier: "UnbanUserRequest" });
1512
+ }
1513
+ }
1514
+ function __c19(j: number): any {
1515
+ switch (j) {
1516
+ case 0:
1517
+ return S.suspend(() =>
1518
+ S.Struct({
1519
+ broadcaster_id: S.String.pipe(T.Query()),
1520
+ moderator_id: S.String.pipe(T.Query()),
1521
+ aggression: S.optional(S.Number),
1522
+ bullying: S.optional(S.Number),
1523
+ disability: S.optional(S.Number),
1524
+ misogyny: S.optional(S.Number),
1525
+ overall_level: S.optional(S.Number),
1526
+ race_ethnicity_or_religion: S.optional(S.Number),
1527
+ sex_based_terms: S.optional(S.Number),
1528
+ sexuality_sex_or_gender: S.optional(S.Number),
1529
+ swearing: S.optional(S.Number),
1530
+ }).pipe(T.Http({ method: "PUT", uri: "/moderation/automod/settings", code: 200 })),
1531
+ ).annotate({ identifier: "UpdateAutomodSettingsRequest" });
1532
+ }
1533
+ }
1534
+ function __c20(j: number): any {
1535
+ switch (j) {
1536
+ case 0:
1537
+ return S.suspend(() =>
1538
+ S.Struct({
1539
+ broadcaster_id: S.String.pipe(T.Query()),
1540
+ moderator_id: S.String.pipe(T.Query()),
1541
+ is_active: S.Boolean,
1542
+ }).pipe(T.Http({ method: "PUT", uri: "/moderation/shield_mode", code: 200 })),
1543
+ ).annotate({ identifier: "UpdateShieldModeStatusRequest" });
1544
+ }
1545
+ }
1546
+ function __c21(j: number): any {
1547
+ switch (j) {
1548
+ case 0:
1549
+ return S.suspend(() =>
1550
+ S.Struct({
1551
+ user_id: S.String,
1552
+ reason: S.String,
1553
+ }),
1554
+ ).annotate({ identifier: "WarnChatUserRequestData" });
1555
+ case 1:
1556
+ return S.suspend(() =>
1557
+ S.Struct({
1558
+ broadcaster_id: S.String.pipe(T.Query()),
1559
+ moderator_id: S.String.pipe(T.Query()),
1560
+ data: __S(168, __c21, 0),
1561
+ }).pipe(T.Http({ method: "POST", uri: "/moderation/warnings", code: 200 })),
1562
+ ).annotate({ identifier: "WarnChatUserRequest" });
1563
+ case 2:
1564
+ return S.suspend(() =>
1565
+ S.Struct({
1566
+ broadcaster_id: S.optional(S.String),
1567
+ user_id: S.optional(S.String),
1568
+ moderator_id: S.optional(S.String),
1569
+ reason: S.optional(S.String),
1570
+ }),
1571
+ ).annotate({ identifier: "WarnChatUserResponseDataItem" });
1572
+ case 3:
1573
+ return S.Array(__S(170, __c21, 2));
1574
+ case 4:
1575
+ return S.suspend(() =>
1576
+ S.Struct({
1577
+ data: S.optional(__S(171, __c21, 3)),
1578
+ }),
1579
+ ).annotate({ identifier: "WarnChatUserResponse" });
1580
+ }
1581
+ }
1582
+ function __c22(j: number): any {
1583
+ switch (j) {
1584
+ case 0:
1585
+ return S.suspend(() =>
1586
+ S.Struct({
1587
+ broadcaster_id: S.String.pipe(T.Query()),
1588
+ moderator_id: S.String.pipe(T.Query()),
1589
+ user_id: S.String,
1590
+ status: S.String,
1591
+ }).pipe(T.Http({ method: "POST", uri: "/moderation/suspicious_users", code: 200 })),
1592
+ ).annotate({ identifier: "AddSuspiciousStatusToChatUserRequest" });
1593
+ }
1594
+ }
1595
+ function __c23(j: number): any {
1596
+ switch (j) {
1597
+ case 0:
1598
+ return S.suspend(() =>
1599
+ S.Struct({
1600
+ user_id: S.optional(S.String),
1601
+ broadcaster_id: S.optional(S.String),
1602
+ moderator_id: S.optional(S.String),
1603
+ updated_at: S.optional(S.String),
1604
+ status: S.optional(S.String),
1605
+ types: S.optional(__S(192, __c24, 0)),
1606
+ }),
1607
+ ).annotate({ identifier: "AddSuspiciousStatusToChatUserResponseDataItem" });
1608
+ case 1:
1609
+ return S.Array(__S(184, __c23, 0));
1610
+ case 2:
1611
+ return S.suspend(() =>
1612
+ S.Struct({
1613
+ data: S.optional(__S(185, __c23, 1)),
1614
+ }),
1615
+ ).annotate({ identifier: "AddSuspiciousStatusToChatUserResponse" });
1616
+ }
1617
+ }
1618
+ function __c24(j: number): any {
1619
+ switch (j) {
1620
+ case 0:
1621
+ return S.Array(S.String);
1622
+ }
1623
+ }
1624
+ function __c25(j: number): any {
1625
+ switch (j) {
1626
+ case 0:
1627
+ return S.suspend(() =>
1628
+ S.Struct({
1629
+ user_id: S.String,
1630
+ duration: S.optional(S.Number),
1631
+ reason: S.optional(S.String),
1632
+ }),
1633
+ ).annotate({ identifier: "BanUserRequestData" });
1634
+ case 1:
1635
+ return S.suspend(() =>
1636
+ S.Struct({
1637
+ broadcaster_id: S.String.pipe(T.Query()),
1638
+ moderator_id: S.String.pipe(T.Query()),
1639
+ data: __S(200, __c25, 0),
1640
+ }).pipe(T.Http({ method: "POST", uri: "/moderation/bans", code: 200 })),
1641
+ ).annotate({ identifier: "BanUserRequest" });
1642
+ case 2:
1643
+ return S.suspend(() =>
1644
+ S.Struct({
1645
+ broadcaster_id: S.optional(S.String),
1646
+ moderator_id: S.optional(S.String),
1647
+ user_id: S.optional(S.String),
1648
+ created_at: S.optional(S.String),
1649
+ end_time: S.optional(S.String),
1650
+ }),
1651
+ ).annotate({ identifier: "BanUserResponseDataItem" });
1652
+ case 3:
1653
+ return S.Array(__S(202, __c25, 2));
1654
+ case 4:
1655
+ return S.suspend(() =>
1656
+ S.Struct({
1657
+ data: S.optional(__S(203, __c25, 3)),
1658
+ }),
1659
+ ).annotate({ identifier: "BanUserResponse" });
1660
+ }
1661
+ }
1662
+ function __c26(j: number): any {
1663
+ switch (j) {
1664
+ case 0:
1665
+ return S.suspend(() =>
1666
+ S.Struct({
1667
+ msg_id: S.String,
1668
+ msg_text: S.String,
1669
+ }),
1670
+ ).annotate({ identifier: "CheckAutomodStatusRequestDataItem" });
1671
+ case 1:
1672
+ return S.Array(__S(208, __c26, 0));
1673
+ case 2:
1674
+ return S.suspend(() =>
1675
+ S.Struct({
1676
+ broadcaster_id: S.String.pipe(T.Query()),
1677
+ data: __S(209, __c26, 1),
1678
+ }).pipe(T.Http({ method: "POST", uri: "/moderation/enforcements/status", code: 200 })),
1679
+ ).annotate({ identifier: "CheckAutomodStatusRequest" });
1680
+ case 3:
1681
+ return S.suspend(() =>
1682
+ S.Struct({
1683
+ msg_id: S.optional(S.String),
1684
+ is_permitted: S.optional(S.Boolean),
1685
+ }),
1686
+ ).annotate({ identifier: "CheckAutomodStatusResponseDataItem" });
1687
+ case 4:
1688
+ return S.Array(__S(211, __c26, 3));
1689
+ case 5:
1690
+ return S.suspend(() =>
1691
+ S.Struct({
1692
+ data: S.optional(__S(212, __c26, 4)),
1693
+ }),
1694
+ ).annotate({ identifier: "CheckAutomodStatusResponse" });
1695
+ }
1696
+ }
1697
+ function __c27(j: number): any {
1698
+ switch (j) {
1699
+ case 0:
1700
+ return S.suspend(() =>
1701
+ S.Struct({
1702
+ broadcaster_id: S.String.pipe(T.Query()),
1703
+ moderator_id: S.String.pipe(T.Query()),
1704
+ message_id: S.optional(S.String.pipe(T.Query())),
1705
+ }).pipe(T.Http({ method: "DELETE", uri: "/moderation/chat", code: 200 })),
1706
+ ).annotate({ identifier: "DeleteChatMessagesRequest" });
1707
+ }
1708
+ }
1709
+ function __c28(j: number): any {
1710
+ switch (j) {
1711
+ case 0:
1712
+ return S.suspend(() =>
1713
+ S.Struct({
1714
+ broadcaster_id: S.String.pipe(T.Query()),
1715
+ moderator_id: S.String.pipe(T.Query()),
1716
+ }).pipe(T.Http({ method: "GET", uri: "/moderation/automod/settings", code: 200 })),
1717
+ ).annotate({ identifier: "GetAutomodSettingsRequest" });
1718
+ }
1719
+ }
1720
+ function __c29(j: number): any {
1721
+ switch (j) {
1722
+ case 0:
1723
+ return S.suspend(() =>
1724
+ S.Struct({
1725
+ broadcaster_id: S.optional(S.String),
1726
+ moderator_id: S.optional(S.String),
1727
+ overall_level: S.optional(S.NullOr(S.Number)),
1728
+ disability: S.optional(S.Number),
1729
+ aggression: S.optional(S.Number),
1730
+ sexuality_sex_or_gender: S.optional(S.Number),
1731
+ misogyny: S.optional(S.Number),
1732
+ bullying: S.optional(S.Number),
1733
+ swearing: S.optional(S.Number),
1734
+ race_ethnicity_or_religion: S.optional(S.Number),
1735
+ sex_based_terms: S.optional(S.Number),
1736
+ }),
1737
+ ).annotate({ identifier: "GetAutomodSettingsResponseDataItem" });
1738
+ case 1:
1739
+ return S.Array(__S(232, __c29, 0));
1740
+ case 2:
1741
+ return S.suspend(() =>
1742
+ S.Struct({
1743
+ data: S.optional(__S(233, __c29, 1)),
1744
+ }),
1745
+ ).annotate({ identifier: "GetAutomodSettingsResponse" });
1746
+ }
1747
+ }
1748
+ function __c30(j: number): any {
1749
+ switch (j) {
1750
+ case 0:
1751
+ return S.suspend(() =>
1752
+ S.Struct({
1753
+ broadcaster_id: S.String.pipe(T.Query()),
1754
+ user_id: S.optional(__S(192, __c24, 0).pipe(T.Query())),
1755
+ first: S.optional(S.Number.pipe(T.Query())),
1756
+ after: S.optional(S.String.pipe(T.Query())),
1757
+ }).pipe(T.Http({ method: "GET", uri: "/moderation/banned", code: 200 })),
1758
+ ).annotate({ identifier: "GetBannedUsersRequest" });
1759
+ case 1:
1760
+ return S.suspend(() =>
1761
+ S.Struct({
1762
+ user_id: S.optional(S.String),
1763
+ user_login: S.optional(S.String),
1764
+ user_name: S.optional(S.String),
1765
+ expires_at: S.optional(S.String),
1766
+ created_at: S.optional(S.String),
1767
+ reason: S.optional(S.String),
1768
+ moderator_id: S.optional(S.String),
1769
+ moderator_login: S.optional(S.String),
1770
+ moderator_name: S.optional(S.String),
1771
+ }),
1772
+ ).annotate({ identifier: "GetBannedUsersResponseDataItem" });
1773
+ case 2:
1774
+ return S.Array(__S(241, __c30, 1));
1775
+ case 3:
1776
+ return S.suspend(() =>
1777
+ S.Struct({
1778
+ data: __S(242, __c30, 2),
1779
+ pagination: S.optional(__S(248, __c31, 0)),
1780
+ }),
1781
+ ).annotate({ identifier: "GetBannedUsersResponse" });
1782
+ }
1783
+ }
1784
+ function __c31(j: number): any {
1785
+ switch (j) {
1786
+ case 0:
1787
+ return S.suspend(() =>
1788
+ S.Struct({
1789
+ cursor: S.optional(S.String),
1790
+ }),
1791
+ ).annotate({ identifier: "GetBannedUsersResponsePagination" });
1792
+ }
1793
+ }
1794
+ function __c32(j: number): any {
1795
+ switch (j) {
1796
+ case 0:
1797
+ return S.suspend(() =>
1798
+ S.Struct({
1799
+ broadcaster_id: S.String.pipe(T.Query()),
1800
+ moderator_id: S.String.pipe(T.Query()),
1801
+ first: S.optional(S.Number.pipe(T.Query())),
1802
+ after: S.optional(S.String.pipe(T.Query())),
1803
+ }).pipe(T.Http({ method: "GET", uri: "/moderation/blocked_terms", code: 200 })),
1804
+ ).annotate({ identifier: "GetBlockedTermsRequest" });
1805
+ case 1:
1806
+ return S.suspend(() =>
1807
+ S.Struct({
1808
+ data: __S(9, __c1, 1),
1809
+ pagination: S.optional(__S(248, __c31, 0)),
1810
+ }),
1811
+ ).annotate({ identifier: "GetBlockedTermsResponse" });
1812
+ }
1813
+ }
1814
+ // Schema table: entry i is schema j of builder f, made on first reach.
1815
+ function __S(i: number, f: (j: number) => unknown, j: number): any {
1816
+ return (__s[i] ??= __L.at(f, j));
1817
+ }