@keystrokehq/reddit 0.1.3 → 0.1.5
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/dist/action.cjs.map +1 -1
- package/dist/action.mjs.map +1 -1
- package/dist/actions/create-reddit-post.cjs +1 -0
- package/dist/actions/create-reddit-post.cjs.map +1 -1
- package/dist/actions/create-reddit-post.d.cts +3 -8
- package/dist/actions/create-reddit-post.d.cts.map +1 -1
- package/dist/actions/create-reddit-post.d.mts +3 -8
- package/dist/actions/create-reddit-post.d.mts.map +1 -1
- package/dist/actions/create-reddit-post.mjs +1 -0
- package/dist/actions/create-reddit-post.mjs.map +1 -1
- package/dist/actions/delete-reddit-comment.cjs +1 -0
- package/dist/actions/delete-reddit-comment.cjs.map +1 -1
- package/dist/actions/delete-reddit-comment.d.cts +3 -3
- package/dist/actions/delete-reddit-comment.d.cts.map +1 -1
- package/dist/actions/delete-reddit-comment.d.mts +3 -3
- package/dist/actions/delete-reddit-comment.d.mts.map +1 -1
- package/dist/actions/delete-reddit-comment.mjs +1 -0
- package/dist/actions/delete-reddit-comment.mjs.map +1 -1
- package/dist/actions/delete-reddit-post.cjs +1 -0
- package/dist/actions/delete-reddit-post.cjs.map +1 -1
- package/dist/actions/delete-reddit-post.d.cts +3 -3
- package/dist/actions/delete-reddit-post.d.cts.map +1 -1
- package/dist/actions/delete-reddit-post.d.mts +3 -3
- package/dist/actions/delete-reddit-post.d.mts.map +1 -1
- package/dist/actions/delete-reddit-post.mjs +1 -0
- package/dist/actions/delete-reddit-post.mjs.map +1 -1
- package/dist/actions/edit-reddit-comment-or-post.cjs +1 -0
- package/dist/actions/edit-reddit-comment-or-post.cjs.map +1 -1
- package/dist/actions/edit-reddit-comment-or-post.d.cts +3 -4
- package/dist/actions/edit-reddit-comment-or-post.d.cts.map +1 -1
- package/dist/actions/edit-reddit-comment-or-post.d.mts +3 -4
- package/dist/actions/edit-reddit-comment-or-post.d.mts.map +1 -1
- package/dist/actions/edit-reddit-comment-or-post.mjs +1 -0
- package/dist/actions/edit-reddit-comment-or-post.mjs.map +1 -1
- package/dist/actions/get-controversial-posts.cjs +1 -0
- package/dist/actions/get-controversial-posts.cjs.map +1 -1
- package/dist/actions/get-controversial-posts.d.cts +3 -6
- package/dist/actions/get-controversial-posts.d.cts.map +1 -1
- package/dist/actions/get-controversial-posts.d.mts +3 -6
- package/dist/actions/get-controversial-posts.d.mts.map +1 -1
- package/dist/actions/get-controversial-posts.mjs +1 -0
- package/dist/actions/get-controversial-posts.mjs.map +1 -1
- package/dist/actions/get-me-prefs.cjs +1 -0
- package/dist/actions/get-me-prefs.cjs.map +1 -1
- package/dist/actions/get-me-prefs.d.cts +3 -3
- package/dist/actions/get-me-prefs.d.cts.map +1 -1
- package/dist/actions/get-me-prefs.d.mts +3 -3
- package/dist/actions/get-me-prefs.d.mts.map +1 -1
- package/dist/actions/get-me-prefs.mjs +1 -0
- package/dist/actions/get-me-prefs.mjs.map +1 -1
- package/dist/actions/get-r-top.cjs +1 -0
- package/dist/actions/get-r-top.cjs.map +1 -1
- package/dist/actions/get-r-top.d.cts +3 -10
- package/dist/actions/get-r-top.d.cts.map +1 -1
- package/dist/actions/get-r-top.d.mts +3 -10
- package/dist/actions/get-r-top.d.mts.map +1 -1
- package/dist/actions/get-r-top.mjs +1 -0
- package/dist/actions/get-r-top.mjs.map +1 -1
- package/dist/actions/get-random.cjs +1 -0
- package/dist/actions/get-random.cjs.map +1 -1
- package/dist/actions/get-random.d.cts +3 -3
- package/dist/actions/get-random.d.cts.map +1 -1
- package/dist/actions/get-random.d.mts +3 -3
- package/dist/actions/get-random.d.mts.map +1 -1
- package/dist/actions/get-random.mjs +1 -0
- package/dist/actions/get-random.mjs.map +1 -1
- package/dist/actions/get-reddit-user-about.cjs +1 -0
- package/dist/actions/get-reddit-user-about.cjs.map +1 -1
- package/dist/actions/get-reddit-user-about.d.cts +3 -3
- package/dist/actions/get-reddit-user-about.d.cts.map +1 -1
- package/dist/actions/get-reddit-user-about.d.mts +3 -3
- package/dist/actions/get-reddit-user-about.d.mts.map +1 -1
- package/dist/actions/get-reddit-user-about.mjs +1 -0
- package/dist/actions/get-reddit-user-about.mjs.map +1 -1
- package/dist/actions/get-scopes.cjs +1 -0
- package/dist/actions/get-scopes.cjs.map +1 -1
- package/dist/actions/get-scopes.d.cts +3 -1
- package/dist/actions/get-scopes.d.cts.map +1 -1
- package/dist/actions/get-scopes.d.mts +3 -1
- package/dist/actions/get-scopes.d.mts.map +1 -1
- package/dist/actions/get-scopes.mjs +1 -0
- package/dist/actions/get-scopes.mjs.map +1 -1
- package/dist/actions/get-subreddit-rules.cjs +1 -0
- package/dist/actions/get-subreddit-rules.cjs.map +1 -1
- package/dist/actions/get-subreddit-rules.d.cts +3 -4
- package/dist/actions/get-subreddit-rules.d.cts.map +1 -1
- package/dist/actions/get-subreddit-rules.d.mts +3 -4
- package/dist/actions/get-subreddit-rules.d.mts.map +1 -1
- package/dist/actions/get-subreddit-rules.mjs +1 -0
- package/dist/actions/get-subreddit-rules.mjs.map +1 -1
- package/dist/actions/get-subreddits-search.cjs +1 -0
- package/dist/actions/get-subreddits-search.cjs.map +1 -1
- package/dist/actions/get-subreddits-search.d.cts +3 -11
- package/dist/actions/get-subreddits-search.d.cts.map +1 -1
- package/dist/actions/get-subreddits-search.d.mts +3 -11
- package/dist/actions/get-subreddits-search.d.mts.map +1 -1
- package/dist/actions/get-subreddits-search.mjs +1 -0
- package/dist/actions/get-subreddits-search.mjs.map +1 -1
- package/dist/actions/get-user-flair.cjs +1 -0
- package/dist/actions/get-user-flair.cjs.map +1 -1
- package/dist/actions/get-user-flair.d.cts +3 -6
- package/dist/actions/get-user-flair.d.cts.map +1 -1
- package/dist/actions/get-user-flair.d.mts +3 -6
- package/dist/actions/get-user-flair.d.mts.map +1 -1
- package/dist/actions/get-user-flair.mjs +1 -0
- package/dist/actions/get-user-flair.mjs.map +1 -1
- package/dist/actions/get-username-available.cjs +1 -0
- package/dist/actions/get-username-available.cjs.map +1 -1
- package/dist/actions/get-username-available.d.cts +3 -3
- package/dist/actions/get-username-available.d.cts.map +1 -1
- package/dist/actions/get-username-available.d.mts +3 -3
- package/dist/actions/get-username-available.d.mts.map +1 -1
- package/dist/actions/get-username-available.mjs +1 -0
- package/dist/actions/get-username-available.mjs.map +1 -1
- package/dist/actions/get.cjs +1 -0
- package/dist/actions/get.cjs.map +1 -1
- package/dist/actions/get.d.cts +3 -9
- package/dist/actions/get.d.cts.map +1 -1
- package/dist/actions/get.d.mts +3 -9
- package/dist/actions/get.d.mts.map +1 -1
- package/dist/actions/get.mjs +1 -0
- package/dist/actions/get.mjs.map +1 -1
- package/dist/actions/list-subreddit-post-flairs.cjs +1 -0
- package/dist/actions/list-subreddit-post-flairs.cjs.map +1 -1
- package/dist/actions/list-subreddit-post-flairs.d.cts +3 -3
- package/dist/actions/list-subreddit-post-flairs.d.cts.map +1 -1
- package/dist/actions/list-subreddit-post-flairs.d.mts +3 -3
- package/dist/actions/list-subreddit-post-flairs.d.mts.map +1 -1
- package/dist/actions/list-subreddit-post-flairs.mjs +1 -0
- package/dist/actions/list-subreddit-post-flairs.mjs.map +1 -1
- package/dist/actions/post-reddit-comment.cjs +1 -0
- package/dist/actions/post-reddit-comment.cjs.map +1 -1
- package/dist/actions/post-reddit-comment.d.cts +3 -4
- package/dist/actions/post-reddit-comment.d.cts.map +1 -1
- package/dist/actions/post-reddit-comment.d.mts +3 -4
- package/dist/actions/post-reddit-comment.d.mts.map +1 -1
- package/dist/actions/post-reddit-comment.mjs +1 -0
- package/dist/actions/post-reddit-comment.mjs.map +1 -1
- package/dist/actions/retrieve-post-comments.cjs +1 -0
- package/dist/actions/retrieve-post-comments.cjs.map +1 -1
- package/dist/actions/retrieve-post-comments.d.cts +3 -3
- package/dist/actions/retrieve-post-comments.d.cts.map +1 -1
- package/dist/actions/retrieve-post-comments.d.mts +3 -3
- package/dist/actions/retrieve-post-comments.d.mts.map +1 -1
- package/dist/actions/retrieve-post-comments.mjs +1 -0
- package/dist/actions/retrieve-post-comments.mjs.map +1 -1
- package/dist/actions/retrieve-reddit-post.cjs +1 -0
- package/dist/actions/retrieve-reddit-post.cjs.map +1 -1
- package/dist/actions/retrieve-reddit-post.d.cts +3 -5
- package/dist/actions/retrieve-reddit-post.d.cts.map +1 -1
- package/dist/actions/retrieve-reddit-post.d.mts +3 -5
- package/dist/actions/retrieve-reddit-post.d.mts.map +1 -1
- package/dist/actions/retrieve-reddit-post.mjs +1 -0
- package/dist/actions/retrieve-reddit-post.mjs.map +1 -1
- package/dist/actions/retrieve-specific-comment.cjs +1 -0
- package/dist/actions/retrieve-specific-comment.cjs.map +1 -1
- package/dist/actions/retrieve-specific-comment.d.cts +3 -3
- package/dist/actions/retrieve-specific-comment.d.cts.map +1 -1
- package/dist/actions/retrieve-specific-comment.d.mts +3 -3
- package/dist/actions/retrieve-specific-comment.d.mts.map +1 -1
- package/dist/actions/retrieve-specific-comment.mjs +1 -0
- package/dist/actions/retrieve-specific-comment.mjs.map +1 -1
- package/dist/actions/search-across-subreddits.cjs +1 -0
- package/dist/actions/search-across-subreddits.cjs.map +1 -1
- package/dist/actions/search-across-subreddits.d.cts +4 -9
- package/dist/actions/search-across-subreddits.d.cts.map +1 -1
- package/dist/actions/search-across-subreddits.d.mts +4 -9
- package/dist/actions/search-across-subreddits.d.mts.map +1 -1
- package/dist/actions/search-across-subreddits.mjs +1 -0
- package/dist/actions/search-across-subreddits.mjs.map +1 -1
- package/dist/actions/toggle-inbox-replies.cjs +1 -0
- package/dist/actions/toggle-inbox-replies.cjs.map +1 -1
- package/dist/actions/toggle-inbox-replies.d.cts +3 -4
- package/dist/actions/toggle-inbox-replies.d.cts.map +1 -1
- package/dist/actions/toggle-inbox-replies.d.mts +3 -4
- package/dist/actions/toggle-inbox-replies.d.mts.map +1 -1
- package/dist/actions/toggle-inbox-replies.mjs +1 -0
- package/dist/actions/toggle-inbox-replies.mjs.map +1 -1
- package/dist/app.cjs +5 -2
- package/dist/app.cjs.map +1 -1
- package/dist/app.d.cts +7 -1
- package/dist/app.d.cts.map +1 -1
- package/dist/app.d.mts +7 -1
- package/dist/app.d.mts.map +1 -1
- package/dist/app.mjs +3 -2
- package/dist/app.mjs.map +1 -1
- package/dist/index.d.cts +1 -1
- package/dist/index.d.mts +1 -1
- package/package.json +2 -2
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
import { reddit } from "../app.cjs";
|
|
2
|
+
import { AppAction } from "@keystrokehq/keystroke/app";
|
|
1
3
|
import { z } from "zod";
|
|
2
4
|
|
|
3
5
|
//#region src/actions/post-reddit-comment.d.ts
|
|
@@ -51,10 +53,7 @@ declare const RedditPostRedditCommentOutput: z.ZodObject<{
|
|
|
51
53
|
}, z.core.$loose>>;
|
|
52
54
|
composio_execution_message: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
53
55
|
}, z.core.$loose>;
|
|
54
|
-
declare const redditPostRedditComment:
|
|
55
|
-
text: string;
|
|
56
|
-
thing_id: string;
|
|
57
|
-
}, unknown, import("@keystrokehq/shared").ResolvedCredentials<readonly [import("@keystrokehq/shared").Credential]>, readonly [import("@keystrokehq/shared").Credential]>;
|
|
56
|
+
declare const redditPostRedditComment: AppAction<typeof RedditPostRedditCommentInput, typeof RedditPostRedditCommentOutput, typeof reddit.credential>;
|
|
58
57
|
//#endregion
|
|
59
58
|
export { redditPostRedditComment };
|
|
60
59
|
//# sourceMappingURL=post-reddit-comment.d.cts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"post-reddit-comment.d.cts","names":[],"sources":["../../src/actions/post-reddit-comment.ts"],"mappings":"
|
|
1
|
+
{"version":3,"file":"post-reddit-comment.d.cts","names":[],"sources":["../../src/actions/post-reddit-comment.ts"],"mappings":";;;;;cAMa,4BAAA,EAA4B,CAAA,CAAA,SAAA;;;;cAkD5B,6BAAA,EAA6B,CAAA,CAAA,SAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;cAK7B,uBAAA,EAAyB,SAAA,QAC7B,4BAAA,SACA,6BAAA,SACA,MAAA,CAAO,UAAA"}
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
import { reddit } from "../app.mjs";
|
|
2
|
+
import { AppAction } from "@keystrokehq/keystroke/app";
|
|
1
3
|
import { z } from "zod";
|
|
2
4
|
|
|
3
5
|
//#region src/actions/post-reddit-comment.d.ts
|
|
@@ -51,10 +53,7 @@ declare const RedditPostRedditCommentOutput: z.ZodObject<{
|
|
|
51
53
|
}, z.core.$loose>>;
|
|
52
54
|
composio_execution_message: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
53
55
|
}, z.core.$loose>;
|
|
54
|
-
declare const redditPostRedditComment:
|
|
55
|
-
text: string;
|
|
56
|
-
thing_id: string;
|
|
57
|
-
}, unknown, import("@keystrokehq/shared").ResolvedCredentials<readonly [import("@keystrokehq/shared").Credential]>, readonly [import("@keystrokehq/shared").Credential]>;
|
|
56
|
+
declare const redditPostRedditComment: AppAction<typeof RedditPostRedditCommentInput, typeof RedditPostRedditCommentOutput, typeof reddit.credential>;
|
|
58
57
|
//#endregion
|
|
59
58
|
export { redditPostRedditComment };
|
|
60
59
|
//# sourceMappingURL=post-reddit-comment.d.mts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"post-reddit-comment.d.mts","names":[],"sources":["../../src/actions/post-reddit-comment.ts"],"mappings":"
|
|
1
|
+
{"version":3,"file":"post-reddit-comment.d.mts","names":[],"sources":["../../src/actions/post-reddit-comment.ts"],"mappings":";;;;;cAMa,4BAAA,EAA4B,CAAA,CAAA,SAAA;;;;cAkD5B,6BAAA,EAA6B,CAAA,CAAA,SAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;cAK7B,uBAAA,EAAyB,SAAA,QAC7B,4BAAA,SACA,6BAAA,SACA,MAAA,CAAO,UAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"post-reddit-comment.mjs","names":[],"sources":["../../src/actions/post-reddit-comment.ts"],"sourcesContent":["import { z } from \"zod\";\n\nimport { action } from \"../action\";\n\nexport const RedditPostRedditCommentInput = z.object({\n text: z.string().describe(\"REQUIRED. The raw Markdown text of the comment to be submitted. This field must be provided and cannot be empty.\"),\n thing_id: z.string().describe(\"REQUIRED. The ID of the parent post (link) or comment, prefixed with 't3_' for a post (e.g., 't3_10omtdx') or 't1_' for a comment (e.g., 't1_h2g9w8l'). This field must be provided.\"),\n});\nconst RedditPostRedditComment_CommentDataSchema = z.object({\n id: z.string().describe(\"Unique identifier of the comment\").nullable(),\n ups: z.number().int().describe(\"Number of upvotes (includes own vote if upvoted)\").nullable(),\n body: z.string().describe(\"Raw comment text content with Markdown formatting; HTML entities are escaped\").nullable(),\n name: z.string().describe(\"Fullname of the comment combining kind and id (e.g., 't1_c3v7f8u')\").nullable(),\n depth: z.number().int().describe(\"Nesting level of the comment; 0 for top-level comments, 1 for first-level replies, etc.\").nullable().optional(),\n downs: z.number().int().describe(\"Number of downvotes (includes own vote if downvoted)\").nullable(),\n likes: z.boolean().describe(\"Vote status: true if upvoted, false if downvoted, null if no vote or not logged in\").nullable().optional(),\n saved: z.boolean().describe(\"Whether the logged-in user has saved this comment\").nullable(),\n score: z.number().int().describe(\"Net score (upvotes minus downvotes) of the comment\").nullable(),\n author: z.string().describe(\"Username of the comment author\").nullable(),\n edited: z.union([z.boolean(), z.number()]),\n gilded: z.number().int().describe(\"Number of Reddit Gold awards the comment has received\").nullable(),\n created: z.number().describe(\"Unix timestamp when the comment was created in local time (epoch seconds)\").nullable(),\n link_id: z.string().describe(\"ID of the parent submission (prefixed with 't3_')\").nullable(),\n replies: z.union([z.record(z.string(), z.unknown()), z.string()]),\n link_url: z.string().describe(\"URL of the parent submission (when comment displayed outside thread context)\").nullable().optional(),\n stickied: z.boolean().describe(\"Whether the comment is stickied/pinned\").nullable(),\n banned_by: z.string().describe(\"Username of moderator who removed the comment; null if none or user lacks privileges\").nullable().optional(),\n body_html: z.string().describe(\"Formatted HTML version of the comment text as displayed on Reddit\").nullable(),\n parent_id: z.string().describe(\"ID of the parent comment (prefixed with 't1_') or submission (prefixed with 't3_')\").nullable(),\n permalink: z.string().describe(\"Permanent URL path to the comment\").nullable(),\n subreddit: z.string().describe(\"Name of the subreddit excluding the '/r/' prefix\").nullable(),\n link_title: z.string().describe(\"Title of the parent submission (when comment displayed outside thread context)\").nullable().optional(),\n approved_by: z.string().describe(\"Username of moderator who approved the comment; null if none or user lacks privileges\").nullable().optional(),\n created_utc: z.number().describe(\"Unix timestamp when the comment was created in UTC (epoch seconds)\").nullable(),\n link_author: z.string().describe(\"Author of the parent submission (when comment displayed outside thread context)\").nullable().optional(),\n num_reports: z.number().int().describe(\"Number of reports on the comment; null if user is not a moderator\").nullable().optional(),\n is_submitter: z.boolean().describe(\"Whether the comment author is also the submission author\").nullable(),\n score_hidden: z.boolean().describe(\"Whether the comment's score is currently hidden\").nullable(),\n subreddit_id: z.string().describe(\"Unique identifier of the subreddit\").nullable(),\n distinguished: z.string().describe(\"Moderator status: null (normal user), 'moderator' (green [M]), 'admin' (red [A]), or 'special'\").nullable().optional(),\n author_flair_text: z.string().describe(\"Text content of the author's user flair in this subreddit\").nullable().optional(),\n author_flair_css_class: z.string().describe(\"CSS class for styling the author's user flair\").nullable().optional(),\n}).passthrough().describe(\"The comment object data returned by Reddit API.\");\nconst RedditPostRedditComment_CommentThingSchema = z.object({\n data: RedditPostRedditComment_CommentDataSchema.nullable(),\n kind: z.string().describe(\"Type identifier for the object; 't1' for comments\").nullable(),\n}).passthrough().describe(\"A Reddit 'thing' containing a comment.\");\nconst RedditPostRedditComment_CommentResponseDataSchema = z.object({\n things: z.array(RedditPostRedditComment_CommentThingSchema).describe(\"Array containing the created comment object(s)\"),\n}).passthrough().describe(\"Container for the created comment objects.\");\nconst RedditPostRedditComment_CommentJsonWrapperSchema = z.object({\n data: RedditPostRedditComment_CommentResponseDataSchema.nullable(),\n errors: z.array(z.union([z.string(), z.array(z.string())])).describe(\"Array of errors encountered during the API call; empty array if successful\"),\n}).passthrough().describe(\"Wrapper object containing the API response.\");\nexport const RedditPostRedditCommentOutput = z.object({\n json: RedditPostRedditComment_CommentJsonWrapperSchema.nullable(),\n composio_execution_message: z.string().describe(\"Informational message about the execution, such as platform limitations encountered\").nullable().optional(),\n}).passthrough().describe(\"Response from posting a comment on Reddit.\");\n\nexport const redditPostRedditComment = action(\"REDDIT_POST_REDDIT_COMMENT\", {\n slug: \"reddit-post-reddit-comment\",\n name: \"Post a comment\",\n description: \"Posts a comment on Reddit, replying to an existing submission (post) or another comment. Fails if the target thread is locked, archived, or restricted — verify thread state beforehand. Rapid successive calls trigger Reddit RATELIMIT errors with explicit cooldown hints (e.g., 'take a break for 9 minutes'); honor the specified wait before retrying. A successful API response does not guarantee public visibility — automod or spam filters may silently remove the comment. Publishes immediately and publicly; confirm target and text before executing.\",\n input: RedditPostRedditCommentInput,\n output: RedditPostRedditCommentOutput,\n});\n"],"mappings":";;;AAIA,MAAa,+BAA+B,EAAE,OAAO;CACnD,MAAM,EAAE,OAAO,CAAC,CAAC,SAAS,kHAAkH;CAC5I,UAAU,EAAE,OAAO,CAAC,CAAC,SAAS,sLAAsL;AACtN,CAAC;AACD,MAAM,4CAA4C,EAAE,OAAO;CACzD,IAAI,EAAE,OAAO,CAAC,CAAC,SAAS,kCAAkC,CAAC,CAAC,SAAS;CACrE,KAAK,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS,kDAAkD,CAAC,CAAC,SAAS;CAC5F,MAAM,EAAE,OAAO,CAAC,CAAC,SAAS,8EAA8E,CAAC,CAAC,SAAS;CACnH,MAAM,EAAE,OAAO,CAAC,CAAC,SAAS,oEAAoE,CAAC,CAAC,SAAS;CACzG,OAAO,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS,yFAAyF,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CAChJ,OA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C,SAAS,wCAAwC;AAClE,MAAM,oDAAoD,EAAE,OAAO,EACjE,QAAQ,EAAE,MAAM,0CAA0C,CAAC,CAAC,SAAS,gDAAgD,EACvH,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC,SAAS,4CAA4C;AACtE,MAAM,mDAAmD,EAAE,OAAO;CAChE,MAAM,kDAAkD,SAAS;CACjE,QAAQ,EAAE,MAAM,EAAE,MAAM,CAAC,EAAE,OAAO,GAAG,EAAE,MAAM,EAAE,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,SAAS,4EAA4E;AACnJ,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC,SAAS,6CAA6C;AAMvE,MAAa,0BAA0B,OAAO,8BAA8B;CAC1E,MAAM;CACN,MAAM;CACN,aAAa;CACb,OAAO;CACP,QAV2C,EAAE,OAAO;EACpD,MAAM,iDAAiD,SAAS;EAChE,4BAA4B,EAAE,OAAO,CAAC,CAAC,SAAS,qFAAqF,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CAC7J,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC,SAAS,4CAOhB;AACV,CAAC"}
|
|
1
|
+
{"version":3,"file":"post-reddit-comment.mjs","names":[],"sources":["../../src/actions/post-reddit-comment.ts"],"sourcesContent":["import type { AppAction } from \"@keystrokehq/keystroke/app\";\nimport { z } from \"zod\";\n\nimport { action } from \"../action\";\nimport { reddit } from \"../app\";\n\nexport const RedditPostRedditCommentInput = z.object({\n text: z.string().describe(\"REQUIRED. The raw Markdown text of the comment to be submitted. This field must be provided and cannot be empty.\"),\n thing_id: z.string().describe(\"REQUIRED. The ID of the parent post (link) or comment, prefixed with 't3_' for a post (e.g., 't3_10omtdx') or 't1_' for a comment (e.g., 't1_h2g9w8l'). This field must be provided.\"),\n});\nconst RedditPostRedditComment_CommentDataSchema = z.object({\n id: z.string().describe(\"Unique identifier of the comment\").nullable(),\n ups: z.number().int().describe(\"Number of upvotes (includes own vote if upvoted)\").nullable(),\n body: z.string().describe(\"Raw comment text content with Markdown formatting; HTML entities are escaped\").nullable(),\n name: z.string().describe(\"Fullname of the comment combining kind and id (e.g., 't1_c3v7f8u')\").nullable(),\n depth: z.number().int().describe(\"Nesting level of the comment; 0 for top-level comments, 1 for first-level replies, etc.\").nullable().optional(),\n downs: z.number().int().describe(\"Number of downvotes (includes own vote if downvoted)\").nullable(),\n likes: z.boolean().describe(\"Vote status: true if upvoted, false if downvoted, null if no vote or not logged in\").nullable().optional(),\n saved: z.boolean().describe(\"Whether the logged-in user has saved this comment\").nullable(),\n score: z.number().int().describe(\"Net score (upvotes minus downvotes) of the comment\").nullable(),\n author: z.string().describe(\"Username of the comment author\").nullable(),\n edited: z.union([z.boolean(), z.number()]),\n gilded: z.number().int().describe(\"Number of Reddit Gold awards the comment has received\").nullable(),\n created: z.number().describe(\"Unix timestamp when the comment was created in local time (epoch seconds)\").nullable(),\n link_id: z.string().describe(\"ID of the parent submission (prefixed with 't3_')\").nullable(),\n replies: z.union([z.record(z.string(), z.unknown()), z.string()]),\n link_url: z.string().describe(\"URL of the parent submission (when comment displayed outside thread context)\").nullable().optional(),\n stickied: z.boolean().describe(\"Whether the comment is stickied/pinned\").nullable(),\n banned_by: z.string().describe(\"Username of moderator who removed the comment; null if none or user lacks privileges\").nullable().optional(),\n body_html: z.string().describe(\"Formatted HTML version of the comment text as displayed on Reddit\").nullable(),\n parent_id: z.string().describe(\"ID of the parent comment (prefixed with 't1_') or submission (prefixed with 't3_')\").nullable(),\n permalink: z.string().describe(\"Permanent URL path to the comment\").nullable(),\n subreddit: z.string().describe(\"Name of the subreddit excluding the '/r/' prefix\").nullable(),\n link_title: z.string().describe(\"Title of the parent submission (when comment displayed outside thread context)\").nullable().optional(),\n approved_by: z.string().describe(\"Username of moderator who approved the comment; null if none or user lacks privileges\").nullable().optional(),\n created_utc: z.number().describe(\"Unix timestamp when the comment was created in UTC (epoch seconds)\").nullable(),\n link_author: z.string().describe(\"Author of the parent submission (when comment displayed outside thread context)\").nullable().optional(),\n num_reports: z.number().int().describe(\"Number of reports on the comment; null if user is not a moderator\").nullable().optional(),\n is_submitter: z.boolean().describe(\"Whether the comment author is also the submission author\").nullable(),\n score_hidden: z.boolean().describe(\"Whether the comment's score is currently hidden\").nullable(),\n subreddit_id: z.string().describe(\"Unique identifier of the subreddit\").nullable(),\n distinguished: z.string().describe(\"Moderator status: null (normal user), 'moderator' (green [M]), 'admin' (red [A]), or 'special'\").nullable().optional(),\n author_flair_text: z.string().describe(\"Text content of the author's user flair in this subreddit\").nullable().optional(),\n author_flair_css_class: z.string().describe(\"CSS class for styling the author's user flair\").nullable().optional(),\n}).passthrough().describe(\"The comment object data returned by Reddit API.\");\nconst RedditPostRedditComment_CommentThingSchema = z.object({\n data: RedditPostRedditComment_CommentDataSchema.nullable(),\n kind: z.string().describe(\"Type identifier for the object; 't1' for comments\").nullable(),\n}).passthrough().describe(\"A Reddit 'thing' containing a comment.\");\nconst RedditPostRedditComment_CommentResponseDataSchema = z.object({\n things: z.array(RedditPostRedditComment_CommentThingSchema).describe(\"Array containing the created comment object(s)\"),\n}).passthrough().describe(\"Container for the created comment objects.\");\nconst RedditPostRedditComment_CommentJsonWrapperSchema = z.object({\n data: RedditPostRedditComment_CommentResponseDataSchema.nullable(),\n errors: z.array(z.union([z.string(), z.array(z.string())])).describe(\"Array of errors encountered during the API call; empty array if successful\"),\n}).passthrough().describe(\"Wrapper object containing the API response.\");\nexport const RedditPostRedditCommentOutput = z.object({\n json: RedditPostRedditComment_CommentJsonWrapperSchema.nullable(),\n composio_execution_message: z.string().describe(\"Informational message about the execution, such as platform limitations encountered\").nullable().optional(),\n}).passthrough().describe(\"Response from posting a comment on Reddit.\");\n\nexport const redditPostRedditComment: AppAction<\n typeof RedditPostRedditCommentInput,\n typeof RedditPostRedditCommentOutput,\n typeof reddit.credential\n> = action(\"REDDIT_POST_REDDIT_COMMENT\", {\n slug: \"reddit-post-reddit-comment\",\n name: \"Post a comment\",\n description: \"Posts a comment on Reddit, replying to an existing submission (post) or another comment. Fails if the target thread is locked, archived, or restricted — verify thread state beforehand. Rapid successive calls trigger Reddit RATELIMIT errors with explicit cooldown hints (e.g., 'take a break for 9 minutes'); honor the specified wait before retrying. A successful API response does not guarantee public visibility — automod or spam filters may silently remove the comment. Publishes immediately and publicly; confirm target and text before executing.\",\n input: RedditPostRedditCommentInput,\n output: RedditPostRedditCommentOutput,\n});\n"],"mappings":";;;;AAMA,MAAa,+BAA+B,EAAE,OAAO;CACnD,MAAM,EAAE,OAAO,CAAC,CAAC,SAAS,kHAAkH;CAC5I,UAAU,EAAE,OAAO,CAAC,CAAC,SAAS,sLAAsL;AACtN,CAAC;AACD,MAAM,4CAA4C,EAAE,OAAO;CACzD,IAAI,EAAE,OAAO,CAAC,CAAC,SAAS,kCAAkC,CAAC,CAAC,SAAS;CACrE,KAAK,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS,kDAAkD,CAAC,CAAC,SAAS;CAC5F,MAAM,EAAE,OAAO,CAAC,CAAC,SAAS,8EAA8E,CAAC,CAAC,SAAS;CACnH,MAAM,EAAE,OAAO,CAAC,CAAC,SAAS,oEAAoE,CAAC,CAAC,SAAS;CACzG,OAAO,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS,yFAAyF,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CAChJ,OAAO,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS,sDAAsD,CAAC,CAAC,SAAS;CAClG,OAAO,EAAE,QAAQ,CAAC,CAAC,SAAS,oFAAoF,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CACtI,OAAO,EAAE,QAAQ,CAAC,CAAC,SAAS,mDAAmD,CAAC,CAAC,SAAS;CAC1F,OAAO,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS,oDAAoD,CAAC,CAAC,SAAS;CAChG,QAAQ,EAAE,OAAO,CAAC,CAAC,SAAS,gCAAgC,CA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C,CAAC,YAAY,CAAC,CAAC,SAAS,6CAA6C;AAMvE,MAAa,0BAIT,OAAO,8BAA8B;CACvC,MAAM;CACN,MAAM;CACN,aAAa;CACb,OAAO;CACP,QAd2C,EAAE,OAAO;EACpD,MAAM,iDAAiD,SAAS;EAChE,4BAA4B,EAAE,OAAO,CAAC,CAAC,SAAS,qFAAqF,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CAC7J,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC,SAAS,4CAWhB;AACV,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"retrieve-post-comments.cjs","names":["z","action"],"sources":["../../src/actions/retrieve-post-comments.ts"],"sourcesContent":["import { z } from \"zod\";\n\nimport { action } from \"../action\";\n\nexport const RedditRetrievePostCommentsInput = z.object({\n article: z.string().describe(\"Base-36 ID of the Reddit post (e.g., 'q5u7q5'), typically found in the post's URL and not including the 't3_' prefix.\"),\n});\nconst RedditRetrievePostComments_PostDataSchema = z.object({\n id: z.string().describe(\"Unique identifier of the post in base36 format.\").nullable().optional(),\n url: z.string().describe(\"URL the post links to, or the permalink if a self post.\").nullable().optional(),\n score: z.number().int().describe(\"Net score of the post (upvotes minus downvotes).\").nullable().optional(),\n title: z.string().describe(\"The title of the post.\").nullable().optional(),\n author: z.string().describe(\"Username of the post author, null if deleted.\").nullable().optional(),\n is_self: z.boolean().describe(\"Whether the post is a self/text post (true) or link post (false).\").nullable().optional(),\n over_18: z.boolean().describe(\"Whether the post is marked as NSFW.\").nullable().optional(),\n selftext: z.string().describe(\"Raw body text for self/text posts with markdown.\").nullable().optional(),\n permalink: z.string().describe(\"Relative URL path to the permanent link of the post.\").nullable().optional(),\n subreddit: z.string().describe(\"Name of the subreddit without the /r/ prefix.\").nullable().optional(),\n created_utc: z.number().describe(\"Unix timestamp of post creation in UTC epoch-seconds.\").nullable().optional(),\n num_comments: z.number().int().describe(\"Total number of comments.\").nullable().optional(),\n}).passthrough().describe(\"Optimized data attributes for a Reddit post (t3 kind).\");\nconst RedditRetrievePostComments_PostThingSchema = z.object({\n data: RedditRetrievePostComments_PostDataSchema.nullable(),\n kind: z.string().describe(\"Type identifier, always 't3' for posts.\").nullable(),\n}).passthrough().describe(\"Wrapped post object with kind and data.\");\nconst RedditRetrievePostComments_PostListingDataSchema = z.object({\n dist: z.number().int().describe(\"Number of items in this listing.\").nullable().optional(),\n after: z.string().describe(\"Fullname of the listing that follows after this page.\").nullable().optional(),\n before: z.string().describe(\"Fullname of the listing that follows before this page.\").nullable().optional(),\n modhash: z.string().describe(\"Modhash for authentication purposes.\").nullable().optional(),\n children: z.array(RedditRetrievePostComments_PostThingSchema).describe(\"Array containing the post object.\"),\n geo_filter: z.string().describe(\"Geographic filter applied to the listing.\").nullable().optional(),\n}).passthrough().describe(\"Container object for the first listing containing the post.\");\nconst RedditRetrievePostComments_PostListingSchema = z.object({\n data: RedditRetrievePostComments_PostListingDataSchema.nullable(),\n kind: z.string().describe(\"Always 'Listing' for this object type.\").nullable(),\n}).passthrough().describe(\"Reddit API Listing object containing the post (first listing in response).\");\nconst RedditRetrievePostComments_CommentDataSchema = z.object({\n id: z.string().describe(\"Unique identifier of the comment in base36 format.\").nullable().optional(),\n body: z.string().describe(\"Raw text of the comment with markdown.\").nullable().optional(),\n name: z.string().describe(\"Fullname of the comment (e.g., 't1_abc123').\").nullable().optional(),\n depth: z.number().int().describe(\"Depth level in the comment tree (0 = top-level).\").nullable().optional(),\n score: z.number().int().describe(\"Net score (upvotes minus downvotes).\").nullable().optional(),\n author: z.string().describe(\"Username of the comment author, null if deleted.\").nullable().optional(),\n parent_id: z.string().describe(\"Fullname of the parent comment (t1_) or post (t3_).\").nullable().optional(),\n permalink: z.string().describe(\"Permanent link to the comment.\").nullable().optional(),\n created_utc: z.number().describe(\"Unix timestamp of creation in UTC epoch-seconds.\").nullable().optional(),\n has_replies: z.boolean().describe(\"Whether this comment has nested replies.\").nullable().optional(),\n is_submitter: z.boolean().describe(\"Whether the author is also the post submitter.\").nullable().optional(),\n distinguished: z.string().describe(\"Special status: null, 'moderator', 'admin', or 'special'.\").nullable().optional(),\n}).passthrough().describe(\"Optimized data attributes for a Reddit comment (t1 kind).\");\nconst RedditRetrievePostComments_CommentThingSchema = z.object({\n data: RedditRetrievePostComments_CommentDataSchema.nullable(),\n kind: z.string().describe(\"Type identifier, always 't1' for comments.\").nullable(),\n}).passthrough().describe(\"Wrapped comment object with kind and data.\");\nconst RedditRetrievePostComments_MoreDataSchema = z.object({\n id: z.string().describe(\"Identifier for this more object.\").nullable().optional(),\n name: z.string().describe(\"Fullname of this more object.\").nullable().optional(),\n count: z.number().int().describe(\"Number of additional comments available.\").nullable().optional(),\n depth: z.number().int().describe(\"Depth level in the comment tree.\").nullable().optional(),\n children: z.array(z.string()).describe(\"Array of comment IDs that can be loaded using the morechildren endpoint.\").nullable().optional(),\n parent_id: z.string().describe(\"Fullname of the parent comment or post.\").nullable().optional(),\n}).passthrough().describe(\"Data for a 'more' object that holds IDs of additional comments to load.\");\nconst RedditRetrievePostComments_MoreThingSchema = z.object({\n data: RedditRetrievePostComments_MoreDataSchema.nullable(),\n kind: z.string().describe(\"Type identifier, always 'more'.\").nullable(),\n}).passthrough().describe(\"Wrapped 'more' object for loading additional comments.\");\nconst RedditRetrievePostComments_CommentListingDataSchema = z.object({\n dist: z.number().int().describe(\"Number of items in this listing.\").nullable().optional(),\n after: z.string().describe(\"Fullname of the listing that follows after this page.\").nullable().optional(),\n before: z.string().describe(\"Fullname of the listing that follows before this page.\").nullable().optional(),\n modhash: z.string().describe(\"Modhash for authentication purposes.\").nullable().optional(),\n children: z.array(z.union([RedditRetrievePostComments_CommentThingSchema, RedditRetrievePostComments_MoreThingSchema])).describe(\"Array of comment objects and 'more' placeholders.\"),\n geo_filter: z.string().describe(\"Geographic filter applied to the listing.\").nullable().optional(),\n}).passthrough().describe(\"Container object for the second listing containing comments.\");\nconst RedditRetrievePostComments_CommentListingSchema = z.object({\n data: RedditRetrievePostComments_CommentListingDataSchema.nullable(),\n kind: z.string().describe(\"Always 'Listing' for this object type.\").nullable(),\n}).passthrough().describe(\"Reddit API Listing object containing comments (second listing in response).\");\nexport const RedditRetrievePostCommentsOutput = z.object({\n post_listing: RedditRetrievePostComments_PostListingSchema.nullable(),\n comments_listing: RedditRetrievePostComments_CommentListingSchema.nullable(),\n}).passthrough().describe(\"Response containing two Listing objects from Reddit API.\\nThe first listing contains the submission/post object, and the second\\nlisting contains the top-level comments with nested replies.\");\n\nexport const redditRetrievePostComments = action(\"REDDIT_RETRIEVE_POST_COMMENTS\", {\n slug: \"reddit-retrieve-post-comments\",\n name: \"Retrieve Comments for a Post\",\n description: \"Retrieves all comments for a Reddit post given its base-36 article ID. Response is a two-element listings array: post metadata in `listings[0]`; comments in `listings[1].data.children` with text at each `[].data.body` and nested replies under each comment's `replies` field. Replies require recursive traversal to capture full discussion. Large, locked, or archived threads may return truncated trees or `more` placeholders rather than full results. Filter out comments where `body` is `[deleted]` or `[removed]`; use `parent_id` to reconstruct conversation flow. No time-filter parameter — compare `created_utc` against a UTC cutoff to filter by date.\",\n input: RedditRetrievePostCommentsInput,\n output: RedditRetrievePostCommentsOutput,\n});\n"],"mappings":";;;AAIA,MAAa,kCAAkCA,IAAAA,EAAE,OAAO,EACtD,SAASA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,uHAAuH,EACtJ,CAAC;AACD,MAAM,4CAA4CA,IAAAA,EAAE,OAAO;CACzD,IAAIA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,iDAAiD,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CAC/F,KAAKA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,yDAAyD,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CACxG,OAAOA,IAAAA,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS,kDAAkD,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CACzG,OAAOA,IAAAA,EAAE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C,SAAS,mDAAmD;CACpL,YAAYA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,2CAA2C,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;AACnG,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC,SAAS,8DAA8D;AACxF,MAAM,kDAAkDA,IAAAA,EAAE,OAAO;CAC/D,MAAM,oDAAoD,SAAS;CACnE,MAAMA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,wCAAwC,CAAC,CAAC,SAAS;AAC/E,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC,SAAS,6EAA6E;AACvG,MAAa,mCAAmCA,IAAAA,EAAE,OAAO;CACvD,cAAc,6CAA6C,SAAS;CACpE,kBAAkB,gDAAgD,SAAS;AAC7E,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC,SAAS,+LAA+L;AAEzN,MAAa,6BAA6BC,eAAAA,OAAO,iCAAiC;CAChF,MAAM;CACN,MAAM;CACN,aAAa;CACb,OAAO;CACP,QAAQ;AACV,CAAC"}
|
|
1
|
+
{"version":3,"file":"retrieve-post-comments.cjs","names":["z","action"],"sources":["../../src/actions/retrieve-post-comments.ts"],"sourcesContent":["import type { AppAction } from \"@keystrokehq/keystroke/app\";\nimport { z } from \"zod\";\n\nimport { action } from \"../action\";\nimport { reddit } from \"../app\";\n\nexport const RedditRetrievePostCommentsInput = z.object({\n article: z.string().describe(\"Base-36 ID of the Reddit post (e.g., 'q5u7q5'), typically found in the post's URL and not including the 't3_' prefix.\"),\n});\nconst RedditRetrievePostComments_PostDataSchema = z.object({\n id: z.string().describe(\"Unique identifier of the post in base36 format.\").nullable().optional(),\n url: z.string().describe(\"URL the post links to, or the permalink if a self post.\").nullable().optional(),\n score: z.number().int().describe(\"Net score of the post (upvotes minus downvotes).\").nullable().optional(),\n title: z.string().describe(\"The title of the post.\").nullable().optional(),\n author: z.string().describe(\"Username of the post author, null if deleted.\").nullable().optional(),\n is_self: z.boolean().describe(\"Whether the post is a self/text post (true) or link post (false).\").nullable().optional(),\n over_18: z.boolean().describe(\"Whether the post is marked as NSFW.\").nullable().optional(),\n selftext: z.string().describe(\"Raw body text for self/text posts with markdown.\").nullable().optional(),\n permalink: z.string().describe(\"Relative URL path to the permanent link of the post.\").nullable().optional(),\n subreddit: z.string().describe(\"Name of the subreddit without the /r/ prefix.\").nullable().optional(),\n created_utc: z.number().describe(\"Unix timestamp of post creation in UTC epoch-seconds.\").nullable().optional(),\n num_comments: z.number().int().describe(\"Total number of comments.\").nullable().optional(),\n}).passthrough().describe(\"Optimized data attributes for a Reddit post (t3 kind).\");\nconst RedditRetrievePostComments_PostThingSchema = z.object({\n data: RedditRetrievePostComments_PostDataSchema.nullable(),\n kind: z.string().describe(\"Type identifier, always 't3' for posts.\").nullable(),\n}).passthrough().describe(\"Wrapped post object with kind and data.\");\nconst RedditRetrievePostComments_PostListingDataSchema = z.object({\n dist: z.number().int().describe(\"Number of items in this listing.\").nullable().optional(),\n after: z.string().describe(\"Fullname of the listing that follows after this page.\").nullable().optional(),\n before: z.string().describe(\"Fullname of the listing that follows before this page.\").nullable().optional(),\n modhash: z.string().describe(\"Modhash for authentication purposes.\").nullable().optional(),\n children: z.array(RedditRetrievePostComments_PostThingSchema).describe(\"Array containing the post object.\"),\n geo_filter: z.string().describe(\"Geographic filter applied to the listing.\").nullable().optional(),\n}).passthrough().describe(\"Container object for the first listing containing the post.\");\nconst RedditRetrievePostComments_PostListingSchema = z.object({\n data: RedditRetrievePostComments_PostListingDataSchema.nullable(),\n kind: z.string().describe(\"Always 'Listing' for this object type.\").nullable(),\n}).passthrough().describe(\"Reddit API Listing object containing the post (first listing in response).\");\nconst RedditRetrievePostComments_CommentDataSchema = z.object({\n id: z.string().describe(\"Unique identifier of the comment in base36 format.\").nullable().optional(),\n body: z.string().describe(\"Raw text of the comment with markdown.\").nullable().optional(),\n name: z.string().describe(\"Fullname of the comment (e.g., 't1_abc123').\").nullable().optional(),\n depth: z.number().int().describe(\"Depth level in the comment tree (0 = top-level).\").nullable().optional(),\n score: z.number().int().describe(\"Net score (upvotes minus downvotes).\").nullable().optional(),\n author: z.string().describe(\"Username of the comment author, null if deleted.\").nullable().optional(),\n parent_id: z.string().describe(\"Fullname of the parent comment (t1_) or post (t3_).\").nullable().optional(),\n permalink: z.string().describe(\"Permanent link to the comment.\").nullable().optional(),\n created_utc: z.number().describe(\"Unix timestamp of creation in UTC epoch-seconds.\").nullable().optional(),\n has_replies: z.boolean().describe(\"Whether this comment has nested replies.\").nullable().optional(),\n is_submitter: z.boolean().describe(\"Whether the author is also the post submitter.\").nullable().optional(),\n distinguished: z.string().describe(\"Special status: null, 'moderator', 'admin', or 'special'.\").nullable().optional(),\n}).passthrough().describe(\"Optimized data attributes for a Reddit comment (t1 kind).\");\nconst RedditRetrievePostComments_CommentThingSchema = z.object({\n data: RedditRetrievePostComments_CommentDataSchema.nullable(),\n kind: z.string().describe(\"Type identifier, always 't1' for comments.\").nullable(),\n}).passthrough().describe(\"Wrapped comment object with kind and data.\");\nconst RedditRetrievePostComments_MoreDataSchema = z.object({\n id: z.string().describe(\"Identifier for this more object.\").nullable().optional(),\n name: z.string().describe(\"Fullname of this more object.\").nullable().optional(),\n count: z.number().int().describe(\"Number of additional comments available.\").nullable().optional(),\n depth: z.number().int().describe(\"Depth level in the comment tree.\").nullable().optional(),\n children: z.array(z.string()).describe(\"Array of comment IDs that can be loaded using the morechildren endpoint.\").nullable().optional(),\n parent_id: z.string().describe(\"Fullname of the parent comment or post.\").nullable().optional(),\n}).passthrough().describe(\"Data for a 'more' object that holds IDs of additional comments to load.\");\nconst RedditRetrievePostComments_MoreThingSchema = z.object({\n data: RedditRetrievePostComments_MoreDataSchema.nullable(),\n kind: z.string().describe(\"Type identifier, always 'more'.\").nullable(),\n}).passthrough().describe(\"Wrapped 'more' object for loading additional comments.\");\nconst RedditRetrievePostComments_CommentListingDataSchema = z.object({\n dist: z.number().int().describe(\"Number of items in this listing.\").nullable().optional(),\n after: z.string().describe(\"Fullname of the listing that follows after this page.\").nullable().optional(),\n before: z.string().describe(\"Fullname of the listing that follows before this page.\").nullable().optional(),\n modhash: z.string().describe(\"Modhash for authentication purposes.\").nullable().optional(),\n children: z.array(z.union([RedditRetrievePostComments_CommentThingSchema, RedditRetrievePostComments_MoreThingSchema])).describe(\"Array of comment objects and 'more' placeholders.\"),\n geo_filter: z.string().describe(\"Geographic filter applied to the listing.\").nullable().optional(),\n}).passthrough().describe(\"Container object for the second listing containing comments.\");\nconst RedditRetrievePostComments_CommentListingSchema = z.object({\n data: RedditRetrievePostComments_CommentListingDataSchema.nullable(),\n kind: z.string().describe(\"Always 'Listing' for this object type.\").nullable(),\n}).passthrough().describe(\"Reddit API Listing object containing comments (second listing in response).\");\nexport const RedditRetrievePostCommentsOutput = z.object({\n post_listing: RedditRetrievePostComments_PostListingSchema.nullable(),\n comments_listing: RedditRetrievePostComments_CommentListingSchema.nullable(),\n}).passthrough().describe(\"Response containing two Listing objects from Reddit API.\\nThe first listing contains the submission/post object, and the second\\nlisting contains the top-level comments with nested replies.\");\n\nexport const redditRetrievePostComments: AppAction<\n typeof RedditRetrievePostCommentsInput,\n typeof RedditRetrievePostCommentsOutput,\n typeof reddit.credential\n> = action(\"REDDIT_RETRIEVE_POST_COMMENTS\", {\n slug: \"reddit-retrieve-post-comments\",\n name: \"Retrieve Comments for a Post\",\n description: \"Retrieves all comments for a Reddit post given its base-36 article ID. Response is a two-element listings array: post metadata in `listings[0]`; comments in `listings[1].data.children` with text at each `[].data.body` and nested replies under each comment's `replies` field. Replies require recursive traversal to capture full discussion. Large, locked, or archived threads may return truncated trees or `more` placeholders rather than full results. Filter out comments where `body` is `[deleted]` or `[removed]`; use `parent_id` to reconstruct conversation flow. No time-filter parameter — compare `created_utc` against a UTC cutoff to filter by date.\",\n input: RedditRetrievePostCommentsInput,\n output: RedditRetrievePostCommentsOutput,\n});\n"],"mappings":";;;;AAMA,MAAa,kCAAkCA,IAAAA,EAAE,OAAO,EACtD,SAASA,IAAAA,E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,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CACxF,OAAOA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,uDAAuD,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CACxG,QAAQA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,wDAAwD,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CAC1G,SAASA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,sCAAsC,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CACzF,UAAUA,IAAAA,EAAE,MAAMA,IAAAA,EAAE,MAAM,CAAC,+CAA+C,0CAA0C,CAAC,CAAC,CAAC,CAAC,SAAS,mDAAmD;CACpL,YAAYA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,2CAA2C,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;AACnG,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC,SAAS,8DAA8D;AACxF,MAAM,kDAAkDA,IAAAA,EAAE,OAAO;CAC/D,MAAM,oDAAoD,SAAS;CACnE,MAAMA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,wCAAwC,CAAC,CAAC,SAAS;AAC/E,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC,SAAS,6EAA6E;AACvG,MAAa,mCAAmCA,IAAAA,EAAE,OAAO;CACvD,cAAc,6CAA6C,SAAS;CACpE,kBAAkB,gDAAgD,SAAS;AAC7E,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC,SAAS,+LAA+L;AAEzN,MAAa,6BAITC,eAAAA,OAAO,iCAAiC;CAC1C,MAAM;CACN,MAAM;CACN,aAAa;CACb,OAAO;CACP,QAAQ;AACV,CAAC"}
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
import { reddit } from "../app.cjs";
|
|
2
|
+
import { AppAction } from "@keystrokehq/keystroke/app";
|
|
1
3
|
import { z } from "zod";
|
|
2
4
|
|
|
3
5
|
//#region src/actions/retrieve-post-comments.d.ts
|
|
@@ -70,9 +72,7 @@ declare const RedditRetrievePostCommentsOutput: z.ZodObject<{
|
|
|
70
72
|
kind: z.ZodNullable<z.ZodString>;
|
|
71
73
|
}, z.core.$loose>>;
|
|
72
74
|
}, z.core.$loose>;
|
|
73
|
-
declare const redditRetrievePostComments:
|
|
74
|
-
article: string;
|
|
75
|
-
}, unknown, import("@keystrokehq/shared").ResolvedCredentials<readonly [import("@keystrokehq/shared").Credential]>, readonly [import("@keystrokehq/shared").Credential]>;
|
|
75
|
+
declare const redditRetrievePostComments: AppAction<typeof RedditRetrievePostCommentsInput, typeof RedditRetrievePostCommentsOutput, typeof reddit.credential>;
|
|
76
76
|
//#endregion
|
|
77
77
|
export { redditRetrievePostComments };
|
|
78
78
|
//# sourceMappingURL=retrieve-post-comments.d.cts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"retrieve-post-comments.d.cts","names":[],"sources":["../../src/actions/retrieve-post-comments.ts"],"mappings":"
|
|
1
|
+
{"version":3,"file":"retrieve-post-comments.d.cts","names":[],"sources":["../../src/actions/retrieve-post-comments.ts"],"mappings":";;;;;cAMa,+BAAA,EAA+B,CAAA,CAAA,SAAA;;;cA2E/B,gCAAA,EAAgC,CAAA,CAAA,SAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;cAKhC,0BAAA,EAA4B,SAAA,QAChC,+BAAA,SACA,gCAAA,SACA,MAAA,CAAO,UAAA"}
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
import { reddit } from "../app.mjs";
|
|
2
|
+
import { AppAction } from "@keystrokehq/keystroke/app";
|
|
1
3
|
import { z } from "zod";
|
|
2
4
|
|
|
3
5
|
//#region src/actions/retrieve-post-comments.d.ts
|
|
@@ -70,9 +72,7 @@ declare const RedditRetrievePostCommentsOutput: z.ZodObject<{
|
|
|
70
72
|
kind: z.ZodNullable<z.ZodString>;
|
|
71
73
|
}, z.core.$loose>>;
|
|
72
74
|
}, z.core.$loose>;
|
|
73
|
-
declare const redditRetrievePostComments:
|
|
74
|
-
article: string;
|
|
75
|
-
}, unknown, import("@keystrokehq/shared").ResolvedCredentials<readonly [import("@keystrokehq/shared").Credential]>, readonly [import("@keystrokehq/shared").Credential]>;
|
|
75
|
+
declare const redditRetrievePostComments: AppAction<typeof RedditRetrievePostCommentsInput, typeof RedditRetrievePostCommentsOutput, typeof reddit.credential>;
|
|
76
76
|
//#endregion
|
|
77
77
|
export { redditRetrievePostComments };
|
|
78
78
|
//# sourceMappingURL=retrieve-post-comments.d.mts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"retrieve-post-comments.d.mts","names":[],"sources":["../../src/actions/retrieve-post-comments.ts"],"mappings":"
|
|
1
|
+
{"version":3,"file":"retrieve-post-comments.d.mts","names":[],"sources":["../../src/actions/retrieve-post-comments.ts"],"mappings":";;;;;cAMa,+BAAA,EAA+B,CAAA,CAAA,SAAA;;;cA2E/B,gCAAA,EAAgC,CAAA,CAAA,SAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;cAKhC,0BAAA,EAA4B,SAAA,QAChC,+BAAA,SACA,gCAAA,SACA,MAAA,CAAO,UAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"retrieve-post-comments.mjs","names":[],"sources":["../../src/actions/retrieve-post-comments.ts"],"sourcesContent":["import { z } from \"zod\";\n\nimport { action } from \"../action\";\n\nexport const RedditRetrievePostCommentsInput = z.object({\n article: z.string().describe(\"Base-36 ID of the Reddit post (e.g., 'q5u7q5'), typically found in the post's URL and not including the 't3_' prefix.\"),\n});\nconst RedditRetrievePostComments_PostDataSchema = z.object({\n id: z.string().describe(\"Unique identifier of the post in base36 format.\").nullable().optional(),\n url: z.string().describe(\"URL the post links to, or the permalink if a self post.\").nullable().optional(),\n score: z.number().int().describe(\"Net score of the post (upvotes minus downvotes).\").nullable().optional(),\n title: z.string().describe(\"The title of the post.\").nullable().optional(),\n author: z.string().describe(\"Username of the post author, null if deleted.\").nullable().optional(),\n is_self: z.boolean().describe(\"Whether the post is a self/text post (true) or link post (false).\").nullable().optional(),\n over_18: z.boolean().describe(\"Whether the post is marked as NSFW.\").nullable().optional(),\n selftext: z.string().describe(\"Raw body text for self/text posts with markdown.\").nullable().optional(),\n permalink: z.string().describe(\"Relative URL path to the permanent link of the post.\").nullable().optional(),\n subreddit: z.string().describe(\"Name of the subreddit without the /r/ prefix.\").nullable().optional(),\n created_utc: z.number().describe(\"Unix timestamp of post creation in UTC epoch-seconds.\").nullable().optional(),\n num_comments: z.number().int().describe(\"Total number of comments.\").nullable().optional(),\n}).passthrough().describe(\"Optimized data attributes for a Reddit post (t3 kind).\");\nconst RedditRetrievePostComments_PostThingSchema = z.object({\n data: RedditRetrievePostComments_PostDataSchema.nullable(),\n kind: z.string().describe(\"Type identifier, always 't3' for posts.\").nullable(),\n}).passthrough().describe(\"Wrapped post object with kind and data.\");\nconst RedditRetrievePostComments_PostListingDataSchema = z.object({\n dist: z.number().int().describe(\"Number of items in this listing.\").nullable().optional(),\n after: z.string().describe(\"Fullname of the listing that follows after this page.\").nullable().optional(),\n before: z.string().describe(\"Fullname of the listing that follows before this page.\").nullable().optional(),\n modhash: z.string().describe(\"Modhash for authentication purposes.\").nullable().optional(),\n children: z.array(RedditRetrievePostComments_PostThingSchema).describe(\"Array containing the post object.\"),\n geo_filter: z.string().describe(\"Geographic filter applied to the listing.\").nullable().optional(),\n}).passthrough().describe(\"Container object for the first listing containing the post.\");\nconst RedditRetrievePostComments_PostListingSchema = z.object({\n data: RedditRetrievePostComments_PostListingDataSchema.nullable(),\n kind: z.string().describe(\"Always 'Listing' for this object type.\").nullable(),\n}).passthrough().describe(\"Reddit API Listing object containing the post (first listing in response).\");\nconst RedditRetrievePostComments_CommentDataSchema = z.object({\n id: z.string().describe(\"Unique identifier of the comment in base36 format.\").nullable().optional(),\n body: z.string().describe(\"Raw text of the comment with markdown.\").nullable().optional(),\n name: z.string().describe(\"Fullname of the comment (e.g., 't1_abc123').\").nullable().optional(),\n depth: z.number().int().describe(\"Depth level in the comment tree (0 = top-level).\").nullable().optional(),\n score: z.number().int().describe(\"Net score (upvotes minus downvotes).\").nullable().optional(),\n author: z.string().describe(\"Username of the comment author, null if deleted.\").nullable().optional(),\n parent_id: z.string().describe(\"Fullname of the parent comment (t1_) or post (t3_).\").nullable().optional(),\n permalink: z.string().describe(\"Permanent link to the comment.\").nullable().optional(),\n created_utc: z.number().describe(\"Unix timestamp of creation in UTC epoch-seconds.\").nullable().optional(),\n has_replies: z.boolean().describe(\"Whether this comment has nested replies.\").nullable().optional(),\n is_submitter: z.boolean().describe(\"Whether the author is also the post submitter.\").nullable().optional(),\n distinguished: z.string().describe(\"Special status: null, 'moderator', 'admin', or 'special'.\").nullable().optional(),\n}).passthrough().describe(\"Optimized data attributes for a Reddit comment (t1 kind).\");\nconst RedditRetrievePostComments_CommentThingSchema = z.object({\n data: RedditRetrievePostComments_CommentDataSchema.nullable(),\n kind: z.string().describe(\"Type identifier, always 't1' for comments.\").nullable(),\n}).passthrough().describe(\"Wrapped comment object with kind and data.\");\nconst RedditRetrievePostComments_MoreDataSchema = z.object({\n id: z.string().describe(\"Identifier for this more object.\").nullable().optional(),\n name: z.string().describe(\"Fullname of this more object.\").nullable().optional(),\n count: z.number().int().describe(\"Number of additional comments available.\").nullable().optional(),\n depth: z.number().int().describe(\"Depth level in the comment tree.\").nullable().optional(),\n children: z.array(z.string()).describe(\"Array of comment IDs that can be loaded using the morechildren endpoint.\").nullable().optional(),\n parent_id: z.string().describe(\"Fullname of the parent comment or post.\").nullable().optional(),\n}).passthrough().describe(\"Data for a 'more' object that holds IDs of additional comments to load.\");\nconst RedditRetrievePostComments_MoreThingSchema = z.object({\n data: RedditRetrievePostComments_MoreDataSchema.nullable(),\n kind: z.string().describe(\"Type identifier, always 'more'.\").nullable(),\n}).passthrough().describe(\"Wrapped 'more' object for loading additional comments.\");\nconst RedditRetrievePostComments_CommentListingDataSchema = z.object({\n dist: z.number().int().describe(\"Number of items in this listing.\").nullable().optional(),\n after: z.string().describe(\"Fullname of the listing that follows after this page.\").nullable().optional(),\n before: z.string().describe(\"Fullname of the listing that follows before this page.\").nullable().optional(),\n modhash: z.string().describe(\"Modhash for authentication purposes.\").nullable().optional(),\n children: z.array(z.union([RedditRetrievePostComments_CommentThingSchema, RedditRetrievePostComments_MoreThingSchema])).describe(\"Array of comment objects and 'more' placeholders.\"),\n geo_filter: z.string().describe(\"Geographic filter applied to the listing.\").nullable().optional(),\n}).passthrough().describe(\"Container object for the second listing containing comments.\");\nconst RedditRetrievePostComments_CommentListingSchema = z.object({\n data: RedditRetrievePostComments_CommentListingDataSchema.nullable(),\n kind: z.string().describe(\"Always 'Listing' for this object type.\").nullable(),\n}).passthrough().describe(\"Reddit API Listing object containing comments (second listing in response).\");\nexport const RedditRetrievePostCommentsOutput = z.object({\n post_listing: RedditRetrievePostComments_PostListingSchema.nullable(),\n comments_listing: RedditRetrievePostComments_CommentListingSchema.nullable(),\n}).passthrough().describe(\"Response containing two Listing objects from Reddit API.\\nThe first listing contains the submission/post object, and the second\\nlisting contains the top-level comments with nested replies.\");\n\nexport const redditRetrievePostComments = action(\"REDDIT_RETRIEVE_POST_COMMENTS\", {\n slug: \"reddit-retrieve-post-comments\",\n name: \"Retrieve Comments for a Post\",\n description: \"Retrieves all comments for a Reddit post given its base-36 article ID. Response is a two-element listings array: post metadata in `listings[0]`; comments in `listings[1].data.children` with text at each `[].data.body` and nested replies under each comment's `replies` field. Replies require recursive traversal to capture full discussion. Large, locked, or archived threads may return truncated trees or `more` placeholders rather than full results. Filter out comments where `body` is `[deleted]` or `[removed]`; use `parent_id` to reconstruct conversation flow. No time-filter parameter — compare `created_utc` against a UTC cutoff to filter by date.\",\n input: RedditRetrievePostCommentsInput,\n output: RedditRetrievePostCommentsOutput,\n});\n"],"mappings":";;;AAIA,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SAAS,mDAAmD;CACpL,YAAY,EAAE,OAAO,CAAC,CAAC,SAAS,2CAA2C,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;AACnG,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC,SAAS,8DAA8D;AACxF,MAAM,kDAAkD,EAAE,OAAO;CAC/D,MAAM,oDAAoD,SAAS;CACnE,MAAM,EAAE,OAAO,CAAC,CAAC,SAAS,wCAAwC,CAAC,CAAC,SAAS;AAC/E,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC,SAAS,6EAA6E;AAMvG,MAAa,6BAA6B,OAAO,iCAAiC;CAChF,MAAM;CACN,MAAM;CACN,aAAa;CACb,OAAO;CACP,QAV8C,EAAE,OAAO;EACvD,cAAc,6CAA6C,SAAS;EACpE,kBAAkB,gDAAgD,SAAS;CAC7E,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC,SAAS,+LAOhB;AACV,CAAC"}
|
|
1
|
+
{"version":3,"file":"retrieve-post-comments.mjs","names":[],"sources":["../../src/actions/retrieve-post-comments.ts"],"sourcesContent":["import type { AppAction } from \"@keystrokehq/keystroke/app\";\nimport { z } from \"zod\";\n\nimport { action } from \"../action\";\nimport { reddit } from \"../app\";\n\nexport const RedditRetrievePostCommentsInput = z.object({\n article: z.string().describe(\"Base-36 ID of the Reddit post (e.g., 'q5u7q5'), typically found in the post's URL and not including the 't3_' prefix.\"),\n});\nconst RedditRetrievePostComments_PostDataSchema = z.object({\n id: z.string().describe(\"Unique identifier of the post in base36 format.\").nullable().optional(),\n url: z.string().describe(\"URL the post links to, or the permalink if a self post.\").nullable().optional(),\n score: z.number().int().describe(\"Net score of the post (upvotes minus downvotes).\").nullable().optional(),\n title: z.string().describe(\"The title of the post.\").nullable().optional(),\n author: z.string().describe(\"Username of the post author, null if deleted.\").nullable().optional(),\n is_self: z.boolean().describe(\"Whether the post is a self/text post (true) or link post (false).\").nullable().optional(),\n over_18: z.boolean().describe(\"Whether the post is marked as NSFW.\").nullable().optional(),\n selftext: z.string().describe(\"Raw body text for self/text posts with markdown.\").nullable().optional(),\n permalink: z.string().describe(\"Relative URL path to the permanent link of the post.\").nullable().optional(),\n subreddit: z.string().describe(\"Name of the subreddit without the /r/ prefix.\").nullable().optional(),\n created_utc: z.number().describe(\"Unix timestamp of post creation in UTC epoch-seconds.\").nullable().optional(),\n num_comments: z.number().int().describe(\"Total number of comments.\").nullable().optional(),\n}).passthrough().describe(\"Optimized data attributes for a Reddit post (t3 kind).\");\nconst RedditRetrievePostComments_PostThingSchema = z.object({\n data: RedditRetrievePostComments_PostDataSchema.nullable(),\n kind: z.string().describe(\"Type identifier, always 't3' for posts.\").nullable(),\n}).passthrough().describe(\"Wrapped post object with kind and data.\");\nconst RedditRetrievePostComments_PostListingDataSchema = z.object({\n dist: z.number().int().describe(\"Number of items in this listing.\").nullable().optional(),\n after: z.string().describe(\"Fullname of the listing that follows after this page.\").nullable().optional(),\n before: z.string().describe(\"Fullname of the listing that follows before this page.\").nullable().optional(),\n modhash: z.string().describe(\"Modhash for authentication purposes.\").nullable().optional(),\n children: z.array(RedditRetrievePostComments_PostThingSchema).describe(\"Array containing the post object.\"),\n geo_filter: z.string().describe(\"Geographic filter applied to the listing.\").nullable().optional(),\n}).passthrough().describe(\"Container object for the first listing containing the post.\");\nconst RedditRetrievePostComments_PostListingSchema = z.object({\n data: RedditRetrievePostComments_PostListingDataSchema.nullable(),\n kind: z.string().describe(\"Always 'Listing' for this object type.\").nullable(),\n}).passthrough().describe(\"Reddit API Listing object containing the post (first listing in response).\");\nconst RedditRetrievePostComments_CommentDataSchema = z.object({\n id: z.string().describe(\"Unique identifier of the comment in base36 format.\").nullable().optional(),\n body: z.string().describe(\"Raw text of the comment with markdown.\").nullable().optional(),\n name: z.string().describe(\"Fullname of the comment (e.g., 't1_abc123').\").nullable().optional(),\n depth: z.number().int().describe(\"Depth level in the comment tree (0 = top-level).\").nullable().optional(),\n score: z.number().int().describe(\"Net score (upvotes minus downvotes).\").nullable().optional(),\n author: z.string().describe(\"Username of the comment author, null if deleted.\").nullable().optional(),\n parent_id: z.string().describe(\"Fullname of the parent comment (t1_) or post (t3_).\").nullable().optional(),\n permalink: z.string().describe(\"Permanent link to the comment.\").nullable().optional(),\n created_utc: z.number().describe(\"Unix timestamp of creation in UTC epoch-seconds.\").nullable().optional(),\n has_replies: z.boolean().describe(\"Whether this comment has nested replies.\").nullable().optional(),\n is_submitter: z.boolean().describe(\"Whether the author is also the post submitter.\").nullable().optional(),\n distinguished: z.string().describe(\"Special status: null, 'moderator', 'admin', or 'special'.\").nullable().optional(),\n}).passthrough().describe(\"Optimized data attributes for a Reddit comment (t1 kind).\");\nconst RedditRetrievePostComments_CommentThingSchema = z.object({\n data: RedditRetrievePostComments_CommentDataSchema.nullable(),\n kind: z.string().describe(\"Type identifier, always 't1' for comments.\").nullable(),\n}).passthrough().describe(\"Wrapped comment object with kind and data.\");\nconst RedditRetrievePostComments_MoreDataSchema = z.object({\n id: z.string().describe(\"Identifier for this more object.\").nullable().optional(),\n name: z.string().describe(\"Fullname of this more object.\").nullable().optional(),\n count: z.number().int().describe(\"Number of additional comments available.\").nullable().optional(),\n depth: z.number().int().describe(\"Depth level in the comment tree.\").nullable().optional(),\n children: z.array(z.string()).describe(\"Array of comment IDs that can be loaded using the morechildren endpoint.\").nullable().optional(),\n parent_id: z.string().describe(\"Fullname of the parent comment or post.\").nullable().optional(),\n}).passthrough().describe(\"Data for a 'more' object that holds IDs of additional comments to load.\");\nconst RedditRetrievePostComments_MoreThingSchema = z.object({\n data: RedditRetrievePostComments_MoreDataSchema.nullable(),\n kind: z.string().describe(\"Type identifier, always 'more'.\").nullable(),\n}).passthrough().describe(\"Wrapped 'more' object for loading additional comments.\");\nconst RedditRetrievePostComments_CommentListingDataSchema = z.object({\n dist: z.number().int().describe(\"Number of items in this listing.\").nullable().optional(),\n after: z.string().describe(\"Fullname of the listing that follows after this page.\").nullable().optional(),\n before: z.string().describe(\"Fullname of the listing that follows before this page.\").nullable().optional(),\n modhash: z.string().describe(\"Modhash for authentication purposes.\").nullable().optional(),\n children: z.array(z.union([RedditRetrievePostComments_CommentThingSchema, RedditRetrievePostComments_MoreThingSchema])).describe(\"Array of comment objects and 'more' placeholders.\"),\n geo_filter: z.string().describe(\"Geographic filter applied to the listing.\").nullable().optional(),\n}).passthrough().describe(\"Container object for the second listing containing comments.\");\nconst RedditRetrievePostComments_CommentListingSchema = z.object({\n data: RedditRetrievePostComments_CommentListingDataSchema.nullable(),\n kind: z.string().describe(\"Always 'Listing' for this object type.\").nullable(),\n}).passthrough().describe(\"Reddit API Listing object containing comments (second listing in response).\");\nexport const RedditRetrievePostCommentsOutput = z.object({\n post_listing: RedditRetrievePostComments_PostListingSchema.nullable(),\n comments_listing: RedditRetrievePostComments_CommentListingSchema.nullable(),\n}).passthrough().describe(\"Response containing two Listing objects from Reddit API.\\nThe first listing contains the submission/post object, and the second\\nlisting contains the top-level comments with nested replies.\");\n\nexport const redditRetrievePostComments: AppAction<\n typeof RedditRetrievePostCommentsInput,\n typeof RedditRetrievePostCommentsOutput,\n typeof reddit.credential\n> = action(\"REDDIT_RETRIEVE_POST_COMMENTS\", {\n slug: \"reddit-retrieve-post-comments\",\n name: \"Retrieve Comments for a Post\",\n description: \"Retrieves all comments for a Reddit post given its base-36 article ID. Response is a two-element listings array: post metadata in `listings[0]`; comments in `listings[1].data.children` with text at each `[].data.body` and nested replies under each comment's `replies` field. Replies require recursive traversal to capture full discussion. Large, locked, or archived threads may return truncated trees or `more` placeholders rather than full results. Filter out comments where `body` is `[deleted]` or `[removed]`; use `parent_id` to reconstruct conversation flow. No time-filter parameter — compare `created_utc` against a UTC cutoff to filter by date.\",\n input: RedditRetrievePostCommentsInput,\n output: RedditRetrievePostCommentsOutput,\n});\n"],"mappings":";;;;AAMA,MAAa,kCAAkC,EAAE,OAAO,EACtD,SAAS,EAAE,OAAO,CAAC,CAAC,SAAS,uHAAuH,EACtJ,CAAC;AACD,MAAM,4CAA4C,EAAE,OAAO;CACz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YAAY,CAAC,CAAC,SAAS,8DAA8D;AACxF,MAAM,kDAAkD,EAAE,OAAO;CAC/D,MAAM,oDAAoD,SAAS;CACnE,MAAM,EAAE,OAAO,CAAC,CAAC,SAAS,wCAAwC,CAAC,CAAC,SAAS;AAC/E,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC,SAAS,6EAA6E;AAMvG,MAAa,6BAIT,OAAO,iCAAiC;CAC1C,MAAM;CACN,MAAM;CACN,aAAa;CACb,OAAO;CACP,QAd8C,EAAE,OAAO;EACvD,cAAc,6CAA6C,SAAS;EACpE,kBAAkB,gDAAgD,SAAS;CAC7E,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC,SAAS,+LAWhB;AACV,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"retrieve-reddit-post.cjs","names":["z","action"],"sources":["../../src/actions/retrieve-reddit-post.ts"],"sourcesContent":["import { z } from \"zod\";\n\nimport { action } from \"../action\";\n\nexport const RedditRetrieveRedditPostInput = z.object({\n sort: z.enum([\"hot\", \"new\", \"top\", \"rising\", \"controversial\"]).default(\"hot\").describe(\"Sort order for posts. Options: 'hot' (default, most active posts), 'new' (newest first), 'top' (highest scoring), 'rising' (trending posts), 'controversial' (most controversial).\").optional(),\n subreddit: z.string().describe(\"The name of the subreddit from which to retrieve posts (e.g., 'popular', 'pics'). Do not include 'r/'. Subreddit names must be 3-21 characters and can only contain letters, numbers, and underscores.\"),\n max_results: z.number().int().default(5).describe(\"The maximum number of posts to return. Default is 5. Set to 0 to retrieve the maximum allowed by the Reddit API (100 posts). Valid range: 0-100.\").optional(),\n});\nconst RedditRetrieveRedditPost_PostDataSchema = z.object({\n id: z.string().describe(\"Unique identifier of the post in base36 format.\").nullable(),\n ups: z.number().int().describe(\"Number of upvotes received.\").nullable(),\n url: z.string().describe(\"URL the post links to, or the permalink if a self post.\").nullable(),\n name: z.string().describe(\"Fullname of the post, combining type prefix and ID (e.g., 't3_abc123').\").nullable(),\n score: z.number().int().describe(\"Net score of the post, calculated as upvotes minus downvotes.\").nullable(),\n title: z.string().describe(\"The title of the post.\").nullable(),\n author: z.string().describe(\"Username of the post author.\").nullable().optional(),\n domain: z.string().describe(\"Domain of the linked content, 'self.<subreddit>' for self posts.\").nullable(),\n is_self: z.boolean().describe(\"Whether the post is a self/text post (true) or link post (false).\").nullable(),\n over_18: z.boolean().describe(\"Whether the post is marked as NSFW (Not Safe For Work).\").nullable(),\n is_video: z.boolean().describe(\"Whether the post contains a video hosted on Reddit.\").nullable().optional(),\n selftext: z.string().describe(\"Raw body text for self/text posts, empty string for link posts.\").nullable(),\n permalink: z.string().describe(\"Relative URL path to the permanent link of the post.\").nullable(),\n subreddit: z.string().describe(\"Name of the subreddit without the /r/ prefix.\").nullable(),\n thumbnail: z.string().describe(\"Thumbnail URL, or 'self' for self posts, 'image' if link to image but no thumbnail, 'default' if unavailable.\").nullable(),\n created_utc: z.number().describe(\"Unix timestamp of post creation in UTC epoch-seconds.\").nullable(),\n num_comments: z.number().int().describe(\"Total number of comments.\").nullable(),\n}).passthrough().describe(\"Optimized post data object containing only essential fields.\");\nconst RedditRetrieveRedditPost_PostChildSchema = z.object({\n data: RedditRetrieveRedditPost_PostDataSchema.nullable(),\n kind: z.string().describe(\"Type identifier for the post object, always 't3' for links/posts.\").nullable(),\n}).passthrough().describe(\"Wrapper object for each post in the children array.\");\nconst RedditRetrieveRedditPost_ListingDataSchema = z.object({\n dist: z.number().int().describe(\"The number of children returned in this listing.\").nullable().optional(),\n after: z.string().describe(\"Fullname of the last item in the listing, used for pagination.\").nullable().optional(),\n before: z.string().describe(\"Fullname of the first item in the listing, used for pagination.\").nullable().optional(),\n modhash: z.string().describe(\"Modhash token for the current session.\").nullable().optional(),\n children: z.array(RedditRetrieveRedditPost_PostChildSchema).describe(\"Array of post objects.\"),\n}).passthrough().describe(\"Container object holding the listing response data.\");\nexport const RedditRetrieveRedditPostOutput = z.object({\n data: RedditRetrieveRedditPost_ListingDataSchema.nullable(),\n kind: z.string().describe(\"Type identifier for the response wrapper, typically 'Listing' for post queries.\").nullable(),\n}).passthrough().describe(\"Response from retrieving posts from a subreddit.\");\n\nexport const redditRetrieveRedditPost = action(\"REDDIT_RETRIEVE_REDDIT_POST\", {\n slug: \"reddit-retrieve-reddit-post\",\n name: \"Retrieve posts from subreddit\",\n description: \"Retrieves posts from a specified, publicly accessible subreddit. Responses nest post data under `data.children[].data`; inspect the structure before parsing. Pagination uses a `data.after` cursor; deduplicate across pages by post `id`. No built-in date filtering; compare `created_utc` (Unix seconds, UTC) client-side. Rate limit: ~1–2 requests/second; back off on HTTP 429.\",\n input: RedditRetrieveRedditPostInput,\n output: RedditRetrieveRedditPostOutput,\n});\n"],"mappings":"
|
|
1
|
+
{"version":3,"file":"retrieve-reddit-post.cjs","names":["z","action"],"sources":["../../src/actions/retrieve-reddit-post.ts"],"sourcesContent":["import type { AppAction } from \"@keystrokehq/keystroke/app\";\nimport { z } from \"zod\";\n\nimport { action } from \"../action\";\nimport { reddit } from \"../app\";\n\nexport const RedditRetrieveRedditPostInput = z.object({\n sort: z.enum([\"hot\", \"new\", \"top\", \"rising\", \"controversial\"]).default(\"hot\").describe(\"Sort order for posts. Options: 'hot' (default, most active posts), 'new' (newest first), 'top' (highest scoring), 'rising' (trending posts), 'controversial' (most controversial).\").optional(),\n subreddit: z.string().describe(\"The name of the subreddit from which to retrieve posts (e.g., 'popular', 'pics'). Do not include 'r/'. Subreddit names must be 3-21 characters and can only contain letters, numbers, and underscores.\"),\n max_results: z.number().int().default(5).describe(\"The maximum number of posts to return. Default is 5. Set to 0 to retrieve the maximum allowed by the Reddit API (100 posts). Valid range: 0-100.\").optional(),\n});\nconst RedditRetrieveRedditPost_PostDataSchema = z.object({\n id: z.string().describe(\"Unique identifier of the post in base36 format.\").nullable(),\n ups: z.number().int().describe(\"Number of upvotes received.\").nullable(),\n url: z.string().describe(\"URL the post links to, or the permalink if a self post.\").nullable(),\n name: z.string().describe(\"Fullname of the post, combining type prefix and ID (e.g., 't3_abc123').\").nullable(),\n score: z.number().int().describe(\"Net score of the post, calculated as upvotes minus downvotes.\").nullable(),\n title: z.string().describe(\"The title of the post.\").nullable(),\n author: z.string().describe(\"Username of the post author.\").nullable().optional(),\n domain: z.string().describe(\"Domain of the linked content, 'self.<subreddit>' for self posts.\").nullable(),\n is_self: z.boolean().describe(\"Whether the post is a self/text post (true) or link post (false).\").nullable(),\n over_18: z.boolean().describe(\"Whether the post is marked as NSFW (Not Safe For Work).\").nullable(),\n is_video: z.boolean().describe(\"Whether the post contains a video hosted on Reddit.\").nullable().optional(),\n selftext: z.string().describe(\"Raw body text for self/text posts, empty string for link posts.\").nullable(),\n permalink: z.string().describe(\"Relative URL path to the permanent link of the post.\").nullable(),\n subreddit: z.string().describe(\"Name of the subreddit without the /r/ prefix.\").nullable(),\n thumbnail: z.string().describe(\"Thumbnail URL, or 'self' for self posts, 'image' if link to image but no thumbnail, 'default' if unavailable.\").nullable(),\n created_utc: z.number().describe(\"Unix timestamp of post creation in UTC epoch-seconds.\").nullable(),\n num_comments: z.number().int().describe(\"Total number of comments.\").nullable(),\n}).passthrough().describe(\"Optimized post data object containing only essential fields.\");\nconst RedditRetrieveRedditPost_PostChildSchema = z.object({\n data: RedditRetrieveRedditPost_PostDataSchema.nullable(),\n kind: z.string().describe(\"Type identifier for the post object, always 't3' for links/posts.\").nullable(),\n}).passthrough().describe(\"Wrapper object for each post in the children array.\");\nconst RedditRetrieveRedditPost_ListingDataSchema = z.object({\n dist: z.number().int().describe(\"The number of children returned in this listing.\").nullable().optional(),\n after: z.string().describe(\"Fullname of the last item in the listing, used for pagination.\").nullable().optional(),\n before: z.string().describe(\"Fullname of the first item in the listing, used for pagination.\").nullable().optional(),\n modhash: z.string().describe(\"Modhash token for the current session.\").nullable().optional(),\n children: z.array(RedditRetrieveRedditPost_PostChildSchema).describe(\"Array of post objects.\"),\n}).passthrough().describe(\"Container object holding the listing response data.\");\nexport const RedditRetrieveRedditPostOutput = z.object({\n data: RedditRetrieveRedditPost_ListingDataSchema.nullable(),\n kind: z.string().describe(\"Type identifier for the response wrapper, typically 'Listing' for post queries.\").nullable(),\n}).passthrough().describe(\"Response from retrieving posts from a subreddit.\");\n\nexport const redditRetrieveRedditPost: AppAction<\n typeof RedditRetrieveRedditPostInput,\n typeof RedditRetrieveRedditPostOutput,\n typeof reddit.credential\n> = action(\"REDDIT_RETRIEVE_REDDIT_POST\", {\n slug: \"reddit-retrieve-reddit-post\",\n name: \"Retrieve posts from subreddit\",\n description: \"Retrieves posts from a specified, publicly accessible subreddit. Responses nest post data under `data.children[].data`; inspect the structure before parsing. Pagination uses a `data.after` cursor; deduplicate across pages by post `id`. No built-in date filtering; compare `created_utc` (Unix seconds, UTC) client-side. Rate limit: ~1–2 requests/second; back off on HTTP 429.\",\n input: RedditRetrieveRedditPostInput,\n output: RedditRetrieveRedditPostOutput,\n});\n"],"mappings":";;;;AAMA,MAAa,gCAAgCA,IAAAA,EAAE,OAAO;CACpD,MAAMA,IAAAA,EAAE,KAAK;EAAC;EAAO;EAAO;EAAO;EAAU;CAAe,CAAC,CAAC,CAAC,QAAQ,KAAK,CAAC,CAAC,SAAS,oLAAoL,CAAC,CAAC,SAAS;CACtR,WAAWA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,wMAAwM;CACvO,aAAaA,IAAAA,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,SAAS,kJAAkJ,CAAC,CAAC,SAAS;AACjN,CAAC;AACD,MAAM,0CAA0CA,IAAAA,EAAE,OAAO;CACvD,IAAIA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,iDAAiD,CAAC,CAAC,SAAS;CACpF,KAAKA,IAAAA,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS,6BAA6B,CAAC,CAAC,SAAS;CACvE,KAAKA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,yDAAyD,CAAC,CAAC,SAAS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ve-reddit-post.d.ts
|
|
@@ -43,11 +45,7 @@ declare const RedditRetrieveRedditPostOutput: z.ZodObject<{
|
|
|
43
45
|
}, z.core.$loose>>;
|
|
44
46
|
kind: z.ZodNullable<z.ZodString>;
|
|
45
47
|
}, z.core.$loose>;
|
|
46
|
-
declare const redditRetrieveRedditPost:
|
|
47
|
-
subreddit: string;
|
|
48
|
-
sort?: "hot" | "new" | "top" | "rising" | "controversial" | undefined;
|
|
49
|
-
max_results?: number | undefined;
|
|
50
|
-
}, unknown, import("@keystrokehq/shared").ResolvedCredentials<readonly [import("@keystrokehq/shared").Credential]>, readonly [import("@keystrokehq/shared").Credential]>;
|
|
48
|
+
declare const redditRetrieveRedditPost: AppAction<typeof RedditRetrieveRedditPostInput, typeof RedditRetrieveRedditPostOutput, typeof reddit.credential>;
|
|
51
49
|
//#endregion
|
|
52
50
|
export { redditRetrieveRedditPost };
|
|
53
51
|
//# sourceMappingURL=retrieve-reddit-post.d.cts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"retrieve-reddit-post.d.cts","names":[],"sources":["../../src/actions/retrieve-reddit-post.ts"],"mappings":"
|
|
1
|
+
{"version":3,"file":"retrieve-reddit-post.d.cts","names":[],"sources":["../../src/actions/retrieve-reddit-post.ts"],"mappings":";;;;;cAMa,6BAAA,EAA6B,CAAA,CAAA,SAAA;;;;;;;;;;;cAmC7B,8BAAA,EAA8B,CAAA,CAAA,SAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;cAK9B,wBAAA,EAA0B,SAAA,QAC9B,6BAAA,SACA,8BAAA,SACA,MAAA,CAAO,UAAA"}
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
import { reddit } from "../app.mjs";
|
|
2
|
+
import { AppAction } from "@keystrokehq/keystroke/app";
|
|
1
3
|
import { z } from "zod";
|
|
2
4
|
|
|
3
5
|
//#region src/actions/retrieve-reddit-post.d.ts
|
|
@@ -43,11 +45,7 @@ declare const RedditRetrieveRedditPostOutput: z.ZodObject<{
|
|
|
43
45
|
}, z.core.$loose>>;
|
|
44
46
|
kind: z.ZodNullable<z.ZodString>;
|
|
45
47
|
}, z.core.$loose>;
|
|
46
|
-
declare const redditRetrieveRedditPost:
|
|
47
|
-
subreddit: string;
|
|
48
|
-
sort?: "hot" | "new" | "top" | "rising" | "controversial" | undefined;
|
|
49
|
-
max_results?: number | undefined;
|
|
50
|
-
}, unknown, import("@keystrokehq/shared").ResolvedCredentials<readonly [import("@keystrokehq/shared").Credential]>, readonly [import("@keystrokehq/shared").Credential]>;
|
|
48
|
+
declare const redditRetrieveRedditPost: AppAction<typeof RedditRetrieveRedditPostInput, typeof RedditRetrieveRedditPostOutput, typeof reddit.credential>;
|
|
51
49
|
//#endregion
|
|
52
50
|
export { redditRetrieveRedditPost };
|
|
53
51
|
//# sourceMappingURL=retrieve-reddit-post.d.mts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"retrieve-reddit-post.d.mts","names":[],"sources":["../../src/actions/retrieve-reddit-post.ts"],"mappings":"
|
|
1
|
+
{"version":3,"file":"retrieve-reddit-post.d.mts","names":[],"sources":["../../src/actions/retrieve-reddit-post.ts"],"mappings":";;;;;cAMa,6BAAA,EAA6B,CAAA,CAAA,SAAA;;;;;;;;;;;cAmC7B,8BAAA,EAA8B,CAAA,CAAA,SAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;cAK9B,wBAAA,EAA0B,SAAA,QAC9B,6BAAA,SACA,8BAAA,SACA,MAAA,CAAO,UAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"retrieve-reddit-post.mjs","names":[],"sources":["../../src/actions/retrieve-reddit-post.ts"],"sourcesContent":["import { z } from \"zod\";\n\nimport { action } from \"../action\";\n\nexport const RedditRetrieveRedditPostInput = z.object({\n sort: z.enum([\"hot\", \"new\", \"top\", \"rising\", \"controversial\"]).default(\"hot\").describe(\"Sort order for posts. Options: 'hot' (default, most active posts), 'new' (newest first), 'top' (highest scoring), 'rising' (trending posts), 'controversial' (most controversial).\").optional(),\n subreddit: z.string().describe(\"The name of the subreddit from which to retrieve posts (e.g., 'popular', 'pics'). Do not include 'r/'. Subreddit names must be 3-21 characters and can only contain letters, numbers, and underscores.\"),\n max_results: z.number().int().default(5).describe(\"The maximum number of posts to return. Default is 5. Set to 0 to retrieve the maximum allowed by the Reddit API (100 posts). Valid range: 0-100.\").optional(),\n});\nconst RedditRetrieveRedditPost_PostDataSchema = z.object({\n id: z.string().describe(\"Unique identifier of the post in base36 format.\").nullable(),\n ups: z.number().int().describe(\"Number of upvotes received.\").nullable(),\n url: z.string().describe(\"URL the post links to, or the permalink if a self post.\").nullable(),\n name: z.string().describe(\"Fullname of the post, combining type prefix and ID (e.g., 't3_abc123').\").nullable(),\n score: z.number().int().describe(\"Net score of the post, calculated as upvotes minus downvotes.\").nullable(),\n title: z.string().describe(\"The title of the post.\").nullable(),\n author: z.string().describe(\"Username of the post author.\").nullable().optional(),\n domain: z.string().describe(\"Domain of the linked content, 'self.<subreddit>' for self posts.\").nullable(),\n is_self: z.boolean().describe(\"Whether the post is a self/text post (true) or link post (false).\").nullable(),\n over_18: z.boolean().describe(\"Whether the post is marked as NSFW (Not Safe For Work).\").nullable(),\n is_video: z.boolean().describe(\"Whether the post contains a video hosted on Reddit.\").nullable().optional(),\n selftext: z.string().describe(\"Raw body text for self/text posts, empty string for link posts.\").nullable(),\n permalink: z.string().describe(\"Relative URL path to the permanent link of the post.\").nullable(),\n subreddit: z.string().describe(\"Name of the subreddit without the /r/ prefix.\").nullable(),\n thumbnail: z.string().describe(\"Thumbnail URL, or 'self' for self posts, 'image' if link to image but no thumbnail, 'default' if unavailable.\").nullable(),\n created_utc: z.number().describe(\"Unix timestamp of post creation in UTC epoch-seconds.\").nullable(),\n num_comments: z.number().int().describe(\"Total number of comments.\").nullable(),\n}).passthrough().describe(\"Optimized post data object containing only essential fields.\");\nconst RedditRetrieveRedditPost_PostChildSchema = z.object({\n data: RedditRetrieveRedditPost_PostDataSchema.nullable(),\n kind: z.string().describe(\"Type identifier for the post object, always 't3' for links/posts.\").nullable(),\n}).passthrough().describe(\"Wrapper object for each post in the children array.\");\nconst RedditRetrieveRedditPost_ListingDataSchema = z.object({\n dist: z.number().int().describe(\"The number of children returned in this listing.\").nullable().optional(),\n after: z.string().describe(\"Fullname of the last item in the listing, used for pagination.\").nullable().optional(),\n before: z.string().describe(\"Fullname of the first item in the listing, used for pagination.\").nullable().optional(),\n modhash: z.string().describe(\"Modhash token for the current session.\").nullable().optional(),\n children: z.array(RedditRetrieveRedditPost_PostChildSchema).describe(\"Array of post objects.\"),\n}).passthrough().describe(\"Container object holding the listing response data.\");\nexport const RedditRetrieveRedditPostOutput = z.object({\n data: RedditRetrieveRedditPost_ListingDataSchema.nullable(),\n kind: z.string().describe(\"Type identifier for the response wrapper, typically 'Listing' for post queries.\").nullable(),\n}).passthrough().describe(\"Response from retrieving posts from a subreddit.\");\n\nexport const redditRetrieveRedditPost = action(\"REDDIT_RETRIEVE_REDDIT_POST\", {\n slug: \"reddit-retrieve-reddit-post\",\n name: \"Retrieve posts from subreddit\",\n description: \"Retrieves posts from a specified, publicly accessible subreddit. Responses nest post data under `data.children[].data`; inspect the structure before parsing. Pagination uses a `data.after` cursor; deduplicate across pages by post `id`. No built-in date filtering; compare `created_utc` (Unix seconds, UTC) client-side. Rate limit: ~1–2 requests/second; back off on HTTP 429.\",\n input: RedditRetrieveRedditPostInput,\n output: RedditRetrieveRedditPostOutput,\n});\n"],"mappings":"
|
|
1
|
+
{"version":3,"file":"retrieve-reddit-post.mjs","names":[],"sources":["../../src/actions/retrieve-reddit-post.ts"],"sourcesContent":["import type { AppAction } from \"@keystrokehq/keystroke/app\";\nimport { z } from \"zod\";\n\nimport { action } from \"../action\";\nimport { reddit } from \"../app\";\n\nexport const RedditRetrieveRedditPostInput = z.object({\n sort: z.enum([\"hot\", \"new\", \"top\", \"rising\", \"controversial\"]).default(\"hot\").describe(\"Sort order for posts. Options: 'hot' (default, most active posts), 'new' (newest first), 'top' (highest scoring), 'rising' (trending posts), 'controversial' (most controversial).\").optional(),\n subreddit: z.string().describe(\"The name of the subreddit from which to retrieve posts (e.g., 'popular', 'pics'). Do not include 'r/'. Subreddit names must be 3-21 characters and can only contain letters, numbers, and underscores.\"),\n max_results: z.number().int().default(5).describe(\"The maximum number of posts to return. Default is 5. Set to 0 to retrieve the maximum allowed by the Reddit API (100 posts). Valid range: 0-100.\").optional(),\n});\nconst RedditRetrieveRedditPost_PostDataSchema = z.object({\n id: z.string().describe(\"Unique identifier of the post in base36 format.\").nullable(),\n ups: z.number().int().describe(\"Number of upvotes received.\").nullable(),\n url: z.string().describe(\"URL the post links to, or the permalink if a self post.\").nullable(),\n name: z.string().describe(\"Fullname of the post, combining type prefix and ID (e.g., 't3_abc123').\").nullable(),\n score: z.number().int().describe(\"Net score of the post, calculated as upvotes minus downvotes.\").nullable(),\n title: z.string().describe(\"The title of the post.\").nullable(),\n author: z.string().describe(\"Username of the post author.\").nullable().optional(),\n domain: z.string().describe(\"Domain of the linked content, 'self.<subreddit>' for self posts.\").nullable(),\n is_self: z.boolean().describe(\"Whether the post is a self/text post (true) or link post (false).\").nullable(),\n over_18: z.boolean().describe(\"Whether the post is marked as NSFW (Not Safe For Work).\").nullable(),\n is_video: z.boolean().describe(\"Whether the post contains a video hosted on Reddit.\").nullable().optional(),\n selftext: z.string().describe(\"Raw body text for self/text posts, empty string for link posts.\").nullable(),\n permalink: z.string().describe(\"Relative URL path to the permanent link of the post.\").nullable(),\n subreddit: z.string().describe(\"Name of the subreddit without the /r/ prefix.\").nullable(),\n thumbnail: z.string().describe(\"Thumbnail URL, or 'self' for self posts, 'image' if link to image but no thumbnail, 'default' if unavailable.\").nullable(),\n created_utc: z.number().describe(\"Unix timestamp of post creation in UTC epoch-seconds.\").nullable(),\n num_comments: z.number().int().describe(\"Total number of comments.\").nullable(),\n}).passthrough().describe(\"Optimized post data object containing only essential fields.\");\nconst RedditRetrieveRedditPost_PostChildSchema = z.object({\n data: RedditRetrieveRedditPost_PostDataSchema.nullable(),\n kind: z.string().describe(\"Type identifier for the post object, always 't3' for links/posts.\").nullable(),\n}).passthrough().describe(\"Wrapper object for each post in the children array.\");\nconst RedditRetrieveRedditPost_ListingDataSchema = z.object({\n dist: z.number().int().describe(\"The number of children returned in this listing.\").nullable().optional(),\n after: z.string().describe(\"Fullname of the last item in the listing, used for pagination.\").nullable().optional(),\n before: z.string().describe(\"Fullname of the first item in the listing, used for pagination.\").nullable().optional(),\n modhash: z.string().describe(\"Modhash token for the current session.\").nullable().optional(),\n children: z.array(RedditRetrieveRedditPost_PostChildSchema).describe(\"Array of post objects.\"),\n}).passthrough().describe(\"Container object holding the listing response data.\");\nexport const RedditRetrieveRedditPostOutput = z.object({\n data: RedditRetrieveRedditPost_ListingDataSchema.nullable(),\n kind: z.string().describe(\"Type identifier for the response wrapper, typically 'Listing' for post queries.\").nullable(),\n}).passthrough().describe(\"Response from retrieving posts from a subreddit.\");\n\nexport const redditRetrieveRedditPost: AppAction<\n typeof RedditRetrieveRedditPostInput,\n typeof RedditRetrieveRedditPostOutput,\n typeof reddit.credential\n> = action(\"REDDIT_RETRIEVE_REDDIT_POST\", {\n slug: \"reddit-retrieve-reddit-post\",\n name: \"Retrieve posts from subreddit\",\n description: \"Retrieves posts from a specified, publicly accessible subreddit. Responses nest post data under `data.children[].data`; inspect the structure before parsing. Pagination uses a `data.after` cursor; deduplicate across pages by post `id`. No built-in date filtering; compare `created_utc` (Unix seconds, UTC) client-side. Rate limit: ~1–2 requests/second; back off on HTTP 429.\",\n input: RedditRetrieveRedditPostInput,\n output: RedditRetrieveRedditPostOutput,\n});\n"],"mappings":";;;;AAMA,MAAa,gCAAgC,EAAE,OAAO;CACpD,MAAM,EAAE,KAAK;EAAC;EAAO;EAAO;EAAO;EAAU;CAAe,CAAC,CAAC,CAAC,QAAQ,KAAK,CAAC,CAAC,SAAS,oLAAoL,CAAC,CAAC,SAAS;CACt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,CAAC,CAAC,SAAS,kDAWhB;AACV,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"retrieve-specific-comment.cjs","names":["z","action"],"sources":["../../src/actions/retrieve-specific-comment.ts"],"sourcesContent":["import { z } from \"zod\";\n\nimport { action } from \"../action\";\n\nexport const RedditRetrieveSpecificCommentInput = z.object({\n id: z.string().describe(\"Reddit fullname identifier. Format: type prefix (t1_ for comments, t3_ for posts) followed by a base36 ID. Examples: 't1_abc123', 't3_1abc2de'. Note: Share URL tokens from reddit.com/r/.../s/... links are NOT valid fullnames and cannot be used directly. Note: REDDIT_RETRIEVE_POST_COMMENTS expects the bare base-36 ID without the t3_ prefix, unlike this tool.\"),\n});\nconst RedditRetrieveSpecificComment_OembedDataSchema = z.object({\n html: z.string().describe(\"HTML code for embedding the media resource.\").nullable().optional(),\n type: z.string().describe(\"Resource type (photo, video, link, or rich) per oEmbed specification.\").nullable().optional(),\n title: z.string().describe(\"Title of the embedded media.\").nullable().optional(),\n width: z.number().int().describe(\"Width of the embedded media in pixels.\").nullable().optional(),\n height: z.number().int().describe(\"Height of the embedded media in pixels.\").nullable().optional(),\n version: z.string().describe(\"oEmbed version number, typically '1.0'.\").nullable().optional(),\n cache_age: z.number().int().describe(\"Suggested cache lifetime in seconds.\").nullable().optional(),\n author_url: z.string().describe(\"URL of the media content creator's profile or website.\").nullable().optional(),\n author_name: z.string().describe(\"Name of the media content creator.\").nullable().optional(),\n description: z.string().describe(\"Text description of the embedded media resource.\").nullable().optional(),\n provider_url: z.string().describe(\"URL of the media provider's website.\").nullable().optional(),\n provider_name: z.string().describe(\"Name of the media provider.\").nullable().optional(),\n thumbnail_url: z.string().describe(\"URL of the thumbnail image.\").nullable().optional(),\n thumbnail_width: z.number().int().describe(\"Width of the thumbnail image in pixels.\").nullable().optional(),\n thumbnail_height: z.number().int().describe(\"Height of the thumbnail image in pixels.\").nullable().optional(),\n}).passthrough().describe(\"oEmbed metadata for embedded media content following the oEmbed specification.\");\nconst RedditRetrieveSpecificComment_MediaDataSchema = z.object({\n oembed: RedditRetrieveSpecificComment_OembedDataSchema.nullable().optional(),\n}).passthrough().describe(\"Media information for posts with embedded content.\");\nconst RedditRetrieveSpecificComment_SimplifiedRepliesSchema = z.object({\n count: z.number().int().default(0).describe(\"Number of direct replies to this comment.\").nullable().optional(),\n has_replies: z.boolean().default(false).describe(\"Whether this comment has any replies.\").nullable().optional(),\n}).passthrough().describe(\"Simplified replies information to prevent unbounded recursive data.\");\nconst RedditRetrieveSpecificComment_CommentDataSchema = z.object({\n id: z.string().describe(\"The item's unique identifier (without the t1_ or t3_ prefix).\").nullable(),\n body: z.string().describe(\"The raw text of the comment. Only present for comments (t1).\").nullable().optional(),\n name: z.string().describe(\"The item's fullname identifier (e.g., 't1_c3v7f8u' for comments, 't3_abc123' for posts).\").nullable(),\n depth: z.number().int().describe(\"The depth level in the thread. Top-level comments have depth 0.\").nullable().optional(),\n media: RedditRetrieveSpecificComment_MediaDataSchema.nullable().optional(),\n score: z.number().int().describe(\"The net score (upvotes minus downvotes).\").nullable(),\n author: z.string().describe(\"The username of the author. Can be null for deleted accounts.\").nullable().optional(),\n replies: RedditRetrieveSpecificComment_SimplifiedRepliesSchema.nullable().optional(),\n body_html: z.string().describe(\"The formatted HTML text. Only present for comments (t1).\").nullable().optional(),\n parent_id: z.string().describe(\"The ID of the parent comment (t1_) or parent submission (t3_). Only present for comments.\").nullable().optional(),\n permalink: z.string().describe(\"Permanent link to the comment or post.\").nullable().optional(),\n created_utc: z.number().describe(\"Creation timestamp in Unix time (UTC).\").nullable(),\n is_submitter: z.boolean().describe(\"Whether the comment author is also the submission author.\").nullable().optional(),\n}).passthrough().describe(\"Optimized data attributes for a Reddit comment (t1) or post (t3). Only essential fields are included to prevent oversized responses.\");\nconst RedditRetrieveSpecificComment_ThingDataSchema = z.object({\n data: RedditRetrieveSpecificComment_CommentDataSchema.nullable(),\n kind: z.string().describe(\"Type identifier for the item (e.g., 't1' for comment, 't3' for link/post).\").nullable(),\n}).passthrough().describe(\"Represents a Reddit 'thing' - can be a comment (t1) or post (t3). The data field uses CommentData which supports both types through optional fields.\");\nexport const RedditRetrieveSpecificCommentOutput = z.object({\n things: z.array(RedditRetrieveSpecificComment_ThingDataSchema).describe(\"List of items (comments or posts) matching the `id` from the request; typically contains a single item.\"),\n}).passthrough();\n\nexport const redditRetrieveSpecificComment = action(\"REDDIT_RETRIEVE_SPECIFIC_COMMENT\", {\n slug: \"reddit-retrieve-specific-comment\",\n name: \"Retrieve specific comment or post\",\n description: \"Retrieves detailed information for a single Reddit comment or post using its fullname. Returns only the specified item, not surrounding thread context; use REDDIT_RETRIEVE_POST_COMMENTS for full discussion retrieval. Deleted, removed, or quarantined items may return empty or partial payloads.\",\n input: RedditRetrieveSpecificCommentInput,\n output: RedditRetrieveSpecificCommentOutput,\n});\n"],"mappings":"
|
|
1
|
+
{"version":3,"file":"retrieve-specific-comment.cjs","names":["z","action"],"sources":["../../src/actions/retrieve-specific-comment.ts"],"sourcesContent":["import type { AppAction } from \"@keystrokehq/keystroke/app\";\nimport { z } from \"zod\";\n\nimport { action } from \"../action\";\nimport { reddit } from \"../app\";\n\nexport const RedditRetrieveSpecificCommentInput = z.object({\n id: z.string().describe(\"Reddit fullname identifier. Format: type prefix (t1_ for comments, t3_ for posts) followed by a base36 ID. Examples: 't1_abc123', 't3_1abc2de'. Note: Share URL tokens from reddit.com/r/.../s/... links are NOT valid fullnames and cannot be used directly. Note: REDDIT_RETRIEVE_POST_COMMENTS expects the bare base-36 ID without the t3_ prefix, unlike this tool.\"),\n});\nconst RedditRetrieveSpecificComment_OembedDataSchema = z.object({\n html: z.string().describe(\"HTML code for embedding the media resource.\").nullable().optional(),\n type: z.string().describe(\"Resource type (photo, video, link, or rich) per oEmbed specification.\").nullable().optional(),\n title: z.string().describe(\"Title of the embedded media.\").nullable().optional(),\n width: z.number().int().describe(\"Width of the embedded media in pixels.\").nullable().optional(),\n height: z.number().int().describe(\"Height of the embedded media in pixels.\").nullable().optional(),\n version: z.string().describe(\"oEmbed version number, typically '1.0'.\").nullable().optional(),\n cache_age: z.number().int().describe(\"Suggested cache lifetime in seconds.\").nullable().optional(),\n author_url: z.string().describe(\"URL of the media content creator's profile or website.\").nullable().optional(),\n author_name: z.string().describe(\"Name of the media content creator.\").nullable().optional(),\n description: z.string().describe(\"Text description of the embedded media resource.\").nullable().optional(),\n provider_url: z.string().describe(\"URL of the media provider's website.\").nullable().optional(),\n provider_name: z.string().describe(\"Name of the media provider.\").nullable().optional(),\n thumbnail_url: z.string().describe(\"URL of the thumbnail image.\").nullable().optional(),\n thumbnail_width: z.number().int().describe(\"Width of the thumbnail image in pixels.\").nullable().optional(),\n thumbnail_height: z.number().int().describe(\"Height of the thumbnail image in pixels.\").nullable().optional(),\n}).passthrough().describe(\"oEmbed metadata for embedded media content following the oEmbed specification.\");\nconst RedditRetrieveSpecificComment_MediaDataSchema = z.object({\n oembed: RedditRetrieveSpecificComment_OembedDataSchema.nullable().optional(),\n}).passthrough().describe(\"Media information for posts with embedded content.\");\nconst RedditRetrieveSpecificComment_SimplifiedRepliesSchema = z.object({\n count: z.number().int().default(0).describe(\"Number of direct replies to this comment.\").nullable().optional(),\n has_replies: z.boolean().default(false).describe(\"Whether this comment has any replies.\").nullable().optional(),\n}).passthrough().describe(\"Simplified replies information to prevent unbounded recursive data.\");\nconst RedditRetrieveSpecificComment_CommentDataSchema = z.object({\n id: z.string().describe(\"The item's unique identifier (without the t1_ or t3_ prefix).\").nullable(),\n body: z.string().describe(\"The raw text of the comment. Only present for comments (t1).\").nullable().optional(),\n name: z.string().describe(\"The item's fullname identifier (e.g., 't1_c3v7f8u' for comments, 't3_abc123' for posts).\").nullable(),\n depth: z.number().int().describe(\"The depth level in the thread. Top-level comments have depth 0.\").nullable().optional(),\n media: RedditRetrieveSpecificComment_MediaDataSchema.nullable().optional(),\n score: z.number().int().describe(\"The net score (upvotes minus downvotes).\").nullable(),\n author: z.string().describe(\"The username of the author. Can be null for deleted accounts.\").nullable().optional(),\n replies: RedditRetrieveSpecificComment_SimplifiedRepliesSchema.nullable().optional(),\n body_html: z.string().describe(\"The formatted HTML text. Only present for comments (t1).\").nullable().optional(),\n parent_id: z.string().describe(\"The ID of the parent comment (t1_) or parent submission (t3_). Only present for comments.\").nullable().optional(),\n permalink: z.string().describe(\"Permanent link to the comment or post.\").nullable().optional(),\n created_utc: z.number().describe(\"Creation timestamp in Unix time (UTC).\").nullable(),\n is_submitter: z.boolean().describe(\"Whether the comment author is also the submission author.\").nullable().optional(),\n}).passthrough().describe(\"Optimized data attributes for a Reddit comment (t1) or post (t3). Only essential fields are included to prevent oversized responses.\");\nconst RedditRetrieveSpecificComment_ThingDataSchema = z.object({\n data: RedditRetrieveSpecificComment_CommentDataSchema.nullable(),\n kind: z.string().describe(\"Type identifier for the item (e.g., 't1' for comment, 't3' for link/post).\").nullable(),\n}).passthrough().describe(\"Represents a Reddit 'thing' - can be a comment (t1) or post (t3). The data field uses CommentData which supports both types through optional fields.\");\nexport const RedditRetrieveSpecificCommentOutput = z.object({\n things: z.array(RedditRetrieveSpecificComment_ThingDataSchema).describe(\"List of items (comments or posts) matching the `id` from the request; typically contains a single item.\"),\n}).passthrough();\n\nexport const redditRetrieveSpecificComment: AppAction<\n typeof RedditRetrieveSpecificCommentInput,\n typeof RedditRetrieveSpecificCommentOutput,\n typeof reddit.credential\n> = action(\"REDDIT_RETRIEVE_SPECIFIC_COMMENT\", {\n slug: \"reddit-retrieve-specific-comment\",\n name: \"Retrieve specific comment or post\",\n description: \"Retrieves detailed information for a single Reddit comment or post using its fullname. Returns only the specified item, not surrounding thread context; use REDDIT_RETRIEVE_POST_COMMENTS for full discussion retrieval. Deleted, removed, or quarantined items may return empty or partial payloads.\",\n input: RedditRetrieveSpecificCommentInput,\n output: RedditRetrieveSpecificCommentOutput,\n});\n"],"mappings":";;;;AAMA,MAAa,qCAAqCA,IAAAA,EAAE,OAAO,EACzD,IAAIA,IAAAA,EAAE,O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,EACnL,CAAC,CAAC,CAAC,YAAY;AAEf,MAAa,gCAITC,eAAAA,OAAO,oCAAoC;CAC7C,MAAM;CACN,MAAM;CACN,aAAa;CACb,OAAO;CACP,QAAQ;AACV,CAAC"}
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
import { reddit } from "../app.cjs";
|
|
2
|
+
import { AppAction } from "@keystrokehq/keystroke/app";
|
|
1
3
|
import { z } from "zod";
|
|
2
4
|
|
|
3
5
|
//#region src/actions/retrieve-specific-comment.d.ts
|
|
@@ -45,9 +47,7 @@ declare const RedditRetrieveSpecificCommentOutput: z.ZodObject<{
|
|
|
45
47
|
kind: z.ZodNullable<z.ZodString>;
|
|
46
48
|
}, z.core.$loose>>;
|
|
47
49
|
}, z.core.$loose>;
|
|
48
|
-
declare const redditRetrieveSpecificComment:
|
|
49
|
-
id: string;
|
|
50
|
-
}, unknown, import("@keystrokehq/shared").ResolvedCredentials<readonly [import("@keystrokehq/shared").Credential]>, readonly [import("@keystrokehq/shared").Credential]>;
|
|
50
|
+
declare const redditRetrieveSpecificComment: AppAction<typeof RedditRetrieveSpecificCommentInput, typeof RedditRetrieveSpecificCommentOutput, typeof reddit.credential>;
|
|
51
51
|
//#endregion
|
|
52
52
|
export { redditRetrieveSpecificComment };
|
|
53
53
|
//# sourceMappingURL=retrieve-specific-comment.d.cts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"retrieve-specific-comment.d.cts","names":[],"sources":["../../src/actions/retrieve-specific-comment.ts"],"mappings":"
|
|
1
|
+
{"version":3,"file":"retrieve-specific-comment.d.cts","names":[],"sources":["../../src/actions/retrieve-specific-comment.ts"],"mappings":";;;;;cAMa,kCAAA,EAAkC,CAAA,CAAA,SAAA;;;cA8ClC,mCAAA,EAAmC,CAAA,CAAA,SAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;cAInC,6BAAA,EAA+B,SAAA,QACnC,kCAAA,SACA,mCAAA,SACA,MAAA,CAAO,UAAA"}
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
import { reddit } from "../app.mjs";
|
|
2
|
+
import { AppAction } from "@keystrokehq/keystroke/app";
|
|
1
3
|
import { z } from "zod";
|
|
2
4
|
|
|
3
5
|
//#region src/actions/retrieve-specific-comment.d.ts
|
|
@@ -45,9 +47,7 @@ declare const RedditRetrieveSpecificCommentOutput: z.ZodObject<{
|
|
|
45
47
|
kind: z.ZodNullable<z.ZodString>;
|
|
46
48
|
}, z.core.$loose>>;
|
|
47
49
|
}, z.core.$loose>;
|
|
48
|
-
declare const redditRetrieveSpecificComment:
|
|
49
|
-
id: string;
|
|
50
|
-
}, unknown, import("@keystrokehq/shared").ResolvedCredentials<readonly [import("@keystrokehq/shared").Credential]>, readonly [import("@keystrokehq/shared").Credential]>;
|
|
50
|
+
declare const redditRetrieveSpecificComment: AppAction<typeof RedditRetrieveSpecificCommentInput, typeof RedditRetrieveSpecificCommentOutput, typeof reddit.credential>;
|
|
51
51
|
//#endregion
|
|
52
52
|
export { redditRetrieveSpecificComment };
|
|
53
53
|
//# sourceMappingURL=retrieve-specific-comment.d.mts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"retrieve-specific-comment.d.mts","names":[],"sources":["../../src/actions/retrieve-specific-comment.ts"],"mappings":"
|
|
1
|
+
{"version":3,"file":"retrieve-specific-comment.d.mts","names":[],"sources":["../../src/actions/retrieve-specific-comment.ts"],"mappings":";;;;;cAMa,kCAAA,EAAkC,CAAA,CAAA,SAAA;;;cA8ClC,mCAAA,EAAmC,CAAA,CAAA,SAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;cAInC,6BAAA,EAA+B,SAAA,QACnC,kCAAA,SACA,mCAAA,SACA,MAAA,CAAO,UAAA"}
|