finance-sentiment 2.1.0 → 2.3.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.
package/README.md CHANGED
@@ -9,6 +9,7 @@ It gives you typed access to:
9
9
  - News sentiment and source-filtered rankings
10
10
  - X/Twitter stock sentiment
11
11
  - Polymarket stock activity and market attention
12
+ - Reddit crypto token sentiment
12
13
 
13
14
  Links:
14
15
  - Source: https://github.com/adanos-software/adanos-ts-sdk
@@ -34,19 +35,23 @@ import { AdanosClient } from "finance-sentiment";
34
35
 
35
36
  const client = new AdanosClient({ apiKey: "adanos_api_key_here" });
36
37
 
37
- const trending = await client.reddit.trending({ days: 7, limit: 10 });
38
- const tsla = await client.reddit.stock("TSLA", { days: 14 });
38
+ const trending = await client.reddit.trending({ limit: 10 });
39
+ const tsla = await client.reddit.stock("TSLA");
39
40
  const explanation = await client.reddit.explain("TSLA");
41
+ const health = await client.health();
40
42
 
41
43
  console.log(trending[0].ticker);
42
44
  console.log(tsla.buzz_score);
43
45
  console.log(explanation.explanation);
46
+ console.log(health.summary.healthy);
44
47
  ```
45
48
 
46
49
  ## What You Can Do
47
50
 
48
51
  - Rank trending stocks across Reddit, News, X, and Polymarket
52
+ - Track Reddit crypto token sentiment and raw mention rows
49
53
  - Pull service-level market sentiment snapshots across every stock namespace
54
+ - Check aggregate API health and per-service health/statistics
50
55
  - Pull detailed ticker reports for a configurable lookback window
51
56
  - Search and compare tickers across datasets
52
57
  - Generate AI-written explanations for Reddit and News stock trends
@@ -58,6 +63,9 @@ console.log(explanation.explanation);
58
63
  - `client.news.*` for News Stocks
59
64
  - `client.x.*` for X/Twitter Stocks
60
65
  - `client.polymarket.*` for Polymarket Stocks
66
+ - `client.crypto.*` for Reddit Crypto
67
+ - `client.redditCrypto.*` is an alias for `client.crypto.*`
68
+ - `client.health()` for aggregate API health
61
69
 
62
70
  ## Examples
63
71
 
@@ -68,14 +76,14 @@ import { AdanosClient } from "finance-sentiment";
68
76
 
69
77
  const client = new AdanosClient({ apiKey: "adanos_api_key_here" });
70
78
 
71
- const trending = await client.reddit.trending({ days: 7, limit: 10 });
72
- const sectors = await client.reddit.trendingSectors({ days: 7, limit: 10 });
73
- const countries = await client.reddit.trendingCountries({ days: 7, limit: 10 });
74
- const tsla = await client.reddit.stock("TSLA", { days: 14 });
79
+ const trending = await client.reddit.trending({ limit: 10 });
80
+ const sectors = await client.reddit.trendingSectors({ limit: 10 });
81
+ const countries = await client.reddit.trendingCountries({ limit: 10 });
82
+ const tsla = await client.reddit.stock("TSLA");
75
83
  const explanation = await client.reddit.explain("TSLA");
76
- const results = await client.reddit.search("Tesla", { days: 7, limit: 10 });
77
- const comparison = await client.reddit.compare(["TSLA", "AAPL", "MSFT"], { days: 7 });
78
- const market = await client.reddit.marketSentiment({ days: 7 });
84
+ const results = await client.reddit.search("Tesla", { limit: 10 });
85
+ const comparison = await client.reddit.compare(["TSLA", "AAPL", "MSFT"]);
86
+ const market = await client.reddit.marketSentiment();
79
87
  ```
80
88
 
81
89
  ### News
@@ -85,14 +93,14 @@ import { AdanosClient } from "finance-sentiment";
85
93
 
86
94
  const client = new AdanosClient({ apiKey: "adanos_api_key_here" });
87
95
 
88
- const trending = await client.news.trending({ days: 7, source: "reuters" });
89
- const sectors = await client.news.trendingSectors({ days: 7, source: "reuters" });
90
- const countries = await client.news.trendingCountries({ days: 7, source: "reuters" });
91
- const nvda = await client.news.stock("NVDA", { days: 7 });
96
+ const trending = await client.news.trending({ source: "reuters" });
97
+ const sectors = await client.news.trendingSectors({ source: "reuters" });
98
+ const countries = await client.news.trendingCountries({ source: "reuters" });
99
+ const nvda = await client.news.stock("NVDA");
92
100
  const explanation = await client.news.explain("NVDA");
93
- const results = await client.news.search("Nvidia", { days: 7, limit: 10 });
94
- const comparison = await client.news.compare(["NVDA", "AAPL"], { days: 7 });
95
- const market = await client.news.marketSentiment({ days: 7 });
101
+ const results = await client.news.search("Nvidia", { limit: 10 });
102
+ const comparison = await client.news.compare(["NVDA", "AAPL"]);
103
+ const market = await client.news.marketSentiment();
96
104
  const stats = await client.news.stats();
97
105
  const health = await client.news.health();
98
106
  ```
@@ -104,14 +112,16 @@ import { AdanosClient } from "finance-sentiment";
104
112
 
105
113
  const client = new AdanosClient({ apiKey: "adanos_api_key_here" });
106
114
 
107
- const trending = await client.x.trending({ days: 1, limit: 20 });
108
- const sectors = await client.x.trendingSectors({ days: 1, limit: 10 });
109
- const countries = await client.x.trendingCountries({ days: 1, limit: 10 });
115
+ const trending = await client.x.trending({ limit: 20 });
116
+ const sectors = await client.x.trendingSectors({ limit: 10 });
117
+ const countries = await client.x.trendingCountries({ limit: 10 });
110
118
  const nvda = await client.x.stock("NVDA");
111
119
  const explanation = await client.x.explain("NVDA");
112
- const results = await client.x.search("Nvidia", { days: 7, limit: 10 });
113
- const comparison = await client.x.compare(["NVDA", "AMD"], { days: 7 });
114
- const market = await client.x.marketSentiment({ days: 7 });
120
+ const results = await client.x.search("Nvidia", { limit: 10 });
121
+ const comparison = await client.x.compare(["NVDA", "AMD"]);
122
+ const market = await client.x.marketSentiment();
123
+ const stats = await client.x.stats();
124
+ const health = await client.x.health();
115
125
  ```
116
126
 
117
127
  ### Polymarket
@@ -121,49 +131,79 @@ import { AdanosClient } from "finance-sentiment";
121
131
 
122
132
  const client = new AdanosClient({ apiKey: "adanos_api_key_here" });
123
133
 
124
- const trending = await client.polymarket.trending({ days: 7, limit: 20, type: "stock" });
125
- const sectors = await client.polymarket.trendingSectors({ days: 7, limit: 10 });
126
- const countries = await client.polymarket.trendingCountries({ days: 7, limit: 10 });
134
+ const trending = await client.polymarket.trending({ limit: 20, type: "stock" });
135
+ const sectors = await client.polymarket.trendingSectors({ limit: 10 });
136
+ const countries = await client.polymarket.trendingCountries({ limit: 10 });
127
137
  const aapl = await client.polymarket.stock("AAPL");
128
- const results = await client.polymarket.search("Apple", { days: 7, limit: 10 });
129
- const comparison = await client.polymarket.compare(["AAPL", "TSLA"], { days: 7 });
130
- const market = await client.polymarket.marketSentiment({ days: 7 });
138
+ const results = await client.polymarket.search("Apple", { limit: 10 });
139
+ const comparison = await client.polymarket.compare(["AAPL", "TSLA"]);
140
+ const market = await client.polymarket.marketSentiment();
141
+ const stats = await client.polymarket.stats();
142
+ const health = await client.polymarket.health();
143
+ ```
144
+
145
+ ### Reddit Crypto
146
+
147
+ ```typescript
148
+ import { AdanosClient } from "finance-sentiment";
149
+
150
+ const client = new AdanosClient({ apiKey: "adanos_api_key_here" });
151
+
152
+ const trending = await client.crypto.trending({ limit: 20 });
153
+ const btc = await client.crypto.token("BTC");
154
+ const mentions = await client.crypto.mentions("BTC", { from: "2026-05-01", to: "2026-05-07", limit: 10, offset: 10 });
155
+ const results = await client.crypto.search("bitcoin", { limit: 10 });
156
+ const comparison = await client.crypto.compare(["BTC", "ETH"]);
157
+ const market = await client.crypto.marketSentiment();
158
+ const stats = await client.crypto.stats();
159
+ const health = await client.crypto.health();
131
160
  ```
132
161
 
133
162
  Polymarket semantics:
134
163
  - `buzz_score` is activity-first and optimized for current market attention
135
- - `total_liquidity` is a windowed signal over the selected `days`
164
+ - `total_liquidity` is a windowed signal over the selected period
165
+ - `current_market_count` is the live-only active-market breadth; `market_count` remains the selected-window breadth
136
166
  - `top_mentions` on `stock()` are relevance-sorted by trading activity first
137
167
 
138
168
  ## Available Methods
139
169
 
170
+ ### `client`
171
+
172
+ | Method | Description |
173
+ |--------|-------------|
174
+ | `health()` | Aggregate API health across all public market sentiment services |
175
+
140
176
  ### `client.reddit.*`
141
177
 
142
178
  | Method | Description |
143
179
  |--------|-------------|
144
- | `trending({ days, limit, offset, type })` | Trending stocks by buzz score |
145
- | `trendingSectors({ days, limit, offset })` | Trending sectors |
146
- | `trendingCountries({ days, limit, offset })` | Trending countries |
147
- | `stock(ticker, { days })` | Detailed sentiment for a ticker |
180
+ | `trending({ from, to, days, limit, offset, type })` | Trending stocks by buzz score |
181
+ | `trendingSectors({ from, to, days, limit, offset })` | Trending sectors |
182
+ | `trendingCountries({ from, to, days, limit, offset })` | Trending countries |
183
+ | `stock(ticker, { from, to, days })` | Detailed sentiment for a ticker |
184
+ | `mentions(ticker, { from, to, days, limit, offset, includeInherited })` | Raw Reddit mention rows |
148
185
  | `explain(ticker)` | AI-generated trend explanation |
149
- | `search(query, { days, limit })` | Search stocks by name or ticker with recent-period summaries |
150
- | `compare(tickers, { days })` | Compare up to 10 stocks |
151
- | `marketSentiment({ days })` | Service-level Reddit market sentiment snapshot |
186
+ | `search(query, { from, to, days, limit })` | Search stocks by name or ticker with recent-period summaries |
187
+ | `compare(tickers, { from, to, days })` | Compare up to 10 stocks |
188
+ | `marketSentiment({ from, to, days })` | Service-level Reddit market sentiment snapshot |
152
189
  | `stats()` | Dataset statistics |
153
190
  | `health()` | Public service health |
154
191
 
192
+ Period options: use `from` and `to` as `YYYY-MM-DD` inclusive UTC dates for reproducible windows. `days` remains available as a legacy shorthand for v1 compatibility. The API returns `422` if `from`, `to`, and `days` are all sent together. Responses keep `period_days`; retain requested dates client-side if you need them later.
193
+
155
194
  ### `client.news.*`
156
195
 
157
196
  | Method | Description |
158
197
  |--------|-------------|
159
- | `trending({ days, limit, offset, type, source })` | Trending stocks from news |
160
- | `trendingSectors({ days, limit, offset, source })` | Trending sectors from news |
161
- | `trendingCountries({ days, limit, offset, source })` | Trending countries from news |
162
- | `stock(ticker, { days })` | Detailed news sentiment for a ticker |
198
+ | `trending({ from, to, days, limit, offset, type, source })` | Trending stocks from news |
199
+ | `trendingSectors({ from, to, days, limit, offset, source })` | Trending sectors from news |
200
+ | `trendingCountries({ from, to, days, limit, offset, source })` | Trending countries from news |
201
+ | `stock(ticker, { from, to, days })` | Detailed news sentiment for a ticker |
202
+ | `mentions(ticker, { from, to, days, limit, offset })` | Raw news mention rows |
163
203
  | `explain(ticker)` | AI-generated explanation from news context |
164
- | `search(query, { days, limit })` | Search stocks in the news dataset with recent-period summaries |
165
- | `compare(tickers, { days })` | Compare up to 10 stocks in news |
166
- | `marketSentiment({ days })` | Service-level News market sentiment snapshot |
204
+ | `search(query, { from, to, days, limit })` | Search stocks in the news dataset with recent-period summaries |
205
+ | `compare(tickers, { from, to, days })` | Compare up to 10 stocks in news |
206
+ | `marketSentiment({ from, to, days })` | Service-level News market sentiment snapshot |
167
207
  | `stats()` | News dataset statistics |
168
208
  | `health()` | Public news service health |
169
209
 
@@ -171,14 +211,15 @@ Polymarket semantics:
171
211
 
172
212
  | Method | Description |
173
213
  |--------|-------------|
174
- | `trending({ days, limit, offset, type })` | Trending stocks on X/Twitter |
175
- | `trendingSectors({ days, limit, offset })` | Trending sectors |
176
- | `trendingCountries({ days, limit, offset })` | Trending countries |
177
- | `stock(ticker, { days })` | Detailed X/Twitter sentiment |
214
+ | `trending({ from, to, days, limit, offset, type })` | Trending stocks on X/Twitter |
215
+ | `trendingSectors({ from, to, days, limit, offset })` | Trending sectors |
216
+ | `trendingCountries({ from, to, days, limit, offset })` | Trending countries |
217
+ | `stock(ticker, { from, to, days })` | Detailed X/Twitter sentiment |
218
+ | `mentions(ticker, { from, to, days, limit, offset })` | Raw X/Twitter mention rows |
178
219
  | `explain(ticker)` | AI-generated explanation from X/Twitter context |
179
- | `search(query, { days, limit })` | Search stocks with recent-period summaries |
180
- | `compare(tickers, { days })` | Compare stocks |
181
- | `marketSentiment({ days })` | Service-level X/Twitter market sentiment snapshot |
220
+ | `search(query, { from, to, days, limit })` | Search stocks with recent-period summaries |
221
+ | `compare(tickers, { from, to, days })` | Compare stocks |
222
+ | `marketSentiment({ from, to, days })` | Service-level X/Twitter market sentiment snapshot |
182
223
  | `stats()` | Dataset statistics |
183
224
  | `health()` | Public service health |
184
225
 
@@ -186,13 +227,27 @@ Polymarket semantics:
186
227
 
187
228
  | Method | Description |
188
229
  |--------|-------------|
189
- | `trending({ days, limit, offset, type })` | Trending stocks on Polymarket with activity-first buzz and windowed liquidity |
190
- | `trendingSectors({ days, limit, offset })` | Trending sectors |
191
- | `trendingCountries({ days, limit, offset })` | Trending countries |
192
- | `stock(ticker, { days })` | Detailed Polymarket activity, sentiment, and relevance-sorted market questions |
193
- | `search(query, { days, limit })` | Search stocks with recent-period summaries |
194
- | `compare(tickers, { days })` | Compare stocks with windowed Polymarket activity signals |
195
- | `marketSentiment({ days })` | Service-level Polymarket market sentiment snapshot |
230
+ | `trending({ from, to, days, limit, offset, type })` | Trending stocks on Polymarket with activity-first buzz and windowed liquidity |
231
+ | `trendingSectors({ from, to, days, limit, offset })` | Trending sectors |
232
+ | `trendingCountries({ from, to, days, limit, offset })` | Trending countries |
233
+ | `stock(ticker, { from, to, days })` | Detailed Polymarket activity, sentiment, and relevance-sorted market questions |
234
+ | `mentions(ticker, { from, to, days, limit, offset })` | Raw Polymarket market snapshots |
235
+ | `search(query, { from, to, days, limit })` | Search stocks with recent-period summaries |
236
+ | `compare(tickers, { from, to, days })` | Compare stocks with windowed Polymarket activity signals |
237
+ | `marketSentiment({ from, to, days })` | Service-level Polymarket market sentiment snapshot |
238
+ | `stats()` | Dataset statistics |
239
+ | `health()` | Public service health |
240
+
241
+ ### `client.crypto.*`
242
+
243
+ | Method | Description |
244
+ |--------|-------------|
245
+ | `trending({ from, to, days, limit, offset })` | Trending Reddit crypto tokens |
246
+ | `token(symbol, { from, to, days })` | Detailed token sentiment and buzz |
247
+ | `mentions(symbol, { from, to, days, limit, offset, includeInherited })` | Raw Reddit crypto mention rows |
248
+ | `search(query, { from, to, days, limit })` | Search tokens by symbol or name with recent-period summaries and market cap metadata |
249
+ | `compare(symbols, { from, to, days })` | Compare multiple tokens |
250
+ | `marketSentiment({ from, to, days })` | Service-level Reddit Crypto market sentiment snapshot |
196
251
  | `stats()` | Dataset statistics |
197
252
  | `health()` | Public service health |
198
253
 
package/dist/index.cjs CHANGED
@@ -47,6 +47,13 @@ var ApiError = class extends StockSentimentError {
47
47
  this.detail = detail;
48
48
  }
49
49
  };
50
+ function periodParams(options) {
51
+ return {
52
+ from: options.from,
53
+ to: options.to,
54
+ days: options.days
55
+ };
56
+ }
50
57
  var HttpClient = class {
51
58
  baseUrl;
52
59
  apiKey;
@@ -105,7 +112,7 @@ var RedditNamespace = class extends PlatformNamespace {
105
112
  /** Get trending stocks on Reddit. */
106
113
  async trending(options = {}) {
107
114
  return this.request("/trending", {
108
- days: options.days,
115
+ ...periodParams(options),
109
116
  limit: options.limit,
110
117
  offset: options.offset,
111
118
  type: options.type
@@ -114,7 +121,7 @@ var RedditNamespace = class extends PlatformNamespace {
114
121
  /** Get trending sectors on Reddit. */
115
122
  async trendingSectors(options = {}) {
116
123
  return this.request("/trending/sectors", {
117
- days: options.days,
124
+ ...periodParams(options),
118
125
  limit: options.limit,
119
126
  offset: options.offset
120
127
  });
@@ -122,7 +129,7 @@ var RedditNamespace = class extends PlatformNamespace {
122
129
  /** Get trending countries on Reddit. */
123
130
  async trendingCountries(options = {}) {
124
131
  return this.request("/trending/countries", {
125
- days: options.days,
132
+ ...periodParams(options),
126
133
  limit: options.limit,
127
134
  offset: options.offset
128
135
  });
@@ -130,14 +137,15 @@ var RedditNamespace = class extends PlatformNamespace {
130
137
  /** Get sentiment for a specific stock ticker. */
131
138
  async stock(ticker, options = {}) {
132
139
  return this.request(`/stock/${encodeURIComponent(ticker)}`, {
133
- days: options.days
140
+ ...periodParams(options)
134
141
  });
135
142
  }
136
143
  /** Get raw Reddit mentions for a specific stock ticker. */
137
144
  async mentions(ticker, options = {}) {
138
145
  return this.request(`/stock/${encodeURIComponent(ticker)}/mentions`, {
139
- days: options.days,
146
+ ...periodParams(options),
140
147
  limit: options.limit,
148
+ offset: options.offset,
141
149
  include_inherited: options.includeInherited?.toString()
142
150
  });
143
151
  }
@@ -149,7 +157,7 @@ var RedditNamespace = class extends PlatformNamespace {
149
157
  async search(query, options = {}) {
150
158
  return this.request("/search", {
151
159
  q: query,
152
- days: options.days,
160
+ ...periodParams(options),
153
161
  limit: options.limit
154
162
  });
155
163
  }
@@ -157,13 +165,13 @@ var RedditNamespace = class extends PlatformNamespace {
157
165
  async compare(tickers, options = {}) {
158
166
  return this.request("/compare", {
159
167
  tickers: tickers.join(","),
160
- days: options.days
168
+ ...periodParams(options)
161
169
  });
162
170
  }
163
171
  /** Get the service-level Reddit market sentiment snapshot. */
164
172
  async marketSentiment(options = {}) {
165
173
  return this.request("/market-sentiment", {
166
- days: options.days
174
+ ...periodParams(options)
167
175
  });
168
176
  }
169
177
  /** Get Reddit stock data statistics. */
@@ -183,7 +191,7 @@ var NewsNamespace = class extends PlatformNamespace {
183
191
  /** Get trending stocks from news. */
184
192
  async trending(options = {}) {
185
193
  return this.request("/trending", {
186
- days: options.days,
194
+ ...periodParams(options),
187
195
  limit: options.limit,
188
196
  offset: options.offset,
189
197
  type: options.type,
@@ -193,7 +201,7 @@ var NewsNamespace = class extends PlatformNamespace {
193
201
  /** Get trending sectors from news. */
194
202
  async trendingSectors(options = {}) {
195
203
  return this.request("/trending/sectors", {
196
- days: options.days,
204
+ ...periodParams(options),
197
205
  limit: options.limit,
198
206
  offset: options.offset,
199
207
  source: options.source
@@ -202,7 +210,7 @@ var NewsNamespace = class extends PlatformNamespace {
202
210
  /** Get trending countries from news. */
203
211
  async trendingCountries(options = {}) {
204
212
  return this.request("/trending/countries", {
205
- days: options.days,
213
+ ...periodParams(options),
206
214
  limit: options.limit,
207
215
  offset: options.offset,
208
216
  source: options.source
@@ -211,14 +219,15 @@ var NewsNamespace = class extends PlatformNamespace {
211
219
  /** Get sentiment for a specific stock ticker from news. */
212
220
  async stock(ticker, options = {}) {
213
221
  return this.request(`/stock/${encodeURIComponent(ticker)}`, {
214
- days: options.days
222
+ ...periodParams(options)
215
223
  });
216
224
  }
217
225
  /** Get raw news mentions for a specific stock ticker. */
218
226
  async mentions(ticker, options = {}) {
219
227
  return this.request(`/stock/${encodeURIComponent(ticker)}/mentions`, {
220
- days: options.days,
221
- limit: options.limit
228
+ ...periodParams(options),
229
+ limit: options.limit,
230
+ offset: options.offset
222
231
  });
223
232
  }
224
233
  /** Get AI-generated explanation for a stock's news trend. */
@@ -229,7 +238,7 @@ var NewsNamespace = class extends PlatformNamespace {
229
238
  async search(query, options = {}) {
230
239
  return this.request("/search", {
231
240
  q: query,
232
- days: options.days,
241
+ ...periodParams(options),
233
242
  limit: options.limit
234
243
  });
235
244
  }
@@ -237,13 +246,13 @@ var NewsNamespace = class extends PlatformNamespace {
237
246
  async compare(tickers, options = {}) {
238
247
  return this.request("/compare", {
239
248
  tickers: tickers.join(","),
240
- days: options.days
249
+ ...periodParams(options)
241
250
  });
242
251
  }
243
252
  /** Get the service-level News market sentiment snapshot. */
244
253
  async marketSentiment(options = {}) {
245
254
  return this.request("/market-sentiment", {
246
- days: options.days
255
+ ...periodParams(options)
247
256
  });
248
257
  }
249
258
  /** Get news data statistics. */
@@ -263,7 +272,7 @@ var XNamespace = class extends PlatformNamespace {
263
272
  /** Get trending stocks on X/Twitter. */
264
273
  async trending(options = {}) {
265
274
  return this.request("/trending", {
266
- days: options.days,
275
+ ...periodParams(options),
267
276
  limit: options.limit,
268
277
  offset: options.offset,
269
278
  type: options.type
@@ -272,7 +281,7 @@ var XNamespace = class extends PlatformNamespace {
272
281
  /** Get trending sectors on X/Twitter. */
273
282
  async trendingSectors(options = {}) {
274
283
  return this.request("/trending/sectors", {
275
- days: options.days,
284
+ ...periodParams(options),
276
285
  limit: options.limit,
277
286
  offset: options.offset
278
287
  });
@@ -280,7 +289,7 @@ var XNamespace = class extends PlatformNamespace {
280
289
  /** Get trending countries on X/Twitter. */
281
290
  async trendingCountries(options = {}) {
282
291
  return this.request("/trending/countries", {
283
- days: options.days,
292
+ ...periodParams(options),
284
293
  limit: options.limit,
285
294
  offset: options.offset
286
295
  });
@@ -288,14 +297,15 @@ var XNamespace = class extends PlatformNamespace {
288
297
  /** Get X/Twitter sentiment for a specific stock ticker. */
289
298
  async stock(ticker, options = {}) {
290
299
  return this.request(`/stock/${encodeURIComponent(ticker)}`, {
291
- days: options.days
300
+ ...periodParams(options)
292
301
  });
293
302
  }
294
303
  /** Get raw X/Twitter mentions for a specific stock ticker. */
295
304
  async mentions(ticker, options = {}) {
296
305
  return this.request(`/stock/${encodeURIComponent(ticker)}/mentions`, {
297
- days: options.days,
298
- limit: options.limit
306
+ ...periodParams(options),
307
+ limit: options.limit,
308
+ offset: options.offset
299
309
  });
300
310
  }
301
311
  /** Get AI-generated explanation for a stock's X/Twitter trend. */
@@ -306,7 +316,7 @@ var XNamespace = class extends PlatformNamespace {
306
316
  async search(query, options = {}) {
307
317
  return this.request("/search", {
308
318
  q: query,
309
- days: options.days,
319
+ ...periodParams(options),
310
320
  limit: options.limit
311
321
  });
312
322
  }
@@ -314,13 +324,13 @@ var XNamespace = class extends PlatformNamespace {
314
324
  async compare(tickers, options = {}) {
315
325
  return this.request("/compare", {
316
326
  tickers: tickers.join(","),
317
- days: options.days
327
+ ...periodParams(options)
318
328
  });
319
329
  }
320
330
  /** Get the service-level X/Twitter market sentiment snapshot. */
321
331
  async marketSentiment(options = {}) {
322
332
  return this.request("/market-sentiment", {
323
- days: options.days
333
+ ...periodParams(options)
324
334
  });
325
335
  }
326
336
  /** Get X/Twitter data statistics. */
@@ -340,7 +350,7 @@ var PolymarketNamespace = class extends PlatformNamespace {
340
350
  /** Get trending stocks on Polymarket. */
341
351
  async trending(options = {}) {
342
352
  return this.request("/trending", {
343
- days: options.days,
353
+ ...periodParams(options),
344
354
  limit: options.limit,
345
355
  offset: options.offset,
346
356
  type: options.type
@@ -349,7 +359,7 @@ var PolymarketNamespace = class extends PlatformNamespace {
349
359
  /** Get trending sectors on Polymarket. */
350
360
  async trendingSectors(options = {}) {
351
361
  return this.request("/trending/sectors", {
352
- days: options.days,
362
+ ...periodParams(options),
353
363
  limit: options.limit,
354
364
  offset: options.offset
355
365
  });
@@ -357,7 +367,7 @@ var PolymarketNamespace = class extends PlatformNamespace {
357
367
  /** Get trending countries on Polymarket. */
358
368
  async trendingCountries(options = {}) {
359
369
  return this.request("/trending/countries", {
360
- days: options.days,
370
+ ...periodParams(options),
361
371
  limit: options.limit,
362
372
  offset: options.offset
363
373
  });
@@ -365,21 +375,22 @@ var PolymarketNamespace = class extends PlatformNamespace {
365
375
  /** Get Polymarket sentiment for a specific stock ticker. */
366
376
  async stock(ticker, options = {}) {
367
377
  return this.request(`/stock/${encodeURIComponent(ticker)}`, {
368
- days: options.days
378
+ ...periodParams(options)
369
379
  });
370
380
  }
371
381
  /** Get raw Polymarket snapshots for a specific stock ticker. */
372
382
  async mentions(ticker, options = {}) {
373
383
  return this.request(`/stock/${encodeURIComponent(ticker)}/mentions`, {
374
- days: options.days,
375
- limit: options.limit
384
+ ...periodParams(options),
385
+ limit: options.limit,
386
+ offset: options.offset
376
387
  });
377
388
  }
378
389
  /** Search for stocks by name or ticker on Polymarket. */
379
390
  async search(query, options = {}) {
380
391
  return this.request("/search", {
381
392
  q: query,
382
- days: options.days,
393
+ ...periodParams(options),
383
394
  limit: options.limit
384
395
  });
385
396
  }
@@ -387,13 +398,13 @@ var PolymarketNamespace = class extends PlatformNamespace {
387
398
  async compare(tickers, options = {}) {
388
399
  return this.request("/compare", {
389
400
  tickers: tickers.join(","),
390
- days: options.days
401
+ ...periodParams(options)
391
402
  });
392
403
  }
393
404
  /** Get the service-level Polymarket market sentiment snapshot. */
394
405
  async marketSentiment(options = {}) {
395
406
  return this.request("/market-sentiment", {
396
- days: options.days
407
+ ...periodParams(options)
397
408
  });
398
409
  }
399
410
  /** Get Polymarket data statistics. */
@@ -413,7 +424,7 @@ var RedditCryptoNamespace = class extends PlatformNamespace {
413
424
  /** Get trending crypto tokens on Reddit. */
414
425
  async trending(options = {}) {
415
426
  return this.request("/trending", {
416
- days: options.days,
427
+ ...periodParams(options),
417
428
  limit: options.limit,
418
429
  offset: options.offset
419
430
  });
@@ -421,14 +432,15 @@ var RedditCryptoNamespace = class extends PlatformNamespace {
421
432
  /** Get sentiment for a specific crypto token. */
422
433
  async token(symbol, options = {}) {
423
434
  return this.request(`/token/${encodeURIComponent(symbol)}`, {
424
- days: options.days
435
+ ...periodParams(options)
425
436
  });
426
437
  }
427
438
  /** Get raw Reddit mentions for a specific crypto token. */
428
439
  async mentions(symbol, options = {}) {
429
440
  return this.request(`/token/${encodeURIComponent(symbol)}/mentions`, {
430
- days: options.days,
441
+ ...periodParams(options),
431
442
  limit: options.limit,
443
+ offset: options.offset,
432
444
  include_inherited: options.includeInherited?.toString()
433
445
  });
434
446
  }
@@ -436,7 +448,7 @@ var RedditCryptoNamespace = class extends PlatformNamespace {
436
448
  async search(query, options = {}) {
437
449
  return this.request("/search", {
438
450
  q: query,
439
- days: options.days,
451
+ ...periodParams(options),
440
452
  limit: options.limit
441
453
  });
442
454
  }
@@ -444,13 +456,13 @@ var RedditCryptoNamespace = class extends PlatformNamespace {
444
456
  async compare(symbols, options = {}) {
445
457
  return this.request("/compare", {
446
458
  symbols: symbols.join(","),
447
- days: options.days
459
+ ...periodParams(options)
448
460
  });
449
461
  }
450
462
  /** Get the service-level Reddit Crypto market sentiment snapshot. */
451
463
  async marketSentiment(options = {}) {
452
464
  return this.request("/market-sentiment", {
453
- days: options.days
465
+ ...periodParams(options)
454
466
  });
455
467
  }
456
468
  /** Get Reddit crypto data statistics. */
@@ -469,6 +481,7 @@ var AdanosClient = class {
469
481
  redditCrypto;
470
482
  x;
471
483
  polymarket;
484
+ http;
472
485
  /**
473
486
  * Create a new Adanos Market Sentiment API client.
474
487
  *
@@ -480,6 +493,7 @@ var AdanosClient = class {
480
493
  const baseUrl = options.baseUrl ?? "https://api.adanos.org";
481
494
  const timeout = options.timeout ?? 3e4;
482
495
  const http = new HttpClient(baseUrl, options.apiKey, timeout);
496
+ this.http = http;
483
497
  this.news = new NewsNamespace(http);
484
498
  this.reddit = new RedditNamespace(http);
485
499
  this.crypto = new RedditCryptoNamespace(http);
@@ -487,6 +501,10 @@ var AdanosClient = class {
487
501
  this.x = new XNamespace(http);
488
502
  this.polymarket = new PolymarketNamespace(http);
489
503
  }
504
+ /** Get aggregate API health across all public market sentiment services. */
505
+ async health() {
506
+ return this.http.get("/health");
507
+ }
490
508
  };
491
509
  var StockSentimentClient = AdanosClient;
492
510
  // Annotate the CommonJS export names for ESM import in node: