Social media5 min readBy Purrkey teamUpdated

How to fetch a Reddit post by URL with full body text

Get one Reddit post's body, score, comment count, upvote ratio and subreddit as normalized JSON from a post URL

On this page

You have 20 Reddit post URLs from a community listening export and need to decide which threads to quote in a newsletter. Fetch each post by URL with anyapi.reddit.post, then rank the threads on score, comment count and upvote ratio in one worksheet

The worksheet is the deliverable: one row per URL with title, author, subreddit, score, numComments, upvoteRatio, body, url, createdUtc, found and decision. No call has been run for this article, so the tables below are a design and the values in them are placeholders

Example input and worksheet design

One invented URL, labelled Example, is a placeholder reddit post address. Your export holds real addresses saved from the post page or from a permalink, so replace the example before running anything

Values here are placeholders showing the shape

titleauthorsubredditscorenumCommentsupvoteRatiofounddecision
(post title)(username)(subreddit name)000.00truequote, hold or drop

The body, url and createdUtc values sit in the same row, ready for the copy desk. Quote means the row supplies a passage and a link, hold means it goes to a second pass, and drop means the thread does not make the five

Step 1: fetch each post by URL

anyapi.reddit.post takes the field url, a string of at least one character, and the catalog describes the call as: "Fetch a single Reddit post by URL, including its full body text, score, comment count, upvote ratio, and subreddit, as normalized JSON." The tool is called through POST /v1/runs with toolId anyapi.reddit.post

The url pattern accepts reddit.com and redd.it links that carry /comments/ or /gallery/ path segments, including the subreddit post, user post, direct comments, and gallery forms. Copy the address from the post page or from a saved permalink

Limit at this step: a share link or a link to another site does not match the pattern. The contract says any other link is refused as invalid input, with no charge, so a refused row returns no data and bills nothing. Clean the export first and keep the rows whose paths contain /comments/ or /gallery/

Step 2: read the fields that drive the decision

found is the first field to read. True means the post came back in data, false means the lookup returned nothing and reason is not_found. A found: false answer is a successful call, not an error

score, numComments and upvoteRatio are the ranking inputs. score is net upvotes minus downvotes at fetch time, numComments is the comment total, and upvoteRatio is a fraction between 0 and 1. A ratio of zero is what the upstream returns when it does not report the ratio, so treat 0 as unreported rather than as a weak thread

body holds the post's own text as Markdown. It is empty for link posts, which carry no body, so those rows cannot supply a passage; their destination sits in url, while permalink holds the canonical thread path. Before quoting, check isLocked and isArchived, since both block new comments, and note that an absent flag means unknown rather than false. createdUtc is Unix seconds, multiplied by 1000 for a JS Date. An image URL is signed and time-limited, so fetch it promptly and keep the query string intact

The agent prompt

Agent prompt
Set up https://purrkey.app/SKILL.md, then use Purrkey to fetch Reddit posts
by URL. Check the current inputs and the price of anyapi.reddit.post before
running anything. Call it once per URL below and return one table with
title, author, subreddit, score, numComments, upvoteRatio, body, url,
createdUtc, found and decision. Mark found false rows as drop and leave
their data fields empty. Do not request a URL that is not a reddit.com or
redd.it /comments/ or /gallery/ link.

PASTE_ONE_EXPORT_URL_HERE

The placeholder line above stands in for the invented Example. Paste your 20 export URLs in its place, then sort the returned rows by numComments and score and keep the top five for the newsletter

Estimated tool cost

Prices come from the Purrkey catalog, read on November 12, 2026, price revision anyapi-catalog-2026-11-05. The unit is max_call: "Maximum per call. Successful runs settle at the actual AnyAPI charge." The totals below are ceilings, not settled charges

StepFormulaUnit pricePlanned quantityTotal
Check 20 post URLscalls x max price$0.00224 per call20$0.0448
Check 100 post URLscalls x max price$0.00224 per call100$0.224

A found: false row still counts as a call. Model fees for the agent are not counted in either row

Fetch the first five URLs

Run five URLs from the export through the tool page at https://purrkey.app/tools/reddit?q=post and compare the price and the url pattern there against this plan before the full batch

Get started by giving this to your agent

  • Claude Code
  • Codex
  • Gemini CLI
  • Cursor
  • GitHub Copilot
Set up https://purrkey.app/SKILL.md, then use Purrkey to show me what I can do with Reddit.
Explore Reddit tools and pricing

FAQ

How do I fetch a Reddit post by URL with its full body text?

Run the post URL through anyapi.reddit.post and read body in the returned data record, where the post's own text arrives as Markdown. Link posts carry no body, so those rows come back empty.

What Reddit URLs does anyapi.reddit.post accept?

reddit.com and redd.it URLs that carry /comments/ or /gallery/, including the subreddit post, user post, direct comments, and gallery forms. Share links and links to other sites are refused as invalid input, with no charge.

What does found: false mean in the Reddit post response?

The lookup returned nothing, and reason says the post was not found. It is a successful call, not an error.

What do score, numComments and upvoteRatio measure?

score is net upvotes minus downvotes at fetch time, numComments is the comment total and upvoteRatio is a fraction between 0 and 1. A ratio of zero is what the upstream returns when it does not report the ratio.

How much does it cost to check 20 Reddit post URLs?

At most $0.0448 at the $0.00224 per call ceiling, and at most $0.224 for 100 URLs.

Why is the body empty for a Reddit link post?

Link posts carry no selftext, so body comes back empty. The post's destination link sits in url and permalink holds the canonical thread path.

Can I fetch a Reddit share link?

Only reddit.com or redd.it URLs with /comments/ or /gallery/ are accepted. The contract says any other link is refused as invalid input, with no charge.

Next step

Try this with Reddit

The tool directory lists every endpoint with its current price. Inspect the inputs there, then let your agent run a small batch before scaling up.

See Reddit tools

Share this article