Inbox · Reddit Search

Search posts

Searches posts.

GEThttps://api.pozy.ai/v1/reddit/search
searchReddit

Guides: Mentions, Reddit

Request

Send your API key as Authorization: Bearer pz_live_.... Read-only keys can call it. Keys with the engagement resource group disabled get 403 resource_group_disabled. Authentication

Query parameters

NameTypeNotes
accountIdrequiredstring
subredditstring
qrequiredstring
restrict_srstringOne of 0, 1
sortstringOne of relevance, hot, top, new, commentsDefault new
limitintegerDefault 25At most 100
afterstring

Example

curl -X GET "https://api.pozy.ai/v1/reddit/search?accountId=696e0b682d0a31188e7a2ba9&q=string&limit=25" \
  -H "Authorization: Bearer $POZY_API_KEY"

Response

200 on success

  • itemsarray of object
    16 child fields
    • idstring
    • fullnamestring
    • titlestring
    • authorstring
    • subredditstring
    • urlstring
    • permalinkstring
    • selftextstring
    • createdUtcnumber
    • scoreinteger
    • numCommentsinteger
    • over18boolean
    • stickiedboolean
    • flairTextstring

      Can be null.

    • isGalleryboolean
    • galleryImagesarray of string (URL)
  • afterstring

    Can be null.

  • beforestring

    Can be null.

200 response
{
  "items": [
    {
      "id": "6bfebd43ddc270f6d2c56fc5",
      "fullname": "Acme",
      "title": "Launch day",
      "author": "string",
      "subreddit": "string",
      "url": "https://pozy.ai/media/example-1.jpg",
      "permalink": "string",
      "selftext": "Hello from Pozy",
      "createdUtc": 12.5,
      "score": 1,
      "numComments": 1,
      "over18": true,
      "stickied": true,
      "flairText": "Hello from Pozy",
      "isGallery": true,
      "galleryImages": [
        "https://pozy.ai/media/example-1.jpg"
      ]
    }
  ],
  "after": "string",
  "before": "string"
}

Errors

Errors use one shape: { error, type, code, param?, details? }. The ones you are most likely to see here:

400invalid_request_errorA parameter or body field is missing or invalid. param names it.
401authentication_errorThe API key is missing, revoked or expired.
403permission_errorThe key is scoped to other profiles or has this resource group disabled.
429rate_limit_errorToo many requests this minute. Wait for Retry-After seconds.

Every code is listed in Errors.

More in Reddit Search