@xpoz/xpoz 0.6.9 → 0.6.11

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
@@ -2,7 +2,7 @@
2
2
 
3
3
  [![npm version](https://img.shields.io/npm/v/@xpoz/xpoz)](https://www.npmjs.com/package/@xpoz/xpoz)
4
4
 
5
- TypeScript SDK for the [Xpoz](https://xpoz.ai) social media intelligence platform. Query Twitter/X, Instagram, and Reddit data through a simple, typed interface.
5
+ TypeScript SDK for the [Xpoz](https://xpoz.ai) social media intelligence platform. Query Twitter/X, Instagram, Reddit, and TikTok data through a simple, typed interface.
6
6
 
7
7
  ## Installation
8
8
 
@@ -24,7 +24,7 @@ export XPOZ_API_KEY=your-token-here
24
24
 
25
25
  ## What is Xpoz?
26
26
 
27
- Xpoz provides unified access to social media data across Twitter/X, Instagram, and Reddit. The platform indexes billions of posts, user profiles, and engagement metrics — making it possible to search, analyze, and export social media data at scale.
27
+ Xpoz provides unified access to social media data across Twitter/X, Instagram, Reddit, and TikTok. The platform indexes billions of posts, user profiles, and engagement metrics — making it possible to search, analyze, and export social media data at scale.
28
28
 
29
29
  The SDK wraps Xpoz's [MCP](https://modelcontextprotocol.io) server, abstracting away transport, authentication, operation polling, and pagination into a clean developer-friendly API.
30
30
 
@@ -84,10 +84,14 @@ const client = new XpozClient({ apiKey: "your-api-key", timeoutMs: 600_000 });
84
84
  Want to try the SDK before signing up? Mint a free trial token (no account needed, valid for 5 days):
85
85
 
86
86
  ```bash
87
- curl -X POST https://api.xpoz.ai/api/trial/token
87
+ curl -X POST https://api.xpoz.ai/api/trial/token \
88
+ -H "Content-Type: application/json" \
89
+ -d '{"source": "sdk"}'
88
90
  # -> { "success": true, "data": { "accessKey": "TRIAL...", "expiresInSeconds": 432000 }, ... }
89
91
  ```
90
92
 
93
+ The `source` field is required — it identifies where the trial token request came from (e.g. `skills`, a specific page, `sdk`, `cli`).
94
+
91
95
  Then use the returned token (it starts with `TRIAL`) as your API key:
92
96
 
93
97
  ```typescript
@@ -578,6 +582,16 @@ const comments = await client.reddit.searchComments("helpful tip", {
578
582
  });
579
583
  ```
580
584
 
585
+ #### `getCommentById(commentId, options?) -> Promise<RedditComment>`
586
+
587
+ Fetch a single Reddit comment by its id (bare base36 or `t1_`-prefixed). Database-first with live API fallback when the comment is missing or stale.
588
+
589
+ ```typescript
590
+ const comment = await client.reddit.getCommentById("laz1ytq", {
591
+ fields: ["id", "body", "rank", "removal"],
592
+ });
593
+ ```
594
+
581
595
  #### `searchSubreddits(query, options?) -> Promise<RedditSubreddit[]>`
582
596
 
583
597
  Search subreddits by name. Use `limit` to adjust the number of results.
@@ -793,6 +807,19 @@ for (const bucket of history.credits) {
793
807
 
794
808
  All fields are optional and typed as their respective TypeScript types. Unknown fields are preserved on the object.
795
809
 
810
+ > **Date fields.** Post models expose up to three creation-time fields whose
811
+ > runtime formats differ from what their names suggest:
812
+ >
813
+ > - `createdAt` — full ISO 8601 datetime on Twitter; epoch **seconds** on
814
+ > Reddit/Instagram/TikTok.
815
+ > - `createdAtTimestamp` — full ISO 8601 datetime (Reddit/Instagram/TikTok;
816
+ > not returned for Twitter).
817
+ > - `createdAtDate` — the creation **date only**, rendered as ISO midnight
818
+ > (`2026-07-20T00:00:00.000Z`); it carries no real time-of-day.
819
+ >
820
+ > Depending on response quoting, values can arrive as strings or numbers —
821
+ > treat all three as `string | number`.
822
+
796
823
  ### TwitterPost
797
824
 
798
825
  | Field | Type | Description |
@@ -812,9 +839,13 @@ All fields are optional and typed as their respective TypeScript types. Unknown
812
839
  | `mentions` | `string[]` | Mentioned usernames |
813
840
  | `mediaUrls` | `string[]` | Media attachment URLs |
814
841
  | `urls` | `string[]` | URLs in tweet text |
815
- | `country` | `string` | Country (if geo-tagged) |
816
- | `createdAt` | `string` | Creation timestamp |
817
- | `createdAtDate` | `string` | Creation date (YYYY-MM-DD) |
842
+ | `placeName` | `string` | Tagged place name |
843
+ | `placeCountry` | `string` | Tagged place country |
844
+ | `placeCountryCode` | `string` | Tagged place country code (ISO 3166-1 alpha-2) |
845
+ | `placeBoundingBoxCoordinates` | `unknown` | Tagged place bounding box |
846
+ | `placeCentroid` | `unknown` | Tagged place centroid |
847
+ | `createdAt` | `string \| number` | Creation datetime (ISO 8601) |
848
+ | `createdAtDate` | `string \| number` | Creation date (ISO midnight, no time-of-day) |
818
849
  | `conversationId` | `string` | Thread conversation ID |
819
850
  | `quotedTweetId` | `string` | ID of quoted tweet |
820
851
  | `replyToTweetId` | `string` | ID of parent tweet |
@@ -860,7 +891,9 @@ All fields are optional and typed as their respective TypeScript types. Unknown
860
891
  | `mediaType` | `string` | Media type |
861
892
  | `imageUrl` | `string` | Image URL |
862
893
  | `videoUrl` | `string` | Video URL |
863
- | `createdAtDate` | `string` | Creation date |
894
+ | `createdAt` | `string \| number` | Creation time (epoch seconds) |
895
+ | `createdAtTimestamp` | `string \| number` | Creation datetime (ISO 8601) |
896
+ | `createdAtDate` | `string \| number` | Creation date (ISO midnight, no time-of-day) |
864
897
  | `genAiChatWithAiCtaInfo` | `string` | Gen AI chat CTA info |
865
898
  | `hasHighRiskGenAiInformTreatment` | `boolean` | High risk Gen AI treatment flag |
866
899
 
@@ -907,7 +940,9 @@ All fields are optional and typed as their respective TypeScript types. Unknown
907
940
  | `permalink` | `string` | Reddit permalink |
908
941
  | `isSelf` | `boolean` | Self post (text only) |
909
942
  | `over18` | `boolean` | NSFW flag |
910
- | `createdAtDate` | `string` | Creation date |
943
+ | `createdAt` | `string \| number` | Creation time (epoch seconds) |
944
+ | `createdAtTimestamp` | `string \| number` | Creation datetime (ISO 8601) |
945
+ | `createdAtDate` | `string \| number` | Creation date (ISO midnight, no time-of-day) |
911
946
 
912
947
  ### RedditUser
913
948
 
@@ -972,8 +1007,9 @@ All fields are optional and typed as their respective TypeScript types. Unknown
972
1007
  | `hashtags` | `string[]` | Hashtags in the post |
973
1008
  | `postType` | `number` | Post type code |
974
1009
  | `isPrivate` | `boolean` | Private post flag |
975
- | `createdAt` | `string` | Creation timestamp |
976
- | `createdAtDate` | `string` | Creation date (YYYY-MM-DD) |
1010
+ | `createdAt` | `string \| number` | Creation time (epoch seconds) |
1011
+ | `createdAtTimestamp` | `string \| number` | Creation datetime (ISO 8601) |
1012
+ | `createdAtDate` | `string \| number` | Creation date (ISO midnight, no time-of-day) |
977
1013
 
978
1014
  ### TiktokUser
979
1015
 
package/dist/index.cjs CHANGED
@@ -298,7 +298,7 @@ function coerce(value) {
298
298
  }
299
299
 
300
300
  // src/version.ts
301
- var VERSION = "0.6.9";
301
+ var VERSION = "0.6.11";
302
302
 
303
303
  // src/mcp/transport.ts
304
304
  var USER_AGENT = `xpoz-ts-sdk/${VERSION}`;
@@ -622,6 +622,7 @@ var GET_INSTAGRAM_USERS_BY_KEYWORDS = "getInstagramUsersByKeywords";
622
622
  var SEARCH_REDDIT_POSTS = "getRedditPostsByKeywords";
623
623
  var GET_REDDIT_POST_WITH_COMMENTS = "getRedditPostWithCommentsById";
624
624
  var SEARCH_REDDIT_COMMENTS = "getRedditCommentsByKeywords";
625
+ var GET_REDDIT_COMMENT_BY_ID = "getRedditCommentById";
625
626
  var GET_REDDIT_USER = "getRedditUser";
626
627
  var SEARCH_REDDIT_USERS = "searchRedditUsers";
627
628
  var GET_REDDIT_USERS_BY_KEYWORDS = "getRedditUsersByKeywords";
@@ -980,6 +981,15 @@ var RedditNamespace = class extends BaseNamespace {
980
981
  const result = await this.callAndMaybePoll(SEARCH_REDDIT_COMMENTS, args);
981
982
  return this.buildPaginatedResult(result, parseComment2, SEARCH_REDDIT_COMMENTS, args);
982
983
  }
984
+ async getCommentById(commentId, options = {}) {
985
+ const args = this.buildArgs({ commentId, ...options });
986
+ const result = await this.callAndMaybePoll(GET_REDDIT_COMMENT_BY_ID, args);
987
+ const results = result["results"];
988
+ if (Array.isArray(results) && results.length > 0) {
989
+ return results[0];
990
+ }
991
+ return result;
992
+ }
983
993
  async getUser(username, options = {}) {
984
994
  const args = this.buildArgs({ username, ...options });
985
995
  const result = await this.callAndMaybePoll(GET_REDDIT_USER, args);
package/dist/index.d.cts CHANGED
@@ -80,11 +80,13 @@ interface TwitterPost {
80
80
  mediaUrls?: string[] | null;
81
81
  urls?: string[] | null;
82
82
  grokGeneratedContent?: Record<string, unknown>[] | null;
83
- country?: string | null;
84
- region?: string | null;
85
- city?: string | null;
86
- createdAt?: string | null;
87
- createdAtDate?: string | null;
83
+ placeName?: string | null;
84
+ placeCountry?: string | null;
85
+ placeCountryCode?: string | null;
86
+ placeBoundingBoxCoordinates?: unknown | null;
87
+ placeCentroid?: unknown | null;
88
+ createdAt?: string | number | null;
89
+ createdAtDate?: string | number | null;
88
90
  [key: string]: unknown;
89
91
  }
90
92
  interface TwitterUser {
@@ -118,7 +120,7 @@ interface TwitterUser {
118
120
  verifiedSinceDatetime?: string | null;
119
121
  usernameChanges?: string[] | null;
120
122
  lastUsernameChangeDatetime?: string | null;
121
- createdAt?: string | null;
123
+ createdAt?: string | number | null;
122
124
  modifiedAt?: string | null;
123
125
  aggRelevance?: number | null;
124
126
  relevantTweetsCount?: number | null;
@@ -237,9 +239,9 @@ interface InstagramPost {
237
239
  location?: string | null;
238
240
  genAiChatWithAiCtaInfo?: string | null;
239
241
  hasHighRiskGenAiInformTreatment?: boolean | null;
240
- createdAt?: string | null;
241
- createdAtTimestamp?: number | null;
242
- createdAtDate?: string | null;
242
+ createdAt?: string | number | null;
243
+ createdAtTimestamp?: string | number | null;
244
+ createdAtDate?: string | number | null;
243
245
  [key: string]: unknown;
244
246
  }
245
247
  interface InstagramUser {
@@ -281,9 +283,9 @@ interface InstagramComment {
281
283
  status?: string | null;
282
284
  isSpam?: boolean | null;
283
285
  hasTranslation?: boolean | null;
284
- createdAt?: string | null;
285
- createdAtTimestamp?: number | null;
286
- createdAtDate?: string | null;
286
+ createdAt?: string | number | null;
287
+ createdAtTimestamp?: string | number | null;
288
+ createdAtDate?: string | number | null;
287
289
  [key: string]: unknown;
288
290
  }
289
291
 
@@ -372,9 +374,12 @@ interface RedditPost {
372
374
  postHint?: string | null;
373
375
  domain?: string | null;
374
376
  crosspostParent?: string | null;
375
- createdAt?: string | null;
376
- createdAtTimestamp?: number | null;
377
- createdAtDate?: string | null;
377
+ selftextHtml?: string | null;
378
+ editedAt?: string | null;
379
+ removal?: Record<string, unknown> | null;
380
+ createdAt?: string | number | null;
381
+ createdAtTimestamp?: string | number | null;
382
+ createdAtDate?: string | number | null;
378
383
  [key: string]: unknown;
379
384
  }
380
385
  interface RedditUser {
@@ -402,9 +407,9 @@ interface RedditUser {
402
407
  profileDescription?: string | null;
403
408
  profileBannerUrl?: string | null;
404
409
  profileTitle?: string | null;
405
- createdAt?: string | null;
406
- createdAtTimestamp?: number | null;
407
- createdAtDate?: string | null;
410
+ createdAt?: string | number | null;
411
+ createdAtTimestamp?: string | number | null;
412
+ createdAtDate?: string | number | null;
408
413
  aggRelevance?: number | null;
409
414
  relevantPostsCount?: number | null;
410
415
  relevantPostsUpvotesSum?: number | null;
@@ -430,9 +435,14 @@ interface RedditComment {
430
435
  collapsed?: boolean | null;
431
436
  edited?: boolean | null;
432
437
  distinguished?: string | null;
433
- createdAt?: string | null;
434
- createdAtTimestamp?: number | null;
435
- createdAtDate?: string | null;
438
+ rank?: number | null;
439
+ topLevelRank?: number | null;
440
+ collapsedReasonCode?: string | null;
441
+ collapsedReason?: string | null;
442
+ removal?: Record<string, unknown> | null;
443
+ createdAt?: string | number | null;
444
+ createdAtTimestamp?: string | number | null;
445
+ createdAtDate?: string | number | null;
436
446
  [key: string]: unknown;
437
447
  }
438
448
  interface RedditSubreddit {
@@ -444,6 +454,7 @@ interface RedditSubreddit {
444
454
  subscribersCount?: number | null;
445
455
  activeUserCount?: number | null;
446
456
  subredditType?: string | null;
457
+ submissionType?: string | null;
447
458
  over18?: boolean | null;
448
459
  lang?: string | null;
449
460
  url?: string | null;
@@ -452,9 +463,9 @@ interface RedditSubreddit {
452
463
  bannerImg?: string | null;
453
464
  headerImg?: string | null;
454
465
  communityIcon?: string | null;
455
- createdAt?: string | null;
456
- createdAtTimestamp?: number | null;
457
- createdAtDate?: string | null;
466
+ createdAt?: string | number | null;
467
+ createdAtTimestamp?: string | number | null;
468
+ createdAtDate?: string | number | null;
458
469
  aggRelevance?: number | null;
459
470
  relevantPostsCount?: number | null;
460
471
  relevantPostsUpvotesSum?: number | null;
@@ -497,6 +508,10 @@ declare class RedditNamespace extends BaseNamespace {
497
508
  endDate?: string;
498
509
  subreddit?: string;
499
510
  }): Promise<PaginatedResult<RedditComment>>;
511
+ getCommentById(commentId: string, options?: {
512
+ fields?: string[];
513
+ forceLatest?: boolean;
514
+ }): Promise<RedditComment>;
500
515
  getUser(username: string, options?: {
501
516
  fields?: string[];
502
517
  forceLatest?: boolean;
@@ -551,9 +566,9 @@ interface TiktokPost {
551
566
  duration?: number | null;
552
567
  videoUrl?: string[] | null;
553
568
  transcriptsJson?: Record<string, string> | null;
554
- createdAt?: string | null;
555
- createdAtTimestamp?: number | null;
556
- createdAtDate?: string | null;
569
+ createdAt?: string | number | null;
570
+ createdAtTimestamp?: string | number | null;
571
+ createdAtDate?: string | number | null;
557
572
  [key: string]: unknown;
558
573
  }
559
574
  interface TiktokUser {
@@ -571,7 +586,7 @@ interface TiktokUser {
571
586
  postCount?: number | null;
572
587
  language?: string | null;
573
588
  region?: string | null;
574
- createdAt?: string | null;
589
+ createdAt?: string | number | null;
575
590
  usernameModifyTime?: string | null;
576
591
  aggRelevance?: number | null;
577
592
  relevantPostsCount?: number | null;
@@ -588,9 +603,9 @@ interface TiktokComment {
588
603
  username?: string | null;
589
604
  text?: string | null;
590
605
  likeCount?: number | null;
591
- createdAt?: string | null;
592
- createdAtTimestamp?: number | null;
593
- createdAtDate?: string | null;
606
+ createdAt?: string | number | null;
607
+ createdAtTimestamp?: string | number | null;
608
+ createdAtDate?: string | number | null;
594
609
  [key: string]: unknown;
595
610
  }
596
611
  interface TiktokSound {
@@ -817,7 +832,7 @@ declare class OperationCancelledError extends XpozError {
817
832
  constructor(operationId: string);
818
833
  }
819
834
 
820
- declare const VERSION = "0.6.9";
835
+ declare const VERSION = "0.6.11";
821
836
 
822
837
  declare function checkForUpdates(): Promise<void>;
823
838
 
package/dist/index.d.ts CHANGED
@@ -80,11 +80,13 @@ interface TwitterPost {
80
80
  mediaUrls?: string[] | null;
81
81
  urls?: string[] | null;
82
82
  grokGeneratedContent?: Record<string, unknown>[] | null;
83
- country?: string | null;
84
- region?: string | null;
85
- city?: string | null;
86
- createdAt?: string | null;
87
- createdAtDate?: string | null;
83
+ placeName?: string | null;
84
+ placeCountry?: string | null;
85
+ placeCountryCode?: string | null;
86
+ placeBoundingBoxCoordinates?: unknown | null;
87
+ placeCentroid?: unknown | null;
88
+ createdAt?: string | number | null;
89
+ createdAtDate?: string | number | null;
88
90
  [key: string]: unknown;
89
91
  }
90
92
  interface TwitterUser {
@@ -118,7 +120,7 @@ interface TwitterUser {
118
120
  verifiedSinceDatetime?: string | null;
119
121
  usernameChanges?: string[] | null;
120
122
  lastUsernameChangeDatetime?: string | null;
121
- createdAt?: string | null;
123
+ createdAt?: string | number | null;
122
124
  modifiedAt?: string | null;
123
125
  aggRelevance?: number | null;
124
126
  relevantTweetsCount?: number | null;
@@ -237,9 +239,9 @@ interface InstagramPost {
237
239
  location?: string | null;
238
240
  genAiChatWithAiCtaInfo?: string | null;
239
241
  hasHighRiskGenAiInformTreatment?: boolean | null;
240
- createdAt?: string | null;
241
- createdAtTimestamp?: number | null;
242
- createdAtDate?: string | null;
242
+ createdAt?: string | number | null;
243
+ createdAtTimestamp?: string | number | null;
244
+ createdAtDate?: string | number | null;
243
245
  [key: string]: unknown;
244
246
  }
245
247
  interface InstagramUser {
@@ -281,9 +283,9 @@ interface InstagramComment {
281
283
  status?: string | null;
282
284
  isSpam?: boolean | null;
283
285
  hasTranslation?: boolean | null;
284
- createdAt?: string | null;
285
- createdAtTimestamp?: number | null;
286
- createdAtDate?: string | null;
286
+ createdAt?: string | number | null;
287
+ createdAtTimestamp?: string | number | null;
288
+ createdAtDate?: string | number | null;
287
289
  [key: string]: unknown;
288
290
  }
289
291
 
@@ -372,9 +374,12 @@ interface RedditPost {
372
374
  postHint?: string | null;
373
375
  domain?: string | null;
374
376
  crosspostParent?: string | null;
375
- createdAt?: string | null;
376
- createdAtTimestamp?: number | null;
377
- createdAtDate?: string | null;
377
+ selftextHtml?: string | null;
378
+ editedAt?: string | null;
379
+ removal?: Record<string, unknown> | null;
380
+ createdAt?: string | number | null;
381
+ createdAtTimestamp?: string | number | null;
382
+ createdAtDate?: string | number | null;
378
383
  [key: string]: unknown;
379
384
  }
380
385
  interface RedditUser {
@@ -402,9 +407,9 @@ interface RedditUser {
402
407
  profileDescription?: string | null;
403
408
  profileBannerUrl?: string | null;
404
409
  profileTitle?: string | null;
405
- createdAt?: string | null;
406
- createdAtTimestamp?: number | null;
407
- createdAtDate?: string | null;
410
+ createdAt?: string | number | null;
411
+ createdAtTimestamp?: string | number | null;
412
+ createdAtDate?: string | number | null;
408
413
  aggRelevance?: number | null;
409
414
  relevantPostsCount?: number | null;
410
415
  relevantPostsUpvotesSum?: number | null;
@@ -430,9 +435,14 @@ interface RedditComment {
430
435
  collapsed?: boolean | null;
431
436
  edited?: boolean | null;
432
437
  distinguished?: string | null;
433
- createdAt?: string | null;
434
- createdAtTimestamp?: number | null;
435
- createdAtDate?: string | null;
438
+ rank?: number | null;
439
+ topLevelRank?: number | null;
440
+ collapsedReasonCode?: string | null;
441
+ collapsedReason?: string | null;
442
+ removal?: Record<string, unknown> | null;
443
+ createdAt?: string | number | null;
444
+ createdAtTimestamp?: string | number | null;
445
+ createdAtDate?: string | number | null;
436
446
  [key: string]: unknown;
437
447
  }
438
448
  interface RedditSubreddit {
@@ -444,6 +454,7 @@ interface RedditSubreddit {
444
454
  subscribersCount?: number | null;
445
455
  activeUserCount?: number | null;
446
456
  subredditType?: string | null;
457
+ submissionType?: string | null;
447
458
  over18?: boolean | null;
448
459
  lang?: string | null;
449
460
  url?: string | null;
@@ -452,9 +463,9 @@ interface RedditSubreddit {
452
463
  bannerImg?: string | null;
453
464
  headerImg?: string | null;
454
465
  communityIcon?: string | null;
455
- createdAt?: string | null;
456
- createdAtTimestamp?: number | null;
457
- createdAtDate?: string | null;
466
+ createdAt?: string | number | null;
467
+ createdAtTimestamp?: string | number | null;
468
+ createdAtDate?: string | number | null;
458
469
  aggRelevance?: number | null;
459
470
  relevantPostsCount?: number | null;
460
471
  relevantPostsUpvotesSum?: number | null;
@@ -497,6 +508,10 @@ declare class RedditNamespace extends BaseNamespace {
497
508
  endDate?: string;
498
509
  subreddit?: string;
499
510
  }): Promise<PaginatedResult<RedditComment>>;
511
+ getCommentById(commentId: string, options?: {
512
+ fields?: string[];
513
+ forceLatest?: boolean;
514
+ }): Promise<RedditComment>;
500
515
  getUser(username: string, options?: {
501
516
  fields?: string[];
502
517
  forceLatest?: boolean;
@@ -551,9 +566,9 @@ interface TiktokPost {
551
566
  duration?: number | null;
552
567
  videoUrl?: string[] | null;
553
568
  transcriptsJson?: Record<string, string> | null;
554
- createdAt?: string | null;
555
- createdAtTimestamp?: number | null;
556
- createdAtDate?: string | null;
569
+ createdAt?: string | number | null;
570
+ createdAtTimestamp?: string | number | null;
571
+ createdAtDate?: string | number | null;
557
572
  [key: string]: unknown;
558
573
  }
559
574
  interface TiktokUser {
@@ -571,7 +586,7 @@ interface TiktokUser {
571
586
  postCount?: number | null;
572
587
  language?: string | null;
573
588
  region?: string | null;
574
- createdAt?: string | null;
589
+ createdAt?: string | number | null;
575
590
  usernameModifyTime?: string | null;
576
591
  aggRelevance?: number | null;
577
592
  relevantPostsCount?: number | null;
@@ -588,9 +603,9 @@ interface TiktokComment {
588
603
  username?: string | null;
589
604
  text?: string | null;
590
605
  likeCount?: number | null;
591
- createdAt?: string | null;
592
- createdAtTimestamp?: number | null;
593
- createdAtDate?: string | null;
606
+ createdAt?: string | number | null;
607
+ createdAtTimestamp?: string | number | null;
608
+ createdAtDate?: string | number | null;
594
609
  [key: string]: unknown;
595
610
  }
596
611
  interface TiktokSound {
@@ -817,7 +832,7 @@ declare class OperationCancelledError extends XpozError {
817
832
  constructor(operationId: string);
818
833
  }
819
834
 
820
- declare const VERSION = "0.6.9";
835
+ declare const VERSION = "0.6.11";
821
836
 
822
837
  declare function checkForUpdates(): Promise<void>;
823
838
 
package/dist/index.js CHANGED
@@ -248,7 +248,7 @@ function coerce(value) {
248
248
  }
249
249
 
250
250
  // src/version.ts
251
- var VERSION = "0.6.9";
251
+ var VERSION = "0.6.11";
252
252
 
253
253
  // src/mcp/transport.ts
254
254
  var USER_AGENT = `xpoz-ts-sdk/${VERSION}`;
@@ -572,6 +572,7 @@ var GET_INSTAGRAM_USERS_BY_KEYWORDS = "getInstagramUsersByKeywords";
572
572
  var SEARCH_REDDIT_POSTS = "getRedditPostsByKeywords";
573
573
  var GET_REDDIT_POST_WITH_COMMENTS = "getRedditPostWithCommentsById";
574
574
  var SEARCH_REDDIT_COMMENTS = "getRedditCommentsByKeywords";
575
+ var GET_REDDIT_COMMENT_BY_ID = "getRedditCommentById";
575
576
  var GET_REDDIT_USER = "getRedditUser";
576
577
  var SEARCH_REDDIT_USERS = "searchRedditUsers";
577
578
  var GET_REDDIT_USERS_BY_KEYWORDS = "getRedditUsersByKeywords";
@@ -930,6 +931,15 @@ var RedditNamespace = class extends BaseNamespace {
930
931
  const result = await this.callAndMaybePoll(SEARCH_REDDIT_COMMENTS, args);
931
932
  return this.buildPaginatedResult(result, parseComment2, SEARCH_REDDIT_COMMENTS, args);
932
933
  }
934
+ async getCommentById(commentId, options = {}) {
935
+ const args = this.buildArgs({ commentId, ...options });
936
+ const result = await this.callAndMaybePoll(GET_REDDIT_COMMENT_BY_ID, args);
937
+ const results = result["results"];
938
+ if (Array.isArray(results) && results.length > 0) {
939
+ return results[0];
940
+ }
941
+ return result;
942
+ }
933
943
  async getUser(username, options = {}) {
934
944
  const args = this.buildArgs({ username, ...options });
935
945
  const result = await this.callAndMaybePoll(GET_REDDIT_USER, args);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xpoz/xpoz",
3
- "version": "0.6.9",
3
+ "version": "0.6.11",
4
4
  "description": "TypeScript SDK for the Xpoz social media intelligence platform",
5
5
  "type": "module",
6
6
  "main": "./dist/index.cjs",