featurebase-node 0.3.0 → 0.4.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 (288) hide show
  1. package/CHANGELOG.md +9 -0
  2. package/README.md +31 -0
  3. package/client.d.mts +12 -6
  4. package/client.d.mts.map +1 -1
  5. package/client.d.ts +12 -6
  6. package/client.d.ts.map +1 -1
  7. package/client.js +10 -0
  8. package/client.js.map +1 -1
  9. package/client.mjs +10 -0
  10. package/client.mjs.map +1 -1
  11. package/core/pagination.d.mts +54 -0
  12. package/core/pagination.d.mts.map +1 -0
  13. package/core/pagination.d.ts +54 -0
  14. package/core/pagination.d.ts.map +1 -0
  15. package/core/pagination.js +101 -0
  16. package/core/pagination.js.map +1 -0
  17. package/core/pagination.mjs +95 -0
  18. package/core/pagination.mjs.map +1 -0
  19. package/index.d.mts +1 -0
  20. package/index.d.mts.map +1 -1
  21. package/index.d.ts +1 -0
  22. package/index.d.ts.map +1 -1
  23. package/index.js +3 -1
  24. package/index.js.map +1 -1
  25. package/index.mjs +1 -0
  26. package/index.mjs.map +1 -1
  27. package/package.json +11 -1
  28. package/pagination.d.mts +2 -0
  29. package/pagination.d.mts.map +1 -0
  30. package/pagination.d.ts +2 -0
  31. package/pagination.d.ts.map +1 -0
  32. package/pagination.js +6 -0
  33. package/pagination.js.map +1 -0
  34. package/pagination.mjs +2 -0
  35. package/pagination.mjs.map +1 -0
  36. package/resources/changelogs/changelogs.d.mts +9 -53
  37. package/resources/changelogs/changelogs.d.mts.map +1 -1
  38. package/resources/changelogs/changelogs.d.ts +9 -53
  39. package/resources/changelogs/changelogs.d.ts.map +1 -1
  40. package/resources/changelogs/changelogs.js +6 -2
  41. package/resources/changelogs/changelogs.js.map +1 -1
  42. package/resources/changelogs/changelogs.mjs +6 -2
  43. package/resources/changelogs/changelogs.mjs.map +1 -1
  44. package/resources/changelogs/index.d.mts +1 -1
  45. package/resources/changelogs/index.d.mts.map +1 -1
  46. package/resources/changelogs/index.d.ts +1 -1
  47. package/resources/changelogs/index.d.ts.map +1 -1
  48. package/resources/feedback/comments.d.mts +9 -53
  49. package/resources/feedback/comments.d.mts.map +1 -1
  50. package/resources/feedback/comments.d.ts +9 -53
  51. package/resources/feedback/comments.d.ts.map +1 -1
  52. package/resources/feedback/comments.js +6 -2
  53. package/resources/feedback/comments.js.map +1 -1
  54. package/resources/feedback/comments.mjs +6 -2
  55. package/resources/feedback/comments.mjs.map +1 -1
  56. package/resources/feedback/feedback.d.mts +4 -4
  57. package/resources/feedback/feedback.d.mts.map +1 -1
  58. package/resources/feedback/feedback.d.ts +4 -4
  59. package/resources/feedback/feedback.d.ts.map +1 -1
  60. package/resources/feedback/feedback.mjs.map +1 -1
  61. package/resources/feedback/index.d.mts +2 -2
  62. package/resources/feedback/index.d.mts.map +1 -1
  63. package/resources/feedback/index.d.ts +2 -2
  64. package/resources/feedback/index.d.ts.map +1 -1
  65. package/resources/feedback/posts/index.d.mts +2 -2
  66. package/resources/feedback/posts/index.d.mts.map +1 -1
  67. package/resources/feedback/posts/index.d.ts +2 -2
  68. package/resources/feedback/posts/index.d.ts.map +1 -1
  69. package/resources/feedback/posts/index.js.map +1 -1
  70. package/resources/feedback/posts/index.mjs.map +1 -1
  71. package/resources/feedback/posts/posts.d.mts +11 -56
  72. package/resources/feedback/posts/posts.d.mts.map +1 -1
  73. package/resources/feedback/posts/posts.d.ts +11 -56
  74. package/resources/feedback/posts/posts.d.ts.map +1 -1
  75. package/resources/feedback/posts/posts.js +6 -2
  76. package/resources/feedback/posts/posts.js.map +1 -1
  77. package/resources/feedback/posts/posts.mjs +6 -2
  78. package/resources/feedback/posts/posts.mjs.map +1 -1
  79. package/resources/feedback/posts/voters.d.mts +79 -124
  80. package/resources/feedback/posts/voters.d.mts.map +1 -1
  81. package/resources/feedback/posts/voters.d.ts +79 -124
  82. package/resources/feedback/posts/voters.d.ts.map +1 -1
  83. package/resources/feedback/posts/voters.js +7 -3
  84. package/resources/feedback/posts/voters.js.map +1 -1
  85. package/resources/feedback/posts/voters.mjs +7 -3
  86. package/resources/feedback/posts/voters.mjs.map +1 -1
  87. package/resources/help-center/articles.d.mts +9 -27
  88. package/resources/help-center/articles.d.mts.map +1 -1
  89. package/resources/help-center/articles.d.ts +9 -27
  90. package/resources/help-center/articles.d.ts.map +1 -1
  91. package/resources/help-center/articles.js +6 -2
  92. package/resources/help-center/articles.js.map +1 -1
  93. package/resources/help-center/articles.mjs +6 -2
  94. package/resources/help-center/articles.mjs.map +1 -1
  95. package/resources/help-center/collections.d.mts +9 -28
  96. package/resources/help-center/collections.d.mts.map +1 -1
  97. package/resources/help-center/collections.d.ts +9 -28
  98. package/resources/help-center/collections.d.ts.map +1 -1
  99. package/resources/help-center/collections.js +6 -3
  100. package/resources/help-center/collections.js.map +1 -1
  101. package/resources/help-center/collections.mjs +6 -3
  102. package/resources/help-center/collections.mjs.map +1 -1
  103. package/resources/help-center/help-center.d.mts +8 -8
  104. package/resources/help-center/help-center.d.mts.map +1 -1
  105. package/resources/help-center/help-center.d.ts +8 -8
  106. package/resources/help-center/help-center.d.ts.map +1 -1
  107. package/resources/help-center/help-center.mjs.map +1 -1
  108. package/resources/help-center/help-centers.d.mts +9 -28
  109. package/resources/help-center/help-centers.d.mts.map +1 -1
  110. package/resources/help-center/help-centers.d.ts +9 -28
  111. package/resources/help-center/help-centers.d.ts.map +1 -1
  112. package/resources/help-center/help-centers.js +6 -3
  113. package/resources/help-center/help-centers.js.map +1 -1
  114. package/resources/help-center/help-centers.mjs +6 -3
  115. package/resources/help-center/help-centers.mjs.map +1 -1
  116. package/resources/help-center/index.d.mts +4 -4
  117. package/resources/help-center/index.d.mts.map +1 -1
  118. package/resources/help-center/index.d.ts +4 -4
  119. package/resources/help-center/index.d.ts.map +1 -1
  120. package/resources/help-center/redirect-rules.d.mts +9 -28
  121. package/resources/help-center/redirect-rules.d.mts.map +1 -1
  122. package/resources/help-center/redirect-rules.d.ts +9 -28
  123. package/resources/help-center/redirect-rules.d.ts.map +1 -1
  124. package/resources/help-center/redirect-rules.js +6 -3
  125. package/resources/help-center/redirect-rules.js.map +1 -1
  126. package/resources/help-center/redirect-rules.mjs +6 -3
  127. package/resources/help-center/redirect-rules.mjs.map +1 -1
  128. package/resources/index.d.mts +3 -3
  129. package/resources/index.d.mts.map +1 -1
  130. package/resources/index.d.ts +3 -3
  131. package/resources/index.d.ts.map +1 -1
  132. package/resources/index.js.map +1 -1
  133. package/resources/index.mjs.map +1 -1
  134. package/resources/organization/brands.d.mts +5 -26
  135. package/resources/organization/brands.d.mts.map +1 -1
  136. package/resources/organization/brands.d.ts +5 -26
  137. package/resources/organization/brands.d.ts.map +1 -1
  138. package/resources/organization/brands.js +2 -1
  139. package/resources/organization/brands.js.map +1 -1
  140. package/resources/organization/brands.mjs +2 -1
  141. package/resources/organization/brands.mjs.map +1 -1
  142. package/resources/organization/index.d.mts +1 -1
  143. package/resources/organization/index.d.mts.map +1 -1
  144. package/resources/organization/index.d.ts +1 -1
  145. package/resources/organization/index.d.ts.map +1 -1
  146. package/resources/organization/organization.d.mts +2 -2
  147. package/resources/organization/organization.d.mts.map +1 -1
  148. package/resources/organization/organization.d.ts +2 -2
  149. package/resources/organization/organization.d.ts.map +1 -1
  150. package/resources/organization/organization.js.map +1 -1
  151. package/resources/organization/organization.mjs.map +1 -1
  152. package/resources/support/conversations/conversations.d.mts +9 -28
  153. package/resources/support/conversations/conversations.d.mts.map +1 -1
  154. package/resources/support/conversations/conversations.d.ts +9 -28
  155. package/resources/support/conversations/conversations.d.ts.map +1 -1
  156. package/resources/support/conversations/conversations.js +6 -3
  157. package/resources/support/conversations/conversations.js.map +1 -1
  158. package/resources/support/conversations/conversations.mjs +6 -3
  159. package/resources/support/conversations/conversations.mjs.map +1 -1
  160. package/resources/support/conversations/index.d.mts +1 -1
  161. package/resources/support/conversations/index.d.mts.map +1 -1
  162. package/resources/support/conversations/index.d.ts +1 -1
  163. package/resources/support/conversations/index.d.ts.map +1 -1
  164. package/resources/support/index.d.mts +2 -2
  165. package/resources/support/index.d.mts.map +1 -1
  166. package/resources/support/index.d.ts +2 -2
  167. package/resources/support/index.d.ts.map +1 -1
  168. package/resources/support/support.d.mts +4 -4
  169. package/resources/support/support.d.mts.map +1 -1
  170. package/resources/support/support.d.ts +4 -4
  171. package/resources/support/support.d.ts.map +1 -1
  172. package/resources/support/support.mjs.map +1 -1
  173. package/resources/support/tickets/index.d.mts +1 -1
  174. package/resources/support/tickets/index.d.mts.map +1 -1
  175. package/resources/support/tickets/index.d.ts +1 -1
  176. package/resources/support/tickets/index.d.ts.map +1 -1
  177. package/resources/support/tickets/tickets.d.mts +9 -27
  178. package/resources/support/tickets/tickets.d.mts.map +1 -1
  179. package/resources/support/tickets/tickets.d.ts +9 -27
  180. package/resources/support/tickets/tickets.d.ts.map +1 -1
  181. package/resources/support/tickets/tickets.js +6 -2
  182. package/resources/support/tickets/tickets.js.map +1 -1
  183. package/resources/support/tickets/tickets.mjs +6 -2
  184. package/resources/support/tickets/tickets.mjs.map +1 -1
  185. package/resources/surveys.d.mts +34 -79
  186. package/resources/surveys.d.mts.map +1 -1
  187. package/resources/surveys.d.ts +34 -79
  188. package/resources/surveys.d.ts.map +1 -1
  189. package/resources/surveys.js +4 -3
  190. package/resources/surveys.js.map +1 -1
  191. package/resources/surveys.mjs +4 -3
  192. package/resources/surveys.mjs.map +1 -1
  193. package/resources/users/companies/companies.d.mts +9 -28
  194. package/resources/users/companies/companies.d.mts.map +1 -1
  195. package/resources/users/companies/companies.d.ts +9 -28
  196. package/resources/users/companies/companies.d.ts.map +1 -1
  197. package/resources/users/companies/companies.js +6 -2
  198. package/resources/users/companies/companies.js.map +1 -1
  199. package/resources/users/companies/companies.mjs +6 -2
  200. package/resources/users/companies/companies.mjs.map +1 -1
  201. package/resources/users/companies/contacts.d.mts +11 -16
  202. package/resources/users/companies/contacts.d.mts.map +1 -1
  203. package/resources/users/companies/contacts.d.ts +11 -16
  204. package/resources/users/companies/contacts.d.ts.map +1 -1
  205. package/resources/users/companies/contacts.js +8 -5
  206. package/resources/users/companies/contacts.js.map +1 -1
  207. package/resources/users/companies/contacts.mjs +8 -5
  208. package/resources/users/companies/contacts.mjs.map +1 -1
  209. package/resources/users/companies/index.d.mts +1 -1
  210. package/resources/users/companies/index.d.mts.map +1 -1
  211. package/resources/users/companies/index.d.ts +1 -1
  212. package/resources/users/companies/index.d.ts.map +1 -1
  213. package/resources/users/contacts/contacts.d.mts +9 -13
  214. package/resources/users/contacts/contacts.d.mts.map +1 -1
  215. package/resources/users/contacts/contacts.d.ts +9 -13
  216. package/resources/users/contacts/contacts.d.ts.map +1 -1
  217. package/resources/users/contacts/contacts.js +6 -2
  218. package/resources/users/contacts/contacts.js.map +1 -1
  219. package/resources/users/contacts/contacts.mjs +6 -2
  220. package/resources/users/contacts/contacts.mjs.map +1 -1
  221. package/resources/users/contacts/index.d.mts +1 -1
  222. package/resources/users/contacts/index.d.mts.map +1 -1
  223. package/resources/users/contacts/index.d.ts +1 -1
  224. package/resources/users/contacts/index.d.ts.map +1 -1
  225. package/resources/users/contacts/index.js.map +1 -1
  226. package/resources/users/contacts/index.mjs.map +1 -1
  227. package/resources/users/index.d.mts +2 -2
  228. package/resources/users/index.d.mts.map +1 -1
  229. package/resources/users/index.d.ts +2 -2
  230. package/resources/users/index.d.ts.map +1 -1
  231. package/resources/users/index.js.map +1 -1
  232. package/resources/users/index.mjs.map +1 -1
  233. package/resources/users/users.d.mts +4 -4
  234. package/resources/users/users.d.mts.map +1 -1
  235. package/resources/users/users.d.ts +4 -4
  236. package/resources/users/users.d.ts.map +1 -1
  237. package/resources/users/users.js.map +1 -1
  238. package/resources/users/users.mjs.map +1 -1
  239. package/resources/webhooks.d.mts +9 -27
  240. package/resources/webhooks.d.mts.map +1 -1
  241. package/resources/webhooks.d.ts +9 -27
  242. package/resources/webhooks.d.ts.map +1 -1
  243. package/resources/webhooks.js +6 -2
  244. package/resources/webhooks.js.map +1 -1
  245. package/resources/webhooks.mjs +6 -2
  246. package/resources/webhooks.mjs.map +1 -1
  247. package/src/client.ts +41 -10
  248. package/src/core/pagination.ts +157 -0
  249. package/src/index.ts +1 -0
  250. package/src/pagination.ts +2 -0
  251. package/src/resources/changelogs/changelogs.ts +11 -64
  252. package/src/resources/changelogs/index.ts +1 -1
  253. package/src/resources/feedback/comments.ts +11 -64
  254. package/src/resources/feedback/feedback.ts +4 -4
  255. package/src/resources/feedback/index.ts +2 -2
  256. package/src/resources/feedback/posts/index.ts +2 -1
  257. package/src/resources/feedback/posts/posts.ts +13 -65
  258. package/src/resources/feedback/posts/voters.ts +87 -140
  259. package/src/resources/help-center/articles.ts +11 -33
  260. package/src/resources/help-center/collections.ts +11 -34
  261. package/src/resources/help-center/help-center.ts +8 -8
  262. package/src/resources/help-center/help-centers.ts +11 -34
  263. package/src/resources/help-center/index.ts +4 -4
  264. package/src/resources/help-center/redirect-rules.ts +11 -34
  265. package/src/resources/index.ts +6 -5
  266. package/src/resources/organization/brands.ts +7 -32
  267. package/src/resources/organization/index.ts +1 -1
  268. package/src/resources/organization/organization.ts +2 -2
  269. package/src/resources/support/conversations/conversations.ts +11 -34
  270. package/src/resources/support/conversations/index.ts +1 -1
  271. package/src/resources/support/index.ts +2 -2
  272. package/src/resources/support/support.ts +4 -4
  273. package/src/resources/support/tickets/index.ts +1 -1
  274. package/src/resources/support/tickets/tickets.ts +11 -33
  275. package/src/resources/surveys.ts +54 -102
  276. package/src/resources/users/companies/companies.ts +11 -34
  277. package/src/resources/users/companies/contacts.ts +24 -26
  278. package/src/resources/users/companies/index.ts +1 -1
  279. package/src/resources/users/contacts/contacts.ts +14 -15
  280. package/src/resources/users/contacts/index.ts +1 -0
  281. package/src/resources/users/index.ts +2 -1
  282. package/src/resources/users/users.ts +4 -2
  283. package/src/resources/webhooks.ts +11 -33
  284. package/src/version.ts +1 -1
  285. package/version.d.mts +1 -1
  286. package/version.d.ts +1 -1
  287. package/version.js +1 -1
  288. package/version.mjs +1 -1
@@ -0,0 +1,101 @@
1
+ "use strict";
2
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
3
+ var _AbstractPage_client;
4
+ Object.defineProperty(exports, "__esModule", { value: true });
5
+ exports.CursorPage = exports.PagePromise = exports.AbstractPage = void 0;
6
+ const tslib_1 = require("../internal/tslib.js");
7
+ const error_1 = require("./error.js");
8
+ const parse_1 = require("../internal/parse.js");
9
+ const api_promise_1 = require("./api-promise.js");
10
+ const values_1 = require("../internal/utils/values.js");
11
+ class AbstractPage {
12
+ constructor(client, response, body, options) {
13
+ _AbstractPage_client.set(this, void 0);
14
+ tslib_1.__classPrivateFieldSet(this, _AbstractPage_client, client, "f");
15
+ this.options = options;
16
+ this.response = response;
17
+ this.body = body;
18
+ }
19
+ hasNextPage() {
20
+ const items = this.getPaginatedItems();
21
+ if (!items.length)
22
+ return false;
23
+ return this.nextPageRequestOptions() != null;
24
+ }
25
+ async getNextPage() {
26
+ const nextOptions = this.nextPageRequestOptions();
27
+ if (!nextOptions) {
28
+ throw new error_1.FeaturebaseError('No next page expected; please check `.hasNextPage()` before calling `.getNextPage()`.');
29
+ }
30
+ return await tslib_1.__classPrivateFieldGet(this, _AbstractPage_client, "f").requestAPIList(this.constructor, nextOptions);
31
+ }
32
+ async *iterPages() {
33
+ let page = this;
34
+ yield page;
35
+ while (page.hasNextPage()) {
36
+ page = await page.getNextPage();
37
+ yield page;
38
+ }
39
+ }
40
+ async *[(_AbstractPage_client = new WeakMap(), Symbol.asyncIterator)]() {
41
+ for await (const page of this.iterPages()) {
42
+ for (const item of page.getPaginatedItems()) {
43
+ yield item;
44
+ }
45
+ }
46
+ }
47
+ }
48
+ exports.AbstractPage = AbstractPage;
49
+ /**
50
+ * This subclass of Promise will resolve to an instantiated Page once the request completes.
51
+ *
52
+ * It also implements AsyncIterable to allow auto-paginating iteration on an unawaited list call, eg:
53
+ *
54
+ * for await (const item of client.items.list()) {
55
+ * console.log(item)
56
+ * }
57
+ */
58
+ class PagePromise extends api_promise_1.APIPromise {
59
+ constructor(client, request, Page) {
60
+ super(client, request, async (client, props) => new Page(client, props.response, await (0, parse_1.defaultParseResponse)(client, props), props.options));
61
+ }
62
+ /**
63
+ * Allow auto-paginating iteration on an unawaited list call, eg:
64
+ *
65
+ * for await (const item of client.items.list()) {
66
+ * console.log(item)
67
+ * }
68
+ */
69
+ async *[Symbol.asyncIterator]() {
70
+ const page = await this;
71
+ for await (const item of page) {
72
+ yield item;
73
+ }
74
+ }
75
+ }
76
+ exports.PagePromise = PagePromise;
77
+ class CursorPage extends AbstractPage {
78
+ constructor(client, response, body, options) {
79
+ super(client, response, body, options);
80
+ this.data = body.data || [];
81
+ this.nextCursor = body.nextCursor || null;
82
+ }
83
+ getPaginatedItems() {
84
+ return this.data ?? [];
85
+ }
86
+ nextPageRequestOptions() {
87
+ const cursor = this.nextCursor;
88
+ if (!cursor) {
89
+ return null;
90
+ }
91
+ return {
92
+ ...this.options,
93
+ query: {
94
+ ...(0, values_1.maybeObj)(this.options.query),
95
+ cursor,
96
+ },
97
+ };
98
+ }
99
+ }
100
+ exports.CursorPage = CursorPage;
101
+ //# sourceMappingURL=pagination.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"pagination.js","sourceRoot":"","sources":["../src/core/pagination.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;;;AAEtF,sCAA2C;AAE3C,gDAAyD;AAEzD,kDAA2C;AAE3C,wDAAoD;AAIpD,MAAsB,YAAY;IAOhC,YAAY,MAAmB,EAAE,QAAkB,EAAE,IAAa,EAAE,OAA4B;QANhG,uCAAqB;QAOnB,+BAAA,IAAI,wBAAW,MAAM,MAAA,CAAC;QACtB,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;QACvB,IAAI,CAAC,QAAQ,GAAG,QAAQ,CAAC;QACzB,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC;IACnB,CAAC;IAMD,WAAW;QACT,MAAM,KAAK,GAAG,IAAI,CAAC,iBAAiB,EAAE,CAAC;QAC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E,KAAK,CAAC,OAAO,CAAC,CAC7F,CAAC;IACJ,CAAC;IAED;;;;;;OAMG;IACH,KAAK,CAAC,CAAC,CAAC,MAAM,CAAC,aAAa,CAAC;QAC3B,MAAM,IAAI,GAAG,MAAM,IAAI,CAAC;QACxB,IAAI,KAAK,EAAE,MAAM,IAAI,IAAI,IAAI,EAAE,CAAC;YAC9B,MAAM,IAAI,CAAC;QACb,CAAC;IACH,CAAC;CACF;AAjCD,kCAiCC;AAcD,MAAa,UAAiB,SAAQ,YAAkB;IAKtD,YACE,MAAmB,EACnB,QAAkB,EAClB,IAA8B,EAC9B,OAA4B;QAE5B,KAAK,CAAC,MAAM,EAAE,QAAQ,EAAE,IAAI,EAAE,OAAO,CAAC,CAAC;QAEvC,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC,IAAI,IAAI,EAAE,CAAC;QAC5B,IAAI,CAAC,UAAU,GAAG,IAAI,CAAC,UAAU,IAAI,IAAI,CAAC;IAC5C,CAAC;IAED,iBAAiB;QACf,OAAO,IAAI,CAAC,IAAI,IAAI,EAAE,CAAC;IACzB,CAAC;IAED,sBAAsB;QACpB,MAAM,MAAM,GAAG,IAAI,CAAC,UAAU,CAAC;QAC/B,IAAI,CAAC,MAAM,EAAE,CAAC;YACZ,OAAO,IAAI,CAAC;QACd,CAAC;QAED,OAAO;YACL,GAAG,IAAI,CAAC,OAAO;YACf,KAAK,EAAE;gBACL,GAAG,IAAA,iBAAQ,EAAC,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC;gBAC/B,MAAM;aACP;SACF,CAAC;IACJ,CAAC;CACF;AAnCD,gCAmCC"}
@@ -0,0 +1,95 @@
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+ var _AbstractPage_client;
3
+ import { __classPrivateFieldGet, __classPrivateFieldSet } from "../internal/tslib.mjs";
4
+ import { FeaturebaseError } from "./error.mjs";
5
+ import { defaultParseResponse } from "../internal/parse.mjs";
6
+ import { APIPromise } from "./api-promise.mjs";
7
+ import { maybeObj } from "../internal/utils/values.mjs";
8
+ export class AbstractPage {
9
+ constructor(client, response, body, options) {
10
+ _AbstractPage_client.set(this, void 0);
11
+ __classPrivateFieldSet(this, _AbstractPage_client, client, "f");
12
+ this.options = options;
13
+ this.response = response;
14
+ this.body = body;
15
+ }
16
+ hasNextPage() {
17
+ const items = this.getPaginatedItems();
18
+ if (!items.length)
19
+ return false;
20
+ return this.nextPageRequestOptions() != null;
21
+ }
22
+ async getNextPage() {
23
+ const nextOptions = this.nextPageRequestOptions();
24
+ if (!nextOptions) {
25
+ throw new FeaturebaseError('No next page expected; please check `.hasNextPage()` before calling `.getNextPage()`.');
26
+ }
27
+ return await __classPrivateFieldGet(this, _AbstractPage_client, "f").requestAPIList(this.constructor, nextOptions);
28
+ }
29
+ async *iterPages() {
30
+ let page = this;
31
+ yield page;
32
+ while (page.hasNextPage()) {
33
+ page = await page.getNextPage();
34
+ yield page;
35
+ }
36
+ }
37
+ async *[(_AbstractPage_client = new WeakMap(), Symbol.asyncIterator)]() {
38
+ for await (const page of this.iterPages()) {
39
+ for (const item of page.getPaginatedItems()) {
40
+ yield item;
41
+ }
42
+ }
43
+ }
44
+ }
45
+ /**
46
+ * This subclass of Promise will resolve to an instantiated Page once the request completes.
47
+ *
48
+ * It also implements AsyncIterable to allow auto-paginating iteration on an unawaited list call, eg:
49
+ *
50
+ * for await (const item of client.items.list()) {
51
+ * console.log(item)
52
+ * }
53
+ */
54
+ export class PagePromise extends APIPromise {
55
+ constructor(client, request, Page) {
56
+ super(client, request, async (client, props) => new Page(client, props.response, await defaultParseResponse(client, props), props.options));
57
+ }
58
+ /**
59
+ * Allow auto-paginating iteration on an unawaited list call, eg:
60
+ *
61
+ * for await (const item of client.items.list()) {
62
+ * console.log(item)
63
+ * }
64
+ */
65
+ async *[Symbol.asyncIterator]() {
66
+ const page = await this;
67
+ for await (const item of page) {
68
+ yield item;
69
+ }
70
+ }
71
+ }
72
+ export class CursorPage extends AbstractPage {
73
+ constructor(client, response, body, options) {
74
+ super(client, response, body, options);
75
+ this.data = body.data || [];
76
+ this.nextCursor = body.nextCursor || null;
77
+ }
78
+ getPaginatedItems() {
79
+ return this.data ?? [];
80
+ }
81
+ nextPageRequestOptions() {
82
+ const cursor = this.nextCursor;
83
+ if (!cursor) {
84
+ return null;
85
+ }
86
+ return {
87
+ ...this.options,
88
+ query: {
89
+ ...maybeObj(this.options.query),
90
+ cursor,
91
+ },
92
+ };
93
+ }
94
+ }
95
+ //# sourceMappingURL=pagination.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"pagination.mjs","sourceRoot":"","sources":["../src/core/pagination.ts"],"names":[],"mappings":"AAAA,sFAAsF;;;OAE/E,EAAE,gBAAgB,EAAE;OAEpB,EAAE,oBAAoB,EAAE;OAExB,EAAE,UAAU,EAAE;OAEd,EAAE,QAAQ,EAAE;AAInB,MAAM,OAAgB,YAAY;IAOhC,YAAY,MAAmB,EAAE,QAAkB,EAAE,IAAa,EAAE,OAA4B;QANhG,uCAAqB;QAOnB,uBAAA,IAAI,wBAAW,MAAM,MAAA,CAAC;QACtB,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;QACvB,IAAI,CAAC,QAAQ,GAAG,QAAQ,CAAC;QACzB,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC;IACnB,CAAC;IAMD,WAAW;QACT,MAAM,KAAK,GAAG,IAAI,CAAC,iBAAiB,EAAE,CAAC;QACvC,IAAI,CAAC,KAAK,CAAC,MAAM;YAAE,OAAO,KAAK,CAAC;QAChC,OAAO,IAAI,CAAC,sBAAsB,EAAE,IAAI,IAAI,CAAC;IAC/C,CAAC;IAED,KAAK,CAAC,WAAW;QACf,MAAM,WAAW,GAAG,IAAI,CAAC,sBAAsB,EAAE,CAAC;QAClD,IAAI,CAAC,WAAW,EAAE,CAAC;YACjB,MAAM,IAAI,gBAAgB,CACxB,uFAAuF,CACxF,CAAC;QACJ,CAAC;QAED,OAAO,MAAM,uBAAA,IAA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ClB,IAA8B,EAC9B,OAA4B;QAE5B,KAAK,CAAC,MAAM,EAAE,QAAQ,EAAE,IAAI,EAAE,OAAO,CAAC,CAAC;QAEvC,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC,IAAI,IAAI,EAAE,CAAC;QAC5B,IAAI,CAAC,UAAU,GAAG,IAAI,CAAC,UAAU,IAAI,IAAI,CAAC;IAC5C,CAAC;IAED,iBAAiB;QACf,OAAO,IAAI,CAAC,IAAI,IAAI,EAAE,CAAC;IACzB,CAAC;IAED,sBAAsB;QACpB,MAAM,MAAM,GAAG,IAAI,CAAC,UAAU,CAAC;QAC/B,IAAI,CAAC,MAAM,EAAE,CAAC;YACZ,OAAO,IAAI,CAAC;QACd,CAAC;QAED,OAAO;YACL,GAAG,IAAI,CAAC,OAAO;YACf,KAAK,EAAE;gBACL,GAAG,QAAQ,CAAC,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC;gBAC/B,MAAM;aACP;SACF,CAAC;IACJ,CAAC;CACF"}
package/index.d.mts CHANGED
@@ -2,5 +2,6 @@ export { Featurebase as default } from "./client.mjs";
2
2
  export { type Uploadable, toFile } from "./core/uploads.mjs";
3
3
  export { APIPromise } from "./core/api-promise.mjs";
4
4
  export { Featurebase, type ClientOptions } from "./client.mjs";
5
+ export { PagePromise } from "./core/pagination.mjs";
5
6
  export { FeaturebaseError, APIError, APIConnectionError, APIConnectionTimeoutError, APIUserAbortError, NotFoundError, ConflictError, RateLimitError, BadRequestError, AuthenticationError, InternalServerError, PermissionDeniedError, UnprocessableEntityError, } from "./core/error.mjs";
6
7
  //# sourceMappingURL=index.d.mts.map
package/index.d.mts.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.mts","sourceRoot":"","sources":["src/index.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,IAAI,OAAO,EAAE;OAE1B,EAAE,KAAK,UAAU,EAAE,MAAM,EAAE;OAC3B,EAAE,UAAU,EAAE;OACd,EAAE,WAAW,EAAE,KAAK,aAAa,EAAE;OACnC,EACL,gBAAgB,EAChB,QAAQ,EACR,kBAAkB,EAClB,yBAAyB,EACzB,iBAAiB,EACjB,aAAa,EACb,aAAa,EACb,cAAc,EACd,eAAe,EACf,mBAAmB,EACnB,mBAAmB,EACnB,qBAAqB,EACrB,wBAAwB,GACzB"}
1
+ {"version":3,"file":"index.d.mts","sourceRoot":"","sources":["src/index.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,IAAI,OAAO,EAAE;OAE1B,EAAE,KAAK,UAAU,EAAE,MAAM,EAAE;OAC3B,EAAE,UAAU,EAAE;OACd,EAAE,WAAW,EAAE,KAAK,aAAa,EAAE;OACnC,EAAE,WAAW,EAAE;OACf,EACL,gBAAgB,EAChB,QAAQ,EACR,kBAAkB,EAClB,yBAAyB,EACzB,iBAAiB,EACjB,aAAa,EACb,aAAa,EACb,cAAc,EACd,eAAe,EACf,mBAAmB,EACnB,mBAAmB,EACnB,qBAAqB,EACrB,wBAAwB,GACzB"}
package/index.d.ts CHANGED
@@ -2,5 +2,6 @@ export { Featurebase as default } from "./client.js";
2
2
  export { type Uploadable, toFile } from "./core/uploads.js";
3
3
  export { APIPromise } from "./core/api-promise.js";
4
4
  export { Featurebase, type ClientOptions } from "./client.js";
5
+ export { PagePromise } from "./core/pagination.js";
5
6
  export { FeaturebaseError, APIError, APIConnectionError, APIConnectionTimeoutError, APIUserAbortError, NotFoundError, ConflictError, RateLimitError, BadRequestError, AuthenticationError, InternalServerError, PermissionDeniedError, UnprocessableEntityError, } from "./core/error.js";
6
7
  //# sourceMappingURL=index.d.ts.map
package/index.d.ts.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["src/index.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,IAAI,OAAO,EAAE;OAE1B,EAAE,KAAK,UAAU,EAAE,MAAM,EAAE;OAC3B,EAAE,UAAU,EAAE;OACd,EAAE,WAAW,EAAE,KAAK,aAAa,EAAE;OACnC,EACL,gBAAgB,EAChB,QAAQ,EACR,kBAAkB,EAClB,yBAAyB,EACzB,iBAAiB,EACjB,aAAa,EACb,aAAa,EACb,cAAc,EACd,eAAe,EACf,mBAAmB,EACnB,mBAAmB,EACnB,qBAAqB,EACrB,wBAAwB,GACzB"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["src/index.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,IAAI,OAAO,EAAE;OAE1B,EAAE,KAAK,UAAU,EAAE,MAAM,EAAE;OAC3B,EAAE,UAAU,EAAE;OACd,EAAE,WAAW,EAAE,KAAK,aAAa,EAAE;OACnC,EAAE,WAAW,EAAE;OACf,EACL,gBAAgB,EAChB,QAAQ,EACR,kBAAkB,EAClB,yBAAyB,EACzB,iBAAiB,EACjB,aAAa,EACb,aAAa,EACb,cAAc,EACd,eAAe,EACf,mBAAmB,EACnB,mBAAmB,EACnB,qBAAqB,EACrB,wBAAwB,GACzB"}
package/index.js CHANGED
@@ -4,7 +4,7 @@ exports = module.exports = function (...args) {
4
4
  return new exports.default(...args)
5
5
  }
6
6
  Object.defineProperty(exports, "__esModule", { value: true });
7
- exports.UnprocessableEntityError = exports.PermissionDeniedError = exports.InternalServerError = exports.AuthenticationError = exports.BadRequestError = exports.RateLimitError = exports.ConflictError = exports.NotFoundError = exports.APIUserAbortError = exports.APIConnectionTimeoutError = exports.APIConnectionError = exports.APIError = exports.FeaturebaseError = exports.Featurebase = exports.APIPromise = exports.toFile = exports.default = void 0;
7
+ exports.UnprocessableEntityError = exports.PermissionDeniedError = exports.InternalServerError = exports.AuthenticationError = exports.BadRequestError = exports.RateLimitError = exports.ConflictError = exports.NotFoundError = exports.APIUserAbortError = exports.APIConnectionTimeoutError = exports.APIConnectionError = exports.APIError = exports.FeaturebaseError = exports.PagePromise = exports.Featurebase = exports.APIPromise = exports.toFile = exports.default = void 0;
8
8
  var client_1 = require("./client.js");
9
9
  Object.defineProperty(exports, "default", { enumerable: true, get: function () { return client_1.Featurebase; } });
10
10
  var uploads_1 = require("./core/uploads.js");
@@ -13,6 +13,8 @@ var api_promise_1 = require("./core/api-promise.js");
13
13
  Object.defineProperty(exports, "APIPromise", { enumerable: true, get: function () { return api_promise_1.APIPromise; } });
14
14
  var client_2 = require("./client.js");
15
15
  Object.defineProperty(exports, "Featurebase", { enumerable: true, get: function () { return client_2.Featurebase; } });
16
+ var pagination_1 = require("./core/pagination.js");
17
+ Object.defineProperty(exports, "PagePromise", { enumerable: true, get: function () { return pagination_1.PagePromise; } });
16
18
  var error_1 = require("./core/error.js");
17
19
  Object.defineProperty(exports, "FeaturebaseError", { enumerable: true, get: function () { return error_1.FeaturebaseError; } });
18
20
  Object.defineProperty(exports, "APIError", { enumerable: true, get: function () { return error_1.APIError; } });
package/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["src/index.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,sCAAkD;AAAzC,iGAAA,WAAW,OAAW;AAE/B,6CAAyD;AAA/B,iGAAA,MAAM,OAAA;AAChC,qDAAgD;AAAvC,yGAAA,UAAU,OAAA;AACnB,sCAA2D;AAAlD,qGAAA,WAAW,OAAA;AACpB,yCAcsB;AAbpB,yGAAA,gBAAgB,OAAA;AAChB,iGAAA,QAAQ,OAAA;AACR,2GAAA,kBAAkB,OAAA;AAClB,kHAAA,yBAAyB,OAAA;AACzB,0GAAA,iBAAiB,OAAA;AACjB,sGAAA,aAAa,OAAA;AACb,sGAAA,aAAa,OAAA;AACb,uGAAA,cAAc,OAAA;AACd,wGAAA,eAAe,OAAA;AACf,4GAAA,mBAAmB,OAAA;AACnB,4GAAA,mBAAmB,OAAA;AACnB,8GAAA,qBAAqB,OAAA;AACrB,iHAAA,wBAAwB,OAAA"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["src/index.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,sCAAkD;AAAzC,iGAAA,WAAW,OAAW;AAE/B,6CAAyD;AAA/B,iGAAA,MAAM,OAAA;AAChC,qDAAgD;AAAvC,yGAAA,UAAU,OAAA;AACnB,sCAA2D;AAAlD,qGAAA,WAAW,OAAA;AACpB,mDAAgD;AAAvC,yGAAA,WAAW,OAAA;AACpB,yCAcsB;AAbpB,yGAAA,gBAAgB,OAAA;AAChB,iGAAA,QAAQ,OAAA;AACR,2GAAA,kBAAkB,OAAA;AAClB,kHAAA,yBAAyB,OAAA;AACzB,0GAAA,iBAAiB,OAAA;AACjB,sGAAA,aAAa,OAAA;AACb,sGAAA,aAAa,OAAA;AACb,uGAAA,cAAc,OAAA;AACd,wGAAA,eAAe,OAAA;AACf,4GAAA,mBAAmB,OAAA;AACnB,4GAAA,mBAAmB,OAAA;AACnB,8GAAA,qBAAqB,OAAA;AACrB,iHAAA,wBAAwB,OAAA"}
package/index.mjs CHANGED
@@ -3,5 +3,6 @@ export { Featurebase as default } from "./client.mjs";
3
3
  export { toFile } from "./core/uploads.mjs";
4
4
  export { APIPromise } from "./core/api-promise.mjs";
5
5
  export { Featurebase } from "./client.mjs";
6
+ export { PagePromise } from "./core/pagination.mjs";
6
7
  export { FeaturebaseError, APIError, APIConnectionError, APIConnectionTimeoutError, APIUserAbortError, NotFoundError, ConflictError, RateLimitError, BadRequestError, AuthenticationError, InternalServerError, PermissionDeniedError, UnprocessableEntityError, } from "./core/error.mjs";
7
8
  //# sourceMappingURL=index.mjs.map
package/index.mjs.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.mjs","sourceRoot":"","sources":["src/index.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,IAAI,OAAO,EAAE;OAE1B,EAAmB,MAAM,EAAE;OAC3B,EAAE,UAAU,EAAE;OACd,EAAE,WAAW,EAAsB;OACnC,EACL,gBAAgB,EAChB,QAAQ,EACR,kBAAkB,EAClB,yBAAyB,EACzB,iBAAiB,EACjB,aAAa,EACb,aAAa,EACb,cAAc,EACd,eAAe,EACf,mBAAmB,EACnB,mBAAmB,EACnB,qBAAqB,EACrB,wBAAwB,GACzB"}
1
+ {"version":3,"file":"index.mjs","sourceRoot":"","sources":["src/index.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,IAAI,OAAO,EAAE;OAE1B,EAAmB,MAAM,EAAE;OAC3B,EAAE,UAAU,EAAE;OACd,EAAE,WAAW,EAAsB;OACnC,EAAE,WAAW,EAAE;OACf,EACL,gBAAgB,EAChB,QAAQ,EACR,kBAAkB,EAClB,yBAAyB,EACzB,iBAAiB,EACjB,aAAa,EACb,aAAa,EACb,cAAc,EACd,eAAe,EACf,mBAAmB,EACnB,mBAAmB,EACnB,qBAAqB,EACrB,wBAAwB,GACzB"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "featurebase-node",
3
- "version": "0.3.0",
3
+ "version": "0.4.0",
4
4
  "description": "The official TypeScript library for the Featurebase API",
5
5
  "author": "Featurebase <>",
6
6
  "types": "./index.d.ts",
@@ -81,6 +81,16 @@
81
81
  "./index.mjs": {
82
82
  "default": "./index.mjs"
83
83
  },
84
+ "./pagination": {
85
+ "import": "./pagination.mjs",
86
+ "require": "./pagination.js"
87
+ },
88
+ "./pagination.js": {
89
+ "default": "./pagination.js"
90
+ },
91
+ "./pagination.mjs": {
92
+ "default": "./pagination.mjs"
93
+ },
84
94
  "./resource": {
85
95
  "import": "./resource.mjs",
86
96
  "require": "./resource.js"
@@ -0,0 +1,2 @@
1
+ export * from "./core/pagination.mjs";
2
+ //# sourceMappingURL=pagination.d.mts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"pagination.d.mts","sourceRoot":"","sources":["src/pagination.ts"],"names":[],"mappings":""}
@@ -0,0 +1,2 @@
1
+ export * from "./core/pagination.js";
2
+ //# sourceMappingURL=pagination.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"pagination.d.ts","sourceRoot":"","sources":["src/pagination.ts"],"names":[],"mappings":""}
package/pagination.js ADDED
@@ -0,0 +1,6 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ const tslib_1 = require("./internal/tslib.js");
4
+ /** @deprecated Import from ./core/pagination instead */
5
+ tslib_1.__exportStar(require("./core/pagination.js"), exports);
6
+ //# sourceMappingURL=pagination.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"pagination.js","sourceRoot":"","sources":["src/pagination.ts"],"names":[],"mappings":";;;AAAA,wDAAwD;AACxD,+DAAkC"}
package/pagination.mjs ADDED
@@ -0,0 +1,2 @@
1
+ export * from "./core/pagination.mjs";
2
+ //# sourceMappingURL=pagination.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"pagination.mjs","sourceRoot":"","sources":["src/pagination.ts"],"names":[],"mappings":""}
@@ -2,6 +2,7 @@ import { APIResource } from "../../core/resource.mjs";
2
2
  import * as SubscribersAPI from "./subscribers.mjs";
3
3
  import { SubscriberAddParams, SubscriberAddResponse, SubscriberRemoveParams, SubscriberRemoveResponse, Subscribers } from "./subscribers.mjs";
4
4
  import { APIPromise } from "../../core/api-promise.mjs";
5
+ import { CursorPage, type CursorPageParams, PagePromise } from "../../core/pagination.mjs";
5
6
  import { RequestOptions } from "../../internal/request-options.mjs";
6
7
  /**
7
8
  * Release notes and updates published by the organization. Changelogs keep users informed about new features, improvements, and fixes.
@@ -183,10 +184,13 @@ export declare class Changelogs extends APIResource {
183
184
  *
184
185
  * @example
185
186
  * ```ts
186
- * const changelogs = await client.changelogs.list();
187
+ * // Automatically fetches more pages as needed.
188
+ * for await (const changelog of client.changelogs.list()) {
189
+ * // ...
190
+ * }
187
191
  * ```
188
192
  */
189
- list(params?: ChangelogListParams | null | undefined, options?: RequestOptions): APIPromise<ChangelogListResponse>;
193
+ list(params?: ChangelogListParams | null | undefined, options?: RequestOptions): PagePromise<ChangelogsCursorPage, Changelog>;
190
194
  /**
191
195
  * Deletes a changelog by its unique identifier.
192
196
  *
@@ -325,6 +329,7 @@ export declare class Changelogs extends APIResource {
325
329
  */
326
330
  unpublish(id: string, params: ChangelogUnpublishParams, options?: RequestOptions): APIPromise<PublishUnpublishSuccess>;
327
331
  }
332
+ export type ChangelogsCursorPage = CursorPage<Changelog>;
328
333
  export interface Changelog {
329
334
  /**
330
335
  * Unique identifier
@@ -471,47 +476,6 @@ export interface PublishUnpublishSuccess {
471
476
  */
472
477
  state?: 'published' | 'scheduled' | 'unpublished';
473
478
  }
474
- export interface ChangelogListResponse {
475
- /**
476
- * Array of changelogs
477
- */
478
- data: Array<Changelog>;
479
- /**
480
- * Cursor for fetching the next page (cursor-based pagination)
481
- */
482
- nextCursor: string | null;
483
- /**
484
- * Object type identifier
485
- */
486
- object: 'list';
487
- /**
488
- * Pagination metadata for page-based requests
489
- */
490
- pagination?: ChangelogListResponse.Pagination;
491
- }
492
- export declare namespace ChangelogListResponse {
493
- /**
494
- * Pagination metadata for page-based requests
495
- */
496
- interface Pagination {
497
- /**
498
- * Items per page
499
- */
500
- limit: number;
501
- /**
502
- * Current page number
503
- */
504
- page: number;
505
- /**
506
- * Total number of items
507
- */
508
- total: number;
509
- /**
510
- * Total number of pages
511
- */
512
- totalPages: number;
513
- }
514
- }
515
479
  export interface ChangelogDeleteResponse {
516
480
  /**
517
481
  * Unique identifier of the deleted changelog
@@ -622,7 +586,7 @@ export interface ChangelogUpdateParams {
622
586
  */
623
587
  'Featurebase-Version'?: string;
624
588
  }
625
- export interface ChangelogListParams {
589
+ export interface ChangelogListParams extends CursorPageParams {
626
590
  /**
627
591
  * Query param: Find changelog by its id (also accepts slug)
628
592
  */
@@ -631,18 +595,10 @@ export interface ChangelogListParams {
631
595
  * Query param: Filter changelogs by category names (single value or array)
632
596
  */
633
597
  categories?: string | Array<string>;
634
- /**
635
- * Query param: Cursor for pagination. Use nextCursor from previous response.
636
- */
637
- cursor?: string;
638
598
  /**
639
599
  * Query param: Include Changelogs dated on or before the specified end date
640
600
  */
641
601
  endDate?: string | null;
642
- /**
643
- * Query param: Maximum number of changelogs to return
644
- */
645
- limit?: number;
646
602
  /**
647
603
  * Query param: The locale of the changelogs. Defaults to the organization default
648
604
  * locale.
@@ -717,7 +673,7 @@ export interface ChangelogUnpublishParams {
717
673
  'Featurebase-Version'?: string;
718
674
  }
719
675
  export declare namespace Changelogs {
720
- export { type Changelog as Changelog, type PublishUnpublishSuccess as PublishUnpublishSuccess, type ChangelogListResponse as ChangelogListResponse, type ChangelogDeleteResponse as ChangelogDeleteResponse, type ChangelogCreateParams as ChangelogCreateParams, type ChangelogRetrieveParams as ChangelogRetrieveParams, type ChangelogUpdateParams as ChangelogUpdateParams, type ChangelogListParams as ChangelogListParams, type ChangelogDeleteParams as ChangelogDeleteParams, type ChangelogPublishParams as ChangelogPublishParams, type ChangelogUnpublishParams as ChangelogUnpublishParams, };
676
+ export { type Changelog as Changelog, type PublishUnpublishSuccess as PublishUnpublishSuccess, type ChangelogDeleteResponse as ChangelogDeleteResponse, type ChangelogsCursorPage as ChangelogsCursorPage, type ChangelogCreateParams as ChangelogCreateParams, type ChangelogRetrieveParams as ChangelogRetrieveParams, type ChangelogUpdateParams as ChangelogUpdateParams, type ChangelogListParams as ChangelogListParams, type ChangelogDeleteParams as ChangelogDeleteParams, type ChangelogPublishParams as ChangelogPublishParams, type ChangelogUnpublishParams as ChangelogUnpublishParams, };
721
677
  export { Subscribers as Subscribers, type SubscriberAddResponse as SubscriberAddResponse, type SubscriberRemoveResponse as SubscriberRemoveResponse, type SubscriberAddParams as SubscriberAddParams, type SubscriberRemoveParams as SubscriberRemoveParams, };
722
678
  }
723
679
  //# sourceMappingURL=changelogs.d.mts.map
@@ -1 +1 @@
1
- {"version":3,"file":"changelogs.d.mts","sourceRoot":"","sources":["../../src/resources/changelogs/changelogs.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,cAAc;OACnB,EACL,mBAAmB,EACnB,qBAAqB,EACrB,sBAAsB,EACtB,wBAAwB,EACxB,WAAW,EACZ;OACM,EAAE,UAAU,E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AAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,OAAO,GACP,IAAI,GACJ,IAAI,GACJ,IAAI,CACP,CAAC;IAEF;;;OAGG;IACH,qBAAqB,CAAC,EAAE,MAAM,CAAC;CAChC;AAID,MAAM,CAAC,OAAO,WAAW,UAAU,CAAC;IAClC,OAAO,EACL,KAAK,SAAS,IAAI,SAAS,EAC3B,KAAK,uBAAuB,IAAI,uBAAuB,EACvD,KAAK,qBAAqB,IAAI,qBAAqB,EACnD,KAAK,uBAAuB,IAAI,uBAAuB,EACvD,KAAK,qBAAqB,IAAI,qBAAqB,EACnD,KAAK,uBAAuB,IAAI,uBAAuB,EACvD,KAAK,qBAAqB,IAAI,qBAAqB,EACnD,KAAK,mBAAmB,IAAI,mBAAmB,EAC/C,KAAK,qBAAqB,IAAI,qBAAqB,EACnD,KAAK,sBAAsB,IAAI,sBAAsB,EACrD,KAAK,wBAAwB,IAAI,wBAAwB,GAC1D,CAAC;IAEF,OAAO,EACL,WAAW,IAAI,WAAW,EAC1B,KAAK,qBAAqB,IAAI,qBAAqB,EACnD,KAAK,wBAAwB,IAAI,wBAAwB,EACzD,KAAK,mBAAmB,IAAI,mBAAmB,EAC/C,KAAK,sBAAsB,IAAI,sBAAsB,GACtD,CAAC;CACH"}
1
+ {"version":3,"file":"changelogs.d.mts","sourceRoot":"","sources":["../../src/resources/changelogs/changelogs.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,cAAc;OACnB,EACL,mBAAmB,EACnB,qBAAqB,EACrB,sBAAsB,EACtB,wBAAwB,EACxB,WAAW,EACZ;OACM,EAAE,UAAU,EAAE;OACd,EAAE,UAAU,EAAE,KAAK,gBAAgB,EAAE,WAAW,EAAE;OAElD,EAAE,cAAc,EAAE;AAGzB;;GAEG;AACH,qBAAa,UAAW,SAAQ,WAAW;IACzC,WAAW,EAAE,cAAc,CAAC,WAAW,CAAgD;IAEvF;;;;;;;;;;;;;;;;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,IAAI,WAAW,EAC1B,KAAK,qBAAqB,IAAI,qBAAqB,EACnD,KAAK,wBAAwB,IAAI,wBAAwB,EACzD,KAAK,mBAAmB,IAAI,mBAAmB,EAC/C,KAAK,sBAAsB,IAAI,sBAAsB,GACtD,CAAC;CACH"}
@@ -2,6 +2,7 @@ import { APIResource } from "../../core/resource.js";
2
2
  import * as SubscribersAPI from "./subscribers.js";
3
3
  import { SubscriberAddParams, SubscriberAddResponse, SubscriberRemoveParams, SubscriberRemoveResponse, Subscribers } from "./subscribers.js";
4
4
  import { APIPromise } from "../../core/api-promise.js";
5
+ import { CursorPage, type CursorPageParams, PagePromise } from "../../core/pagination.js";
5
6
  import { RequestOptions } from "../../internal/request-options.js";
6
7
  /**
7
8
  * Release notes and updates published by the organization. Changelogs keep users informed about new features, improvements, and fixes.
@@ -183,10 +184,13 @@ export declare class Changelogs extends APIResource {
183
184
  *
184
185
  * @example
185
186
  * ```ts
186
- * const changelogs = await client.changelogs.list();
187
+ * // Automatically fetches more pages as needed.
188
+ * for await (const changelog of client.changelogs.list()) {
189
+ * // ...
190
+ * }
187
191
  * ```
188
192
  */
189
- list(params?: ChangelogListParams | null | undefined, options?: RequestOptions): APIPromise<ChangelogListResponse>;
193
+ list(params?: ChangelogListParams | null | undefined, options?: RequestOptions): PagePromise<ChangelogsCursorPage, Changelog>;
190
194
  /**
191
195
  * Deletes a changelog by its unique identifier.
192
196
  *
@@ -325,6 +329,7 @@ export declare class Changelogs extends APIResource {
325
329
  */
326
330
  unpublish(id: string, params: ChangelogUnpublishParams, options?: RequestOptions): APIPromise<PublishUnpublishSuccess>;
327
331
  }
332
+ export type ChangelogsCursorPage = CursorPage<Changelog>;
328
333
  export interface Changelog {
329
334
  /**
330
335
  * Unique identifier
@@ -471,47 +476,6 @@ export interface PublishUnpublishSuccess {
471
476
  */
472
477
  state?: 'published' | 'scheduled' | 'unpublished';
473
478
  }
474
- export interface ChangelogListResponse {
475
- /**
476
- * Array of changelogs
477
- */
478
- data: Array<Changelog>;
479
- /**
480
- * Cursor for fetching the next page (cursor-based pagination)
481
- */
482
- nextCursor: string | null;
483
- /**
484
- * Object type identifier
485
- */
486
- object: 'list';
487
- /**
488
- * Pagination metadata for page-based requests
489
- */
490
- pagination?: ChangelogListResponse.Pagination;
491
- }
492
- export declare namespace ChangelogListResponse {
493
- /**
494
- * Pagination metadata for page-based requests
495
- */
496
- interface Pagination {
497
- /**
498
- * Items per page
499
- */
500
- limit: number;
501
- /**
502
- * Current page number
503
- */
504
- page: number;
505
- /**
506
- * Total number of items
507
- */
508
- total: number;
509
- /**
510
- * Total number of pages
511
- */
512
- totalPages: number;
513
- }
514
- }
515
479
  export interface ChangelogDeleteResponse {
516
480
  /**
517
481
  * Unique identifier of the deleted changelog
@@ -622,7 +586,7 @@ export interface ChangelogUpdateParams {
622
586
  */
623
587
  'Featurebase-Version'?: string;
624
588
  }
625
- export interface ChangelogListParams {
589
+ export interface ChangelogListParams extends CursorPageParams {
626
590
  /**
627
591
  * Query param: Find changelog by its id (also accepts slug)
628
592
  */
@@ -631,18 +595,10 @@ export interface ChangelogListParams {
631
595
  * Query param: Filter changelogs by category names (single value or array)
632
596
  */
633
597
  categories?: string | Array<string>;
634
- /**
635
- * Query param: Cursor for pagination. Use nextCursor from previous response.
636
- */
637
- cursor?: string;
638
598
  /**
639
599
  * Query param: Include Changelogs dated on or before the specified end date
640
600
  */
641
601
  endDate?: string | null;
642
- /**
643
- * Query param: Maximum number of changelogs to return
644
- */
645
- limit?: number;
646
602
  /**
647
603
  * Query param: The locale of the changelogs. Defaults to the organization default
648
604
  * locale.
@@ -717,7 +673,7 @@ export interface ChangelogUnpublishParams {
717
673
  'Featurebase-Version'?: string;
718
674
  }
719
675
  export declare namespace Changelogs {
720
- export { type Changelog as Changelog, type PublishUnpublishSuccess as PublishUnpublishSuccess, type ChangelogListResponse as ChangelogListResponse, type ChangelogDeleteResponse as ChangelogDeleteResponse, type ChangelogCreateParams as ChangelogCreateParams, type ChangelogRetrieveParams as ChangelogRetrieveParams, type ChangelogUpdateParams as ChangelogUpdateParams, type ChangelogListParams as ChangelogListParams, type ChangelogDeleteParams as ChangelogDeleteParams, type ChangelogPublishParams as ChangelogPublishParams, type ChangelogUnpublishParams as ChangelogUnpublishParams, };
676
+ export { type Changelog as Changelog, type PublishUnpublishSuccess as PublishUnpublishSuccess, type ChangelogDeleteResponse as ChangelogDeleteResponse, type ChangelogsCursorPage as ChangelogsCursorPage, type ChangelogCreateParams as ChangelogCreateParams, type ChangelogRetrieveParams as ChangelogRetrieveParams, type ChangelogUpdateParams as ChangelogUpdateParams, type ChangelogListParams as ChangelogListParams, type ChangelogDeleteParams as ChangelogDeleteParams, type ChangelogPublishParams as ChangelogPublishParams, type ChangelogUnpublishParams as ChangelogUnpublishParams, };
721
677
  export { Subscribers as Subscribers, type SubscriberAddResponse as SubscriberAddResponse, type SubscriberRemoveResponse as SubscriberRemoveResponse, type SubscriberAddParams as SubscriberAddParams, type SubscriberRemoveParams as SubscriberRemoveParams, };
722
678
  }
723
679
  //# sourceMappingURL=changelogs.d.ts.map