@knocklabs/node 1.0.0 → 1.2.0

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 (414) hide show
  1. package/CHANGELOG.md +38 -0
  2. package/README.md +1 -1
  3. package/api-promise.js +2 -15
  4. package/api-promise.js.map +1 -1
  5. package/client.d.mts +4 -1
  6. package/client.d.mts.map +1 -1
  7. package/client.d.ts +4 -1
  8. package/client.d.ts.map +1 -1
  9. package/client.js +27 -44
  10. package/client.js.map +1 -1
  11. package/client.mjs +18 -12
  12. package/client.mjs.map +1 -1
  13. package/core/api-promise.d.mts +0 -1
  14. package/core/api-promise.d.mts.map +1 -1
  15. package/core/api-promise.d.ts +0 -1
  16. package/core/api-promise.d.ts.map +1 -1
  17. package/core/api-promise.js +4 -14
  18. package/core/api-promise.js.map +1 -1
  19. package/core/api-promise.mjs +1 -11
  20. package/core/api-promise.mjs.map +1 -1
  21. package/core/error.d.mts +0 -1
  22. package/core/error.d.mts.map +1 -1
  23. package/core/error.d.ts +0 -1
  24. package/core/error.d.ts.map +1 -1
  25. package/core/error.js.map +1 -1
  26. package/core/error.mjs.map +1 -1
  27. package/core/pagination.d.mts +0 -1
  28. package/core/pagination.d.mts.map +1 -1
  29. package/core/pagination.d.ts +0 -1
  30. package/core/pagination.d.ts.map +1 -1
  31. package/core/pagination.js +3 -13
  32. package/core/pagination.js.map +1 -1
  33. package/core/pagination.mjs +1 -11
  34. package/core/pagination.mjs.map +1 -1
  35. package/error.js +2 -15
  36. package/error.js.map +1 -1
  37. package/internal/builtin-types.d.mts +0 -2
  38. package/internal/builtin-types.d.mts.map +1 -1
  39. package/internal/builtin-types.d.ts +0 -2
  40. package/internal/builtin-types.d.ts.map +1 -1
  41. package/internal/detect-platform.js.map +1 -1
  42. package/internal/detect-platform.mjs.map +1 -1
  43. package/internal/errors.d.mts.map +1 -1
  44. package/internal/errors.d.ts.map +1 -1
  45. package/internal/errors.js +2 -2
  46. package/internal/errors.js.map +1 -1
  47. package/internal/errors.mjs.map +1 -1
  48. package/internal/headers.d.mts +0 -1
  49. package/internal/headers.d.mts.map +1 -1
  50. package/internal/headers.d.ts +0 -1
  51. package/internal/headers.d.ts.map +1 -1
  52. package/internal/headers.js +1 -1
  53. package/internal/headers.js.map +1 -1
  54. package/internal/headers.mjs +1 -1
  55. package/internal/headers.mjs.map +1 -1
  56. package/internal/parse.d.mts +0 -1
  57. package/internal/parse.d.mts.map +1 -1
  58. package/internal/parse.d.ts +0 -1
  59. package/internal/parse.d.ts.map +1 -1
  60. package/internal/parse.js +1 -2
  61. package/internal/parse.js.map +1 -1
  62. package/internal/parse.mjs.map +1 -1
  63. package/internal/qs/stringify.js +1 -2
  64. package/internal/qs/stringify.js.map +1 -1
  65. package/internal/qs/stringify.mjs.map +1 -1
  66. package/internal/qs/utils.js +9 -9
  67. package/internal/qs/utils.js.map +1 -1
  68. package/internal/qs/utils.mjs.map +1 -1
  69. package/internal/request-options.d.mts +0 -1
  70. package/internal/request-options.d.mts.map +1 -1
  71. package/internal/request-options.d.ts +0 -1
  72. package/internal/request-options.d.ts.map +1 -1
  73. package/internal/shims.js +5 -6
  74. package/internal/shims.js.map +1 -1
  75. package/internal/shims.mjs.map +1 -1
  76. package/internal/to-file.d.mts +0 -1
  77. package/internal/to-file.d.mts.map +1 -1
  78. package/internal/to-file.d.ts +0 -1
  79. package/internal/to-file.d.ts.map +1 -1
  80. package/internal/to-file.js +4 -4
  81. package/internal/to-file.js.map +1 -1
  82. package/internal/to-file.mjs +3 -2
  83. package/internal/to-file.mjs.map +1 -1
  84. package/internal/tslib.js +81 -0
  85. package/internal/tslib.mjs +17 -0
  86. package/internal/types.d.mts +0 -1
  87. package/internal/types.d.mts.map +1 -1
  88. package/internal/types.d.ts +0 -1
  89. package/internal/types.d.ts.map +1 -1
  90. package/internal/uploads.d.mts +1 -3
  91. package/internal/uploads.d.mts.map +1 -1
  92. package/internal/uploads.d.ts +1 -3
  93. package/internal/uploads.d.ts.map +1 -1
  94. package/internal/uploads.js +16 -6
  95. package/internal/uploads.js.map +1 -1
  96. package/internal/uploads.mjs +12 -3
  97. package/internal/uploads.mjs.map +1 -1
  98. package/internal/utils/base64.d.mts.map +1 -1
  99. package/internal/utils/base64.d.ts.map +1 -1
  100. package/internal/utils/base64.js.map +1 -1
  101. package/internal/utils/base64.mjs.map +1 -1
  102. package/internal/utils/bytes.d.mts +1 -1
  103. package/internal/utils/bytes.d.mts.map +1 -1
  104. package/internal/utils/bytes.d.ts +1 -1
  105. package/internal/utils/bytes.d.ts.map +1 -1
  106. package/internal/utils/bytes.js +3 -4
  107. package/internal/utils/bytes.js.map +1 -1
  108. package/internal/utils/bytes.mjs.map +1 -1
  109. package/internal/utils/env.d.mts.map +1 -1
  110. package/internal/utils/env.d.ts.map +1 -1
  111. package/internal/utils/env.js.map +1 -1
  112. package/internal/utils/env.mjs.map +1 -1
  113. package/internal/utils/log.d.mts +0 -1
  114. package/internal/utils/log.d.mts.map +1 -1
  115. package/internal/utils/log.d.ts +0 -1
  116. package/internal/utils/log.d.ts.map +1 -1
  117. package/internal/utils/log.js +2 -2
  118. package/internal/utils/log.js.map +1 -1
  119. package/internal/utils/log.mjs.map +1 -1
  120. package/internal/utils/path.d.mts.map +1 -1
  121. package/internal/utils/path.d.ts.map +1 -1
  122. package/internal/utils/path.js +2 -2
  123. package/internal/utils/path.js.map +1 -1
  124. package/internal/utils/path.mjs.map +1 -1
  125. package/internal/utils/sleep.d.mts.map +1 -1
  126. package/internal/utils/sleep.d.ts.map +1 -1
  127. package/internal/utils/uuid.d.mts +1 -1
  128. package/internal/utils/uuid.d.mts.map +1 -1
  129. package/internal/utils/uuid.d.ts +1 -1
  130. package/internal/utils/uuid.d.ts.map +1 -1
  131. package/internal/utils/uuid.js +1 -2
  132. package/internal/utils/uuid.js.map +1 -1
  133. package/internal/utils/uuid.mjs +1 -2
  134. package/internal/utils/uuid.mjs.map +1 -1
  135. package/internal/utils/values.d.mts.map +1 -1
  136. package/internal/utils/values.d.ts.map +1 -1
  137. package/internal/utils/values.js +5 -5
  138. package/internal/utils/values.js.map +1 -1
  139. package/internal/utils/values.mjs.map +1 -1
  140. package/internal/utils.js +7 -20
  141. package/internal/utils.js.map +1 -1
  142. package/lib/index.js +3 -16
  143. package/lib/index.js.map +1 -1
  144. package/lib/tokenSigner.js +5 -28
  145. package/lib/tokenSigner.js.map +1 -1
  146. package/lib/tokenSigner.mjs.map +1 -1
  147. package/lib/userTokens.js +1 -1
  148. package/lib/userTokens.js.map +1 -1
  149. package/package.json +2 -6
  150. package/pagination.js +2 -15
  151. package/pagination.js.map +1 -1
  152. package/resource.js +2 -15
  153. package/resource.js.map +1 -1
  154. package/resources/audiences.d.mts +37 -0
  155. package/resources/audiences.d.mts.map +1 -1
  156. package/resources/audiences.d.ts +37 -0
  157. package/resources/audiences.d.ts.map +1 -1
  158. package/resources/audiences.js +25 -0
  159. package/resources/audiences.js.map +1 -1
  160. package/resources/audiences.mjs +25 -0
  161. package/resources/audiences.mjs.map +1 -1
  162. package/resources/bulk-operations.d.mts +7 -0
  163. package/resources/bulk-operations.d.mts.map +1 -1
  164. package/resources/bulk-operations.d.ts +7 -0
  165. package/resources/bulk-operations.d.ts.map +1 -1
  166. package/resources/bulk-operations.js +7 -0
  167. package/resources/bulk-operations.js.map +1 -1
  168. package/resources/bulk-operations.mjs +7 -0
  169. package/resources/bulk-operations.mjs.map +1 -1
  170. package/resources/channels/bulk.d.mts +21 -0
  171. package/resources/channels/bulk.d.mts.map +1 -1
  172. package/resources/channels/bulk.d.ts +21 -0
  173. package/resources/channels/bulk.d.ts.map +1 -1
  174. package/resources/channels/bulk.js +21 -0
  175. package/resources/channels/bulk.js.map +1 -1
  176. package/resources/channels/bulk.mjs +21 -0
  177. package/resources/channels/bulk.mjs.map +1 -1
  178. package/resources/channels/channels.js +2 -24
  179. package/resources/channels/channels.js.map +1 -1
  180. package/resources/channels.js +2 -15
  181. package/resources/channels.js.map +1 -1
  182. package/resources/integrations/integrations.js +3 -25
  183. package/resources/integrations/integrations.js.map +1 -1
  184. package/resources/integrations.js +2 -15
  185. package/resources/integrations.js.map +1 -1
  186. package/resources/messages/batch.d.mts +76 -0
  187. package/resources/messages/batch.d.mts.map +1 -1
  188. package/resources/messages/batch.d.ts +76 -0
  189. package/resources/messages/batch.d.ts.map +1 -1
  190. package/resources/messages/batch.js +76 -0
  191. package/resources/messages/batch.js.map +1 -1
  192. package/resources/messages/batch.mjs +76 -0
  193. package/resources/messages/batch.mjs.map +1 -1
  194. package/resources/messages/index.d.mts +0 -1
  195. package/resources/messages/index.d.mts.map +1 -1
  196. package/resources/messages/index.d.ts +0 -1
  197. package/resources/messages/index.d.ts.map +1 -1
  198. package/resources/messages/index.js +1 -3
  199. package/resources/messages/index.js.map +1 -1
  200. package/resources/messages/index.mjs +0 -1
  201. package/resources/messages/index.mjs.map +1 -1
  202. package/resources/messages/messages.d.mts +101 -4
  203. package/resources/messages/messages.d.mts.map +1 -1
  204. package/resources/messages/messages.d.ts +101 -4
  205. package/resources/messages/messages.d.ts.map +1 -1
  206. package/resources/messages/messages.js +103 -28
  207. package/resources/messages/messages.js.map +1 -1
  208. package/resources/messages/messages.mjs +101 -4
  209. package/resources/messages/messages.mjs.map +1 -1
  210. package/resources/messages.js +2 -15
  211. package/resources/messages.js.map +1 -1
  212. package/resources/objects/bulk.d.mts +49 -0
  213. package/resources/objects/bulk.d.mts.map +1 -1
  214. package/resources/objects/bulk.d.ts +49 -0
  215. package/resources/objects/bulk.d.ts.map +1 -1
  216. package/resources/objects/bulk.js +49 -0
  217. package/resources/objects/bulk.js.map +1 -1
  218. package/resources/objects/bulk.mjs +49 -0
  219. package/resources/objects/bulk.mjs.map +1 -1
  220. package/resources/objects/objects.d.mts +179 -5
  221. package/resources/objects/objects.d.mts.map +1 -1
  222. package/resources/objects/objects.d.ts +179 -5
  223. package/resources/objects/objects.d.ts.map +1 -1
  224. package/resources/objects/objects.js +173 -24
  225. package/resources/objects/objects.js.map +1 -1
  226. package/resources/objects/objects.mjs +171 -0
  227. package/resources/objects/objects.mjs.map +1 -1
  228. package/resources/objects.js +2 -15
  229. package/resources/objects.js.map +1 -1
  230. package/resources/providers/ms-teams.d.mts +40 -0
  231. package/resources/providers/ms-teams.d.mts.map +1 -1
  232. package/resources/providers/ms-teams.d.ts +40 -0
  233. package/resources/providers/ms-teams.d.ts.map +1 -1
  234. package/resources/providers/ms-teams.js +40 -0
  235. package/resources/providers/ms-teams.js.map +1 -1
  236. package/resources/providers/ms-teams.mjs +40 -0
  237. package/resources/providers/ms-teams.mjs.map +1 -1
  238. package/resources/providers/providers.js +3 -25
  239. package/resources/providers/providers.js.map +1 -1
  240. package/resources/providers/slack.d.mts +27 -0
  241. package/resources/providers/slack.d.mts.map +1 -1
  242. package/resources/providers/slack.d.ts +27 -0
  243. package/resources/providers/slack.d.ts.map +1 -1
  244. package/resources/providers/slack.js +27 -0
  245. package/resources/providers/slack.js.map +1 -1
  246. package/resources/providers/slack.mjs +27 -0
  247. package/resources/providers/slack.mjs.map +1 -1
  248. package/resources/providers.js +2 -15
  249. package/resources/providers.js.map +1 -1
  250. package/resources/recipients/channel-data.d.mts +1 -1
  251. package/resources/recipients/channel-data.d.mts.map +1 -1
  252. package/resources/recipients/channel-data.d.ts +1 -1
  253. package/resources/recipients/channel-data.d.ts.map +1 -1
  254. package/resources/recipients/recipients.js +4 -26
  255. package/resources/recipients/recipients.js.map +1 -1
  256. package/resources/recipients.js +2 -15
  257. package/resources/recipients.js.map +1 -1
  258. package/resources/schedules/bulk.d.mts +30 -0
  259. package/resources/schedules/bulk.d.mts.map +1 -1
  260. package/resources/schedules/bulk.d.ts +30 -0
  261. package/resources/schedules/bulk.d.ts.map +1 -1
  262. package/resources/schedules/bulk.js +30 -0
  263. package/resources/schedules/bulk.js.map +1 -1
  264. package/resources/schedules/bulk.mjs +30 -0
  265. package/resources/schedules/bulk.mjs.map +1 -1
  266. package/resources/schedules/schedules.d.mts +75 -2
  267. package/resources/schedules/schedules.d.mts.map +1 -1
  268. package/resources/schedules/schedules.d.ts +75 -2
  269. package/resources/schedules/schedules.d.ts.map +1 -1
  270. package/resources/schedules/schedules.js +76 -24
  271. package/resources/schedules/schedules.js.map +1 -1
  272. package/resources/schedules/schedules.mjs +74 -0
  273. package/resources/schedules/schedules.mjs.map +1 -1
  274. package/resources/schedules.js +2 -15
  275. package/resources/schedules.js.map +1 -1
  276. package/resources/tenants/bulk.d.mts +14 -0
  277. package/resources/tenants/bulk.d.mts.map +1 -1
  278. package/resources/tenants/bulk.d.ts +14 -0
  279. package/resources/tenants/bulk.d.ts.map +1 -1
  280. package/resources/tenants/bulk.js +14 -0
  281. package/resources/tenants/bulk.js.map +1 -1
  282. package/resources/tenants/bulk.mjs +14 -0
  283. package/resources/tenants/bulk.mjs.map +1 -1
  284. package/resources/tenants/tenants.d.mts +33 -0
  285. package/resources/tenants/tenants.d.mts.map +1 -1
  286. package/resources/tenants/tenants.d.ts +33 -0
  287. package/resources/tenants/tenants.d.ts.map +1 -1
  288. package/resources/tenants/tenants.js +35 -24
  289. package/resources/tenants/tenants.js.map +1 -1
  290. package/resources/tenants/tenants.mjs +33 -0
  291. package/resources/tenants/tenants.mjs.map +1 -1
  292. package/resources/tenants.js +2 -15
  293. package/resources/tenants.js.map +1 -1
  294. package/resources/users/bulk.d.mts +41 -0
  295. package/resources/users/bulk.d.mts.map +1 -1
  296. package/resources/users/bulk.d.ts +41 -0
  297. package/resources/users/bulk.d.ts.map +1 -1
  298. package/resources/users/bulk.js +41 -0
  299. package/resources/users/bulk.js.map +1 -1
  300. package/resources/users/bulk.mjs +41 -0
  301. package/resources/users/bulk.mjs.map +1 -1
  302. package/resources/users/feeds.d.mts +19 -0
  303. package/resources/users/feeds.d.mts.map +1 -1
  304. package/resources/users/feeds.d.ts +19 -0
  305. package/resources/users/feeds.d.ts.map +1 -1
  306. package/resources/users/feeds.js +19 -0
  307. package/resources/users/feeds.js.map +1 -1
  308. package/resources/users/feeds.mjs +19 -0
  309. package/resources/users/feeds.mjs.map +1 -1
  310. package/resources/users/guides.d.mts +68 -0
  311. package/resources/users/guides.d.mts.map +1 -1
  312. package/resources/users/guides.d.ts +68 -0
  313. package/resources/users/guides.d.ts.map +1 -1
  314. package/resources/users/guides.js +68 -0
  315. package/resources/users/guides.js.map +1 -1
  316. package/resources/users/guides.mjs +68 -0
  317. package/resources/users/guides.mjs.map +1 -1
  318. package/resources/users/users.d.mts +182 -15
  319. package/resources/users/users.d.mts.map +1 -1
  320. package/resources/users/users.d.ts +182 -15
  321. package/resources/users/users.d.ts.map +1 -1
  322. package/resources/users/users.js +143 -26
  323. package/resources/users/users.js.map +1 -1
  324. package/resources/users/users.mjs +139 -0
  325. package/resources/users/users.mjs.map +1 -1
  326. package/resources/users.js +2 -15
  327. package/resources/users.js.map +1 -1
  328. package/resources/workflows.d.mts +30 -0
  329. package/resources/workflows.d.mts.map +1 -1
  330. package/resources/workflows.d.ts +30 -0
  331. package/resources/workflows.d.ts.map +1 -1
  332. package/resources/workflows.js +30 -0
  333. package/resources/workflows.js.map +1 -1
  334. package/resources/workflows.mjs +30 -0
  335. package/resources/workflows.mjs.map +1 -1
  336. package/resources.js +2 -15
  337. package/resources.js.map +1 -1
  338. package/src/client.ts +17 -0
  339. package/src/internal/headers.ts +1 -1
  340. package/src/internal/to-file.ts +4 -2
  341. package/src/internal/uploads.ts +16 -4
  342. package/src/internal/utils/uuid.ts +1 -3
  343. package/src/resources/audiences.ts +37 -0
  344. package/src/resources/bulk-operations.ts +7 -0
  345. package/src/resources/channels/bulk.ts +21 -0
  346. package/src/resources/messages/batch.ts +76 -0
  347. package/src/resources/messages/index.ts +0 -1
  348. package/src/resources/messages/messages.ts +101 -6
  349. package/src/resources/objects/bulk.ts +49 -0
  350. package/src/resources/objects/objects.ts +179 -5
  351. package/src/resources/providers/ms-teams.ts +40 -0
  352. package/src/resources/providers/slack.ts +27 -0
  353. package/src/resources/recipients/channel-data.ts +4 -1
  354. package/src/resources/schedules/bulk.ts +30 -0
  355. package/src/resources/schedules/schedules.ts +75 -2
  356. package/src/resources/tenants/bulk.ts +14 -0
  357. package/src/resources/tenants/tenants.ts +33 -0
  358. package/src/resources/users/bulk.ts +41 -0
  359. package/src/resources/users/feeds.ts +19 -0
  360. package/src/resources/users/guides.ts +68 -0
  361. package/src/resources/users/users.ts +188 -15
  362. package/src/resources/workflows.ts +30 -0
  363. package/src/version.ts +1 -1
  364. package/uploads.js +2 -15
  365. package/uploads.js.map +1 -1
  366. package/version.d.mts +1 -1
  367. package/version.d.ts +1 -1
  368. package/version.js +1 -1
  369. package/version.mjs +1 -1
  370. package/internal/shims/crypto.d.mts +0 -13
  371. package/internal/shims/crypto.d.mts.map +0 -1
  372. package/internal/shims/crypto.d.ts +0 -13
  373. package/internal/shims/crypto.d.ts.map +0 -1
  374. package/internal/shims/crypto.js +0 -13
  375. package/internal/shims/crypto.js.map +0 -1
  376. package/internal/shims/crypto.mjs +0 -9
  377. package/internal/shims/crypto.mjs.map +0 -1
  378. package/internal/shims/file.d.mts +0 -23
  379. package/internal/shims/file.d.mts.map +0 -1
  380. package/internal/shims/file.d.ts +0 -23
  381. package/internal/shims/file.d.ts.map +0 -1
  382. package/internal/shims/file.js +0 -16
  383. package/internal/shims/file.js.map +0 -1
  384. package/internal/shims/file.mjs +0 -12
  385. package/internal/shims/file.mjs.map +0 -1
  386. package/internal/shims/getBuiltinModule.d.mts +0 -11
  387. package/internal/shims/getBuiltinModule.d.mts.map +0 -1
  388. package/internal/shims/getBuiltinModule.d.ts +0 -11
  389. package/internal/shims/getBuiltinModule.d.ts.map +0 -1
  390. package/internal/shims/getBuiltinModule.js +0 -71
  391. package/internal/shims/getBuiltinModule.js.map +0 -1
  392. package/internal/shims/getBuiltinModule.mjs +0 -67
  393. package/internal/shims/getBuiltinModule.mjs.map +0 -1
  394. package/internal/shims/nullGetBuiltinModule.d.mts +0 -2
  395. package/internal/shims/nullGetBuiltinModule.d.mts.map +0 -1
  396. package/internal/shims/nullGetBuiltinModule.d.ts +0 -2
  397. package/internal/shims/nullGetBuiltinModule.d.ts.map +0 -1
  398. package/internal/shims/nullGetBuiltinModule.js +0 -5
  399. package/internal/shims/nullGetBuiltinModule.js.map +0 -1
  400. package/internal/shims/nullGetBuiltinModule.mjs +0 -2
  401. package/internal/shims/nullGetBuiltinModule.mjs.map +0 -1
  402. package/resources/messages/activities.d.mts +0 -22
  403. package/resources/messages/activities.d.mts.map +0 -1
  404. package/resources/messages/activities.d.ts +0 -22
  405. package/resources/messages/activities.d.ts.map +0 -1
  406. package/resources/messages/activities.js +0 -17
  407. package/resources/messages/activities.js.map +0 -1
  408. package/resources/messages/activities.mjs +0 -13
  409. package/resources/messages/activities.mjs.map +0 -1
  410. package/src/internal/shims/crypto.ts +0 -18
  411. package/src/internal/shims/file.ts +0 -32
  412. package/src/internal/shims/getBuiltinModule.ts +0 -66
  413. package/src/internal/shims/nullGetBuiltinModule.ts +0 -1
  414. package/src/resources/messages/activities.ts +0 -38
@@ -1,8 +1,6 @@
1
1
  // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
2
 
3
3
  import { APIResource } from '../../core/resource';
4
- import * as ActivitiesAPI from './activities';
5
- import { Activities, ActivityListParams } from './activities';
6
4
  import * as BatchAPI from './batch';
7
5
  import {
8
6
  Batch,
@@ -37,10 +35,17 @@ import { path } from '../../internal/utils/path';
37
35
 
38
36
  export class Messages extends APIResource {
39
37
  batch: BatchAPI.Batch = new BatchAPI.Batch(this._client);
40
- activities: ActivitiesAPI.Activities = new ActivitiesAPI.Activities(this._client);
41
38
 
42
39
  /**
43
40
  * Returns a paginated list of messages for the current environment.
41
+ *
42
+ * @example
43
+ * ```ts
44
+ * // Automatically fetches more pages as needed.
45
+ * for await (const message of client.messages.list()) {
46
+ * // ...
47
+ * }
48
+ * ```
44
49
  */
45
50
  list(
46
51
  query: MessageListParams | null | undefined = {},
@@ -52,6 +57,13 @@ export class Messages extends APIResource {
52
57
  /**
53
58
  * Archives a message for the user. Archived messages are hidden from the default
54
59
  * message list in the feed but can still be accessed and unarchived later.
60
+ *
61
+ * @example
62
+ * ```ts
63
+ * const message = await client.messages.archive(
64
+ * '1jNaXzB2RZX3LY8wVQnfCKyPnv7',
65
+ * );
66
+ * ```
55
67
  */
56
68
  archive(messageID: string, options?: RequestOptions): APIPromise<Message> {
57
69
  return this._client.put(path`/v1/messages/${messageID}/archived`, options);
@@ -59,6 +71,13 @@ export class Messages extends APIResource {
59
71
 
60
72
  /**
61
73
  * Retrieves a specific message by its ID.
74
+ *
75
+ * @example
76
+ * ```ts
77
+ * const message = await client.messages.get(
78
+ * '1jNaXzB2RZX3LY8wVQnfCKyPnv7',
79
+ * );
80
+ * ```
62
81
  */
63
82
  get(messageID: string, options?: RequestOptions): APIPromise<Message> {
64
83
  return this._client.get(path`/v1/messages/${messageID}`, options);
@@ -67,6 +86,13 @@ export class Messages extends APIResource {
67
86
  /**
68
87
  * Returns the fully rendered contents of a message, where the response depends on
69
88
  * which channel the message was sent through.
89
+ *
90
+ * @example
91
+ * ```ts
92
+ * const response = await client.messages.getContent(
93
+ * 'message_id',
94
+ * );
95
+ * ```
70
96
  */
71
97
  getContent(messageID: string, options?: RequestOptions): APIPromise<MessageGetContentResponse> {
72
98
  return this._client.get(path`/v1/messages/${messageID}/content`, options);
@@ -74,6 +100,16 @@ export class Messages extends APIResource {
74
100
 
75
101
  /**
76
102
  * Returns a paginated list of activities for the specified message.
103
+ *
104
+ * @example
105
+ * ```ts
106
+ * // Automatically fetches more pages as needed.
107
+ * for await (const activity of client.messages.listActivities(
108
+ * 'message_id',
109
+ * )) {
110
+ * // ...
111
+ * }
112
+ * ```
77
113
  */
78
114
  listActivities(
79
115
  messageID: string,
@@ -88,6 +124,16 @@ export class Messages extends APIResource {
88
124
 
89
125
  /**
90
126
  * Returns a paginated list of delivery logs for the specified message.
127
+ *
128
+ * @example
129
+ * ```ts
130
+ * // Automatically fetches more pages as needed.
131
+ * for await (const messageDeliveryLog of client.messages.listDeliveryLogs(
132
+ * 'message_id',
133
+ * )) {
134
+ * // ...
135
+ * }
136
+ * ```
91
137
  */
92
138
  listDeliveryLogs(
93
139
  messageID: string,
@@ -103,6 +149,16 @@ export class Messages extends APIResource {
103
149
 
104
150
  /**
105
151
  * Returns a paginated list of events for the specified message.
152
+ *
153
+ * @example
154
+ * ```ts
155
+ * // Automatically fetches more pages as needed.
156
+ * for await (const messageEvent of client.messages.listEvents(
157
+ * 'message_id',
158
+ * )) {
159
+ * // ...
160
+ * }
161
+ * ```
106
162
  */
107
163
  listEvents(
108
164
  messageID: string,
@@ -121,6 +177,13 @@ export class Messages extends APIResource {
121
177
  * Cannot include more than 5 key-value pairs, must not contain nested data. Read
122
178
  * more about message engagement statuses
123
179
  * [here](/send-notifications/message-statuses#engagement-status).
180
+ *
181
+ * @example
182
+ * ```ts
183
+ * const message = await client.messages.markAsInteracted(
184
+ * '1jNaXzB2RZX3LY8wVQnfCKyPnv7',
185
+ * );
186
+ * ```
124
187
  */
125
188
  markAsInteracted(
126
189
  messageID: string,
@@ -134,6 +197,13 @@ export class Messages extends APIResource {
134
197
  * Marks a message as `read`. This indicates that the user has read the message
135
198
  * content. Read more about message engagement statuses
136
199
  * [here](/send-notifications/message-statuses#engagement-status).
200
+ *
201
+ * @example
202
+ * ```ts
203
+ * const message = await client.messages.markAsRead(
204
+ * '1jNaXzB2RZX3LY8wVQnfCKyPnv7',
205
+ * );
206
+ * ```
137
207
  */
138
208
  markAsRead(messageID: string, options?: RequestOptions): APIPromise<Message> {
139
209
  return this._client.put(path`/v1/messages/${messageID}/read`, options);
@@ -143,6 +213,13 @@ export class Messages extends APIResource {
143
213
  * Marks a message as `seen`. This indicates that the user has viewed the message
144
214
  * in their feed or inbox. Read more about message engagement statuses
145
215
  * [here](/send-notifications/message-statuses#engagement-status).
216
+ *
217
+ * @example
218
+ * ```ts
219
+ * const message = await client.messages.markAsSeen(
220
+ * '1jNaXzB2RZX3LY8wVQnfCKyPnv7',
221
+ * );
222
+ * ```
146
223
  */
147
224
  markAsSeen(messageID: string, options?: RequestOptions): APIPromise<Message> {
148
225
  return this._client.put(path`/v1/messages/${messageID}/seen`, options);
@@ -152,6 +229,13 @@ export class Messages extends APIResource {
152
229
  * Marks a message as `unread`. This reverses the `read` state. Read more about
153
230
  * message engagement statuses
154
231
  * [here](/send-notifications/message-statuses#engagement-status).
232
+ *
233
+ * @example
234
+ * ```ts
235
+ * const message = await client.messages.markAsUnread(
236
+ * '1jNaXzB2RZX3LY8wVQnfCKyPnv7',
237
+ * );
238
+ * ```
155
239
  */
156
240
  markAsUnread(messageID: string, options?: RequestOptions): APIPromise<Message> {
157
241
  return this._client.delete(path`/v1/messages/${messageID}/read`, options);
@@ -161,6 +245,13 @@ export class Messages extends APIResource {
161
245
  * Marks a message as `unseen`. This reverses the `seen` state. Read more about
162
246
  * message engagement statuses
163
247
  * [here](/send-notifications/message-statuses#engagement-status).
248
+ *
249
+ * @example
250
+ * ```ts
251
+ * const message = await client.messages.markAsUnseen(
252
+ * '1jNaXzB2RZX3LY8wVQnfCKyPnv7',
253
+ * );
254
+ * ```
164
255
  */
165
256
  markAsUnseen(messageID: string, options?: RequestOptions): APIPromise<Message> {
166
257
  return this._client.delete(path`/v1/messages/${messageID}/seen`, options);
@@ -169,6 +260,13 @@ export class Messages extends APIResource {
169
260
  /**
170
261
  * Removes a message from the archived state, making it visible in the default
171
262
  * message list in the feed again.
263
+ *
264
+ * @example
265
+ * ```ts
266
+ * const message = await client.messages.unarchive(
267
+ * '1jNaXzB2RZX3LY8wVQnfCKyPnv7',
268
+ * );
269
+ * ```
172
270
  */
173
271
  unarchive(messageID: string, options?: RequestOptions): APIPromise<Message> {
174
272
  return this._client.delete(path`/v1/messages/${messageID}/archived`, options);
@@ -910,7 +1008,6 @@ export interface MessageMarkAsInteractedParams {
910
1008
  }
911
1009
 
912
1010
  Messages.Batch = Batch;
913
- Messages.Activities = Activities;
914
1011
 
915
1012
  export declare namespace Messages {
916
1013
  export {
@@ -949,6 +1046,4 @@ export declare namespace Messages {
949
1046
  type BatchMarkAsUnseenParams as BatchMarkAsUnseenParams,
950
1047
  type BatchUnarchiveParams as BatchUnarchiveParams,
951
1048
  };
952
-
953
- export { Activities as Activities, type ActivityListParams as ActivityListParams };
954
1049
  }
@@ -11,6 +11,14 @@ import { path } from '../../internal/utils/path';
11
11
  export class Bulk extends APIResource {
12
12
  /**
13
13
  * Bulk deletes objects from the specified collection.
14
+ *
15
+ * @example
16
+ * ```ts
17
+ * const bulkOperation = await client.objects.bulk.delete(
18
+ * 'collection',
19
+ * { object_ids: ['obj_123', 'obj_456', 'obj_789'] },
20
+ * );
21
+ * ```
14
22
  */
15
23
  delete(
16
24
  collection: string,
@@ -26,6 +34,20 @@ export class Bulk extends APIResource {
26
34
  * also handles
27
35
  * [inline identifications](/managing-recipients/identifying-recipients#inline-identifying-recipients)
28
36
  * for the `recipient` field.
37
+ *
38
+ * @example
39
+ * ```ts
40
+ * const bulkOperation =
41
+ * await client.objects.bulk.addSubscriptions('projects', {
42
+ * subscriptions: [
43
+ * {
44
+ * id: 'project-1',
45
+ * properties: null,
46
+ * recipients: [{ id: 'user_1' }],
47
+ * },
48
+ * ],
49
+ * });
50
+ * ```
29
51
  */
30
52
  addSubscriptions(
31
53
  collection: string,
@@ -37,6 +59,33 @@ export class Bulk extends APIResource {
37
59
 
38
60
  /**
39
61
  * Bulk sets up to 1,000 objects at a time in the specified collection.
62
+ *
63
+ * @example
64
+ * ```ts
65
+ * const bulkOperation = await client.objects.bulk.set(
66
+ * 'collection',
67
+ * {
68
+ * objects: [
69
+ * {
70
+ * collection: 'projects',
71
+ * id: 'project_1',
72
+ * name: {
73
+ * '0': 'M',
74
+ * '1': 'y',
75
+ * '2': ' ',
76
+ * '3': 'p',
77
+ * '4': 'r',
78
+ * '5': 'o',
79
+ * '6': 'j',
80
+ * '7': 'e',
81
+ * '8': 'c',
82
+ * '9': 't',
83
+ * },
84
+ * },
85
+ * ],
86
+ * },
87
+ * );
88
+ * ```
40
89
  */
41
90
  set(
42
91
  collection: string,
@@ -24,6 +24,16 @@ export class Objects extends APIResource {
24
24
  /**
25
25
  * Returns a paginated list of objects from the specified collection. Optionally
26
26
  * includes preference data for the objects.
27
+ *
28
+ * @example
29
+ * ```ts
30
+ * // Automatically fetches more pages as needed.
31
+ * for await (const object of client.objects.list(
32
+ * 'collection',
33
+ * )) {
34
+ * // ...
35
+ * }
36
+ * ```
27
37
  */
28
38
  list(
29
39
  collection: string,
@@ -39,6 +49,14 @@ export class Objects extends APIResource {
39
49
  /**
40
50
  * Permanently removes an object from the specified collection. This operation
41
51
  * cannot be undone.
52
+ *
53
+ * @example
54
+ * ```ts
55
+ * const object = await client.objects.delete(
56
+ * 'collection',
57
+ * 'id',
58
+ * );
59
+ * ```
42
60
  */
43
61
  delete(collection: string, id: string, options?: RequestOptions): APIPromise<string> {
44
62
  return this._client.delete(path`/v1/objects/${collection}/${id}`, options);
@@ -49,6 +67,18 @@ export class Objects extends APIResource {
49
67
  * updated. This endpoint also handles
50
68
  * [inline identifications](/managing-recipients/identifying-recipients#inline-identifying-recipients)
51
69
  * for the `recipient`.
70
+ *
71
+ * @example
72
+ * ```ts
73
+ * const subscriptions = await client.objects.addSubscriptions(
74
+ * 'collection',
75
+ * 'object_id',
76
+ * {
77
+ * recipients: ['user_1', 'user_2'],
78
+ * properties: { key: 'value' },
79
+ * },
80
+ * );
81
+ * ```
52
82
  */
53
83
  addSubscriptions(
54
84
  collection: string,
@@ -62,6 +92,16 @@ export class Objects extends APIResource {
62
92
  /**
63
93
  * Delete subscriptions for the specified recipients from an object. Returns the
64
94
  * list of deleted subscriptions.
95
+ *
96
+ * @example
97
+ * ```ts
98
+ * const subscriptions =
99
+ * await client.objects.deleteSubscriptions(
100
+ * 'collection',
101
+ * 'object_id',
102
+ * { recipients: ['user_123'] },
103
+ * );
104
+ * ```
65
105
  */
66
106
  deleteSubscriptions(
67
107
  collection: string,
@@ -78,6 +118,11 @@ export class Objects extends APIResource {
78
118
  /**
79
119
  * Retrieves a specific object by its ID from the specified collection. Returns the
80
120
  * object with all its properties.
121
+ *
122
+ * @example
123
+ * ```ts
124
+ * const object = await client.objects.get('collection', 'id');
125
+ * ```
81
126
  */
82
127
  get(collection: string, id: string, options?: RequestOptions): APIPromise<Object> {
83
128
  return this._client.get(path`/v1/objects/${collection}/${id}`, options);
@@ -85,6 +130,15 @@ export class Objects extends APIResource {
85
130
 
86
131
  /**
87
132
  * Returns the channel data for the specified object and channel.
133
+ *
134
+ * @example
135
+ * ```ts
136
+ * const channelData = await client.objects.getChannelData(
137
+ * 'collection',
138
+ * 'object_id',
139
+ * '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e',
140
+ * );
141
+ * ```
88
142
  */
89
143
  getChannelData(
90
144
  collection: string,
@@ -97,6 +151,15 @@ export class Objects extends APIResource {
97
151
 
98
152
  /**
99
153
  * Returns the preference set for the specified object and preference set `id`.
154
+ *
155
+ * @example
156
+ * ```ts
157
+ * const preferenceSet = await client.objects.getPreferences(
158
+ * 'collection',
159
+ * 'object_id',
160
+ * 'default',
161
+ * );
162
+ * ```
100
163
  */
101
164
  getPreferences(
102
165
  collection: string,
@@ -111,6 +174,17 @@ export class Objects extends APIResource {
111
174
  * Returns a paginated list of messages for a specific object in the given
112
175
  * collection. Allows filtering by message status and provides various sorting
113
176
  * options.
177
+ *
178
+ * @example
179
+ * ```ts
180
+ * // Automatically fetches more pages as needed.
181
+ * for await (const message of client.objects.listMessages(
182
+ * 'projects',
183
+ * 'project-123',
184
+ * )) {
185
+ * // ...
186
+ * }
187
+ * ```
114
188
  */
115
189
  listMessages(
116
190
  collection: string,
@@ -127,6 +201,14 @@ export class Objects extends APIResource {
127
201
 
128
202
  /**
129
203
  * Returns a paginated list of preference sets for the specified object.
204
+ *
205
+ * @example
206
+ * ```ts
207
+ * const preferenceSets = await client.objects.listPreferences(
208
+ * 'collection',
209
+ * 'object_id',
210
+ * );
211
+ * ```
130
212
  */
131
213
  listPreferences(
132
214
  collection: string,
@@ -138,6 +220,17 @@ export class Objects extends APIResource {
138
220
 
139
221
  /**
140
222
  * Returns a paginated list of schedules for an object.
223
+ *
224
+ * @example
225
+ * ```ts
226
+ * // Automatically fetches more pages as needed.
227
+ * for await (const schedule of client.objects.listSchedules(
228
+ * 'collection',
229
+ * 'id',
230
+ * )) {
231
+ * // ...
232
+ * }
233
+ * ```
141
234
  */
142
235
  listSchedules(
143
236
  collection: string,
@@ -156,6 +249,17 @@ export class Objects extends APIResource {
156
249
  * List subscriptions for an object. Either list the recipients that subscribe to
157
250
  * the provided object, or list the objects that the provided object is subscribed
158
251
  * to. Determined by the `mode` query parameter.
252
+ *
253
+ * @example
254
+ * ```ts
255
+ * // Automatically fetches more pages as needed.
256
+ * for await (const subscription of client.objects.listSubscriptions(
257
+ * 'collection',
258
+ * 'object_id',
259
+ * )) {
260
+ * // ...
261
+ * }
262
+ * ```
159
263
  */
160
264
  listSubscriptions(
161
265
  collection: string,
@@ -174,6 +278,33 @@ export class Objects extends APIResource {
174
278
  * Creates a new object or updates an existing one in the specified collection.
175
279
  * This operation is used to identify objects with their properties, as well as
176
280
  * optional preferences and channel data.
281
+ *
282
+ * @example
283
+ * ```ts
284
+ * const object = await client.objects.set(
285
+ * 'collection',
286
+ * 'id',
287
+ * {
288
+ * channel_data: {
289
+ * '97c5837d-c65c-4d54-aa39-080eeb81c69d': {
290
+ * tokens: ['push_token_123'],
291
+ * },
292
+ * },
293
+ * locale: 'en-US',
294
+ * preferences: {
295
+ * default: {
296
+ * channel_types: { email: true },
297
+ * workflows: {
298
+ * 'dinosaurs-loose': {
299
+ * channel_types: { email: true },
300
+ * },
301
+ * },
302
+ * },
303
+ * },
304
+ * timezone: 'America/New_York',
305
+ * },
306
+ * );
307
+ * ```
177
308
  */
178
309
  set(collection: string, id: string, body: ObjectSetParams, options?: RequestOptions): APIPromise<Object> {
179
310
  return this._client.put(path`/v1/objects/${collection}/${id}`, { body, ...options });
@@ -183,6 +314,16 @@ export class Objects extends APIResource {
183
314
  * Sets the channel data for the specified object and channel. If no object exists
184
315
  * in the current environment for the given `collection` and `object_id`, Knock
185
316
  * will create the object as part of this request.
317
+ *
318
+ * @example
319
+ * ```ts
320
+ * const channelData = await client.objects.setChannelData(
321
+ * 'collection',
322
+ * 'object_id',
323
+ * '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e',
324
+ * { data: { tokens: ['push_token_1'] } },
325
+ * );
326
+ * ```
186
327
  */
187
328
  setChannelData(
188
329
  collection: string,
@@ -204,6 +345,27 @@ export class Objects extends APIResource {
204
345
  * `:object_id`, Knock will create the object as part of this request. The
205
346
  * preference set `:id` can be either `default` or a `tenant.id`. Learn more about
206
347
  * [per-tenant preferences](/preferences/tenant-preferences).
348
+ *
349
+ * @example
350
+ * ```ts
351
+ * const preferenceSet = await client.objects.setPreferences(
352
+ * 'collection',
353
+ * 'object_id',
354
+ * 'default',
355
+ * {
356
+ * categories: {
357
+ * marketing: false,
358
+ * transactional: { channel_types: { email: false } },
359
+ * },
360
+ * channel_types: { email: true },
361
+ * workflows: {
362
+ * 'dinosaurs-loose': {
363
+ * channel_types: { email: false },
364
+ * },
365
+ * },
366
+ * },
367
+ * );
368
+ * ```
207
369
  */
208
370
  setPreferences(
209
371
  collection: string,
@@ -220,6 +382,15 @@ export class Objects extends APIResource {
220
382
 
221
383
  /**
222
384
  * Unsets the channel data for the specified object and channel.
385
+ *
386
+ * @example
387
+ * ```ts
388
+ * const response = await client.objects.unsetChannelData(
389
+ * 'collection',
390
+ * 'object_id',
391
+ * '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e',
392
+ * );
393
+ * ```
223
394
  */
224
395
  unsetChannelData(
225
396
  collection: string,
@@ -297,7 +468,10 @@ export interface Object {
297
468
  */
298
469
  created_at?: string | null;
299
470
 
300
- [k: string]: unknown;
471
+ /**
472
+ * The custom properties associated with the object.
473
+ */
474
+ properties?: Record<string, unknown>;
301
475
  }
302
476
 
303
477
  /**
@@ -508,10 +682,10 @@ export interface ObjectSetParams {
508
682
  preferences?: PreferencesAPI.InlinePreferenceSetRequest;
509
683
 
510
684
  /**
511
- * The timezone of the object. Must be a valid
512
- * [tz database time zone string](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones).
513
- * Used for
514
- * [recurring schedules](/concepts/schedules#scheduling-workflows-with-recurring-schedules-for-recipients).
685
+ * The timezone of the object. Must be a
686
+ * valid [tz database time zone string](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones).
687
+ * Used
688
+ * for [recurring schedules](/concepts/schedules#scheduling-workflows-with-recurring-schedules-for-recipients).
515
689
  */
516
690
  timezone?: string | null;
517
691
 
@@ -10,6 +10,14 @@ export class MsTeams extends APIResource {
10
10
  /**
11
11
  * Check if a connection to Microsoft Teams has been authorized for a given
12
12
  * Microsoft Teams tenant object.
13
+ *
14
+ * @example
15
+ * ```ts
16
+ * const response = await client.providers.msTeams.checkAuth(
17
+ * 'channel_id',
18
+ * { ms_teams_tenant_object: 'ms_teams_tenant_object' },
19
+ * );
20
+ * ```
13
21
  */
14
22
  checkAuth(
15
23
  channelID: string,
@@ -22,6 +30,18 @@ export class MsTeams extends APIResource {
22
30
  /**
23
31
  * List the Microsoft Teams channels within a team. By default, archived and
24
32
  * private channels are excluded from the results.
33
+ *
34
+ * @example
35
+ * ```ts
36
+ * const response =
37
+ * await client.providers.msTeams.listChannels(
38
+ * 'channel_id',
39
+ * {
40
+ * ms_teams_tenant_object: 'ms_teams_tenant_object',
41
+ * team_id: 'team_id',
42
+ * },
43
+ * );
44
+ * ```
25
45
  */
26
46
  listChannels(
27
47
  channelID: string,
@@ -34,6 +54,17 @@ export class MsTeams extends APIResource {
34
54
  /**
35
55
  * Get a list of teams belonging to the Microsoft Entra tenant. By default,
36
56
  * archived and private channels are excluded from the results.
57
+ *
58
+ * @example
59
+ * ```ts
60
+ * // Automatically fetches more pages as needed.
61
+ * for await (const msTeamListTeamsResponse of client.providers.msTeams.listTeams(
62
+ * 'channel_id',
63
+ * { ms_teams_tenant_object: 'ms_teams_tenant_object' },
64
+ * )) {
65
+ * // ...
66
+ * }
67
+ * ```
37
68
  */
38
69
  listTeams(
39
70
  channelID: string,
@@ -49,6 +80,15 @@ export class MsTeams extends APIResource {
49
80
 
50
81
  /**
51
82
  * Remove a Microsoft Entra tenant ID from a Microsoft Teams tenant object.
83
+ *
84
+ * @example
85
+ * ```ts
86
+ * const response =
87
+ * await client.providers.msTeams.revokeAccess(
88
+ * 'channel_id',
89
+ * { ms_teams_tenant_object: 'ms_teams_tenant_object' },
90
+ * );
91
+ * ```
52
92
  */
53
93
  revokeAccess(
54
94
  channelID: string,
@@ -9,6 +9,14 @@ import { path } from '../../internal/utils/path';
9
9
  export class Slack extends APIResource {
10
10
  /**
11
11
  * Check if a Slack channel is authenticated.
12
+ *
13
+ * @example
14
+ * ```ts
15
+ * const response = await client.providers.slack.checkAuth(
16
+ * 'channel_id',
17
+ * { access_token_object: 'access_token_object' },
18
+ * );
19
+ * ```
12
20
  */
13
21
  checkAuth(
14
22
  channelID: string,
@@ -20,6 +28,17 @@ export class Slack extends APIResource {
20
28
 
21
29
  /**
22
30
  * List Slack channels for a Slack workspace.
31
+ *
32
+ * @example
33
+ * ```ts
34
+ * // Automatically fetches more pages as needed.
35
+ * for await (const slackListChannelsResponse of client.providers.slack.listChannels(
36
+ * 'channel_id',
37
+ * { access_token_object: 'access_token_object' },
38
+ * )) {
39
+ * // ...
40
+ * }
41
+ * ```
23
42
  */
24
43
  listChannels(
25
44
  channelID: string,
@@ -35,6 +54,14 @@ export class Slack extends APIResource {
35
54
 
36
55
  /**
37
56
  * Revoke access for a Slack channel.
57
+ *
58
+ * @example
59
+ * ```ts
60
+ * const response = await client.providers.slack.revokeAccess(
61
+ * 'channel_id',
62
+ * { access_token_object: 'access_token_object' },
63
+ * );
64
+ * ```
38
65
  */
39
66
  revokeAccess(
40
67
  channelID: string,
@@ -96,7 +96,10 @@ export namespace DiscordChannelData {
96
96
  /**
97
97
  * A request to set channel data for a type of channel inline.
98
98
  */
99
- export type InlineChannelDataRequest = Record<string, ChannelDataRequest>;
99
+ export type InlineChannelDataRequest = Record<
100
+ string,
101
+ PushChannelData | OneSignalChannelData | SlackChannelData | MsTeamsChannelData | DiscordChannelData
102
+ >;
100
103
 
101
104
  /**
102
105
  * Microsoft Teams channel connection.