Skip to main content

Reddit

Base URL: https://drain.lat/api/v1/reddit
Fetch a public Reddit user profile.
GET /api/v1/reddit/profile/:username
username
string
required
The Reddit username to look up.
curl "https://drain.lat/api/v1/reddit/profile/spez" \
  -H "x-api-key: YOUR_API_KEY"
username
string
Reddit username.
bio
string
Profile bio.
avatarUrl
string
Avatar image URL.
karma
object
isPremium
boolean
Whether the account has Reddit Premium.
isMod
boolean
Whether the account is a moderator.
isEmployee
boolean
Whether the account is a Reddit employee.
created
string
Account creation date (ISO 8601).
profileUrl
string
Link to the Reddit profile.
Response
{
  "username": "spez",
  "bio": "CEO of Reddit.",
  "avatarUrl": "https://styles.redditmedia.com/t5_...",
  "karma": {
    "post": 142300,
    "comment": 98400,
    "total": 240700,
    "awardee": 12400,
    "awarder": 3200
  },
  "isPremium": true,
  "isMod": true,
  "isEmployee": true,
  "created": "2005-06-06T04:00:00.000Z",
  "profileUrl": "https://www.reddit.com/user/spez",
  "scrapedAt": "2026-05-05T12:00:00.000Z"
}
Get the last 10 posts from a Reddit user.
GET /api/v1/reddit/profile/:username/posts
username
string
required
The Reddit username.
curl "https://drain.lat/api/v1/reddit/profile/spez/posts" \
  -H "x-api-key: YOUR_API_KEY"
username
string
Reddit username.
posts
array
total
number
Number of posts returned.
Response
{
  "username": "spez",
  "posts": [
    {
      "id": "t3_abc123",
      "title": "Addressing your questions about the API changes",
      "subreddit": "reddit",
      "score": 48200,
      "upvoteRatio": 0.81,
      "comments": 14300,
      "thumbnailUrl": "https://b.thumbs.redditmedia.com/...",
      "url": "https://www.reddit.com/r/reddit/comments/abc123/",
      "createdAt": "2026-04-20T18:00:00.000Z"
    }
  ],
  "total": 10,
  "scrapedAt": "2026-05-05T12:00:00.000Z"
}
Get a user’s recent comments.
GET /api/v1/reddit/profile/:username/comments
username
string
required
The Reddit username.
limit
number
Number of comments to return. Max 25. Default 10.
curl "https://drain.lat/api/v1/reddit/profile/spez/comments?limit=10" \
  -H "x-api-key: YOUR_API_KEY"
username
string
Reddit username.
comments
array
total
number
Number of comments returned.
Response
{
  "username": "spez",
  "comments": [
    {
      "id": "abc123",
      "body": "Thanks for the feedback.",
      "subreddit": "announcements",
      "postTitle": "Reddit update",
      "permalink": "https://www.reddit.com/r/announcements/comments/abc/reddit_update/xyz",
      "score": 4200,
      "created": "2026-05-01T12:00:00.000Z"
    }
  ],
  "total": 10,
  "scrapedAt": "2026-05-08T10:00:00.000Z"
}
Get info about a subreddit.
GET /api/v1/reddit/r/:subreddit
subreddit
string
required
The subreddit name (without r/).
curl "https://drain.lat/api/v1/reddit/r/funny" \
  -H "x-api-key: YOUR_API_KEY"
id
string
Subreddit ID.
name
string
Subreddit name.
title
string
Subreddit title.
description
string
Subreddit description.
subscribers
number
Subscriber count.
activeUsers
number
Currently active users.
isNsfw
boolean
Whether the subreddit is NSFW.
created
string
Creation date (ISO 8601).
iconUrl
string
Subreddit icon URL.
bannerUrl
string
Subreddit banner URL.
url
string
Link to the subreddit.
Response
{
  "id": "2qh33",
  "name": "funny",
  "title": "funny",
  "description": "Welcome to r/funny",
  "subscribers": 58000000,
  "activeUsers": 12000,
  "isNsfw": false,
  "created": "2008-01-25T05:11:28.000Z",
  "iconUrl": "https://...",
  "bannerUrl": "https://...",
  "url": "https://www.reddit.com/r/funny",
  "scrapedAt": "2026-05-08T10:00:00.000Z"
}
Get posts from a subreddit.
GET /api/v1/reddit/r/:subreddit/posts
subreddit
string
required
The subreddit name (without r/).
sort
string
Sort order. Options: hot, new, top, rising. Default hot.
limit
number
Number of posts to return. Max 25. Default 10.
curl "https://drain.lat/api/v1/reddit/r/funny/posts?sort=hot&limit=10" \
  -H "x-api-key: YOUR_API_KEY"
subreddit
string
Subreddit name.
sort
string
Sort order used.
posts
array
total
number
Number of posts returned.
Response
{
  "subreddit": "funny",
  "sort": "hot",
  "posts": [
    {
      "id": "abc123",
      "title": "My cat figured out how to open doors",
      "author": "user123",
      "url": "https://i.redd.it/abc.jpg",
      "permalink": "https://www.reddit.com/r/funny/comments/abc123/",
      "score": 98000,
      "upvoteRatio": 0.97,
      "numComments": 1200,
      "isVideo": false,
      "thumbnail": "https://...",
      "created": "2026-05-08T08:00:00.000Z"
    }
  ],
  "total": 10,
  "scrapedAt": "2026-05-08T10:00:00.000Z"
}