> ## Documentation Index
> Fetch the complete documentation index at: https://docs.bridgly.app/llms.txt
> Use this file to discover all available pages before exploring further.

# Search Reddit across posts, communities and users



## OpenAPI

````yaml /openapi.json post /reddit/search/all
openapi: 3.1.0
info:
  title: Bridgly API
  description: >-
    Web scraping API for LinkedIn, X (Twitter) and Reddit. Authenticated
    endpoints accept a Bridgly API key (`bgly_…`) via `Authorization: Bearer
    <token>`.
  version: 1.0.0
servers:
  - url: https://api.bridgly.app
    description: Production
  - url: http://localhost:4000
    description: Local
security: []
tags:
  - name: LinkedIn
    description: Scrape LinkedIn profiles, companies, posts, and search.
  - name: Reddit
    description: Scrape Reddit posts, subreddits, users, and search.
  - name: X (Twitter)
    description: Scrape tweets and search X.
paths:
  /reddit/search/all:
    post:
      tags:
        - Reddit
      summary: Search Reddit across posts, communities and users
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                query:
                  type: string
                  description: >-
                    The text to search Reddit for, e.g. "openai", "best
                    keyboard".
                subreddit:
                  description: >-
                    Restrict the search to a single subreddit (name without the
                    "r/" prefix). Only applies to post search.
                  type: string
                sort:
                  type: string
                  enum:
                    - relevance
                    - hot
                    - top
                    - new
                    - comments
                  description: Result ordering. Defaults to "relevance".
                time:
                  type: string
                  enum:
                    - hour
                    - day
                    - week
                    - month
                    - year
                    - all
                  description: Restrict results to a recent window. Defaults to "all".
                after:
                  description: >-
                    Pagination cursor (a Reddit fullname returned as `after`
                    from a previous page).
                  type: string
                limit:
                  description: Number of results to return (1–100). Defaults to 25.
                  type: integer
                  minimum: 1
                  maximum: 100
              required:
                - query
      responses:
        '200':
          description: Default Response
          content:
            application/json:
              schema:
                type: object
                properties:
                  timeMs:
                    type: number
                    description: >-
                      Wall-clock time the request took to complete, in
                      milliseconds.
                  creditsCost:
                    type: number
                    description: Number of account credits this request consumed.
                  data:
                    type: object
                    properties:
                      results:
                        type: array
                        items:
                          oneOf:
                            - type: object
                              properties:
                                id:
                                  type: string
                                  description: >-
                                    Base-36 post id without the `t3_` prefix,
                                    e.g. "1u3a0cd".
                                fullname:
                                  type: string
                                  description: >-
                                    Reddit fullname including the type prefix,
                                    e.g. "t3_1u3a0cd".
                                title:
                                  anyOf:
                                    - type: string
                                    - type: 'null'
                                  description: Post title.
                                author:
                                  anyOf:
                                    - type: string
                                    - type: 'null'
                                  description: >-
                                    Author username, or "[deleted]" when
                                    removed.
                                authorFullname:
                                  anyOf:
                                    - type: string
                                    - type: 'null'
                                  description: Author account fullname, e.g. "t2_98wao505".
                                selftext:
                                  anyOf:
                                    - type: string
                                    - type: 'null'
                                  description: >-
                                    Self-post body text (empty string for link
                                    posts).
                                score:
                                  anyOf:
                                    - type: number
                                    - type: 'null'
                                  description: Net score (upvotes minus downvotes).
                                upvoteRatio:
                                  anyOf:
                                    - type: number
                                    - type: 'null'
                                  description: Fraction of votes that are upvotes, 0–1.
                                numComments:
                                  anyOf:
                                    - type: number
                                    - type: 'null'
                                  description: Total comment count.
                                createdUtc:
                                  anyOf:
                                    - type: number
                                    - type: 'null'
                                  description: Creation time as a Unix epoch in seconds.
                                permalink:
                                  type: string
                                  description: >-
                                    Site-relative permalink path, e.g.
                                    "/r/technology/comments/…".
                                postUrl:
                                  type: string
                                  description: Absolute URL to the post on reddit.com.
                                url:
                                  anyOf:
                                    - type: string
                                    - type: 'null'
                                  description: >-
                                    The URL the post points to — the external
                                    link for link posts, or the post permalink
                                    for self posts.
                                subreddit:
                                  anyOf:
                                    - type: string
                                    - type: 'null'
                                  description: >-
                                    Subreddit name without prefix, e.g.
                                    "technology".
                                subredditPrefixed:
                                  anyOf:
                                    - type: string
                                    - type: 'null'
                                  description: >-
                                    Subreddit name with prefix, e.g.
                                    "r/technology".
                                subredditSubscribers:
                                  anyOf:
                                    - type: number
                                    - type: 'null'
                                  description: >-
                                    Subscriber count of the subreddit, when
                                    present.
                                linkFlairText:
                                  anyOf:
                                    - type: string
                                    - type: 'null'
                                  description: Link flair label, if any.
                                domain:
                                  anyOf:
                                    - type: string
                                    - type: 'null'
                                  description: >-
                                    Source domain, e.g. "self.technology" or
                                    "nytimes.com".
                                thumbnail:
                                  anyOf:
                                    - type: string
                                    - type: 'null'
                                  description: >-
                                    Thumbnail URL, or a sentinel like
                                    "self"/"default"/"nsfw" when there is no
                                    image.
                                isSelf:
                                  type: boolean
                                  description: Whether this is a self (text) post.
                                isVideo:
                                  type: boolean
                                  description: Whether the post hosts a Reddit video.
                                over18:
                                  type: boolean
                                  description: Whether the post is marked NSFW.
                                spoiler:
                                  type: boolean
                                  description: Whether the post is marked as a spoiler.
                                stickied:
                                  type: boolean
                                  description: Whether the post is pinned in its subreddit.
                                locked:
                                  type: boolean
                                  description: Whether commenting is locked.
                                type:
                                  type: string
                                  enum:
                                    - post
                              required:
                                - id
                                - fullname
                                - title
                                - author
                                - authorFullname
                                - selftext
                                - score
                                - upvoteRatio
                                - numComments
                                - createdUtc
                                - permalink
                                - postUrl
                                - url
                                - subreddit
                                - subredditPrefixed
                                - subredditSubscribers
                                - linkFlairText
                                - domain
                                - thumbnail
                                - isSelf
                                - isVideo
                                - over18
                                - spoiler
                                - stickied
                                - locked
                                - type
                              additionalProperties: false
                            - type: object
                              properties:
                                id:
                                  type: string
                                  description: >-
                                    Base-36 subreddit id without the `t5_`
                                    prefix, e.g. "3b9u5".
                                fullname:
                                  type: string
                                  description: >-
                                    Reddit fullname including the prefix, e.g.
                                    "t5_3b9u5".
                                name:
                                  anyOf:
                                    - type: string
                                    - type: 'null'
                                  description: >-
                                    Subreddit name without prefix, e.g.
                                    "OpenAI".
                                namePrefixed:
                                  anyOf:
                                    - type: string
                                    - type: 'null'
                                  description: Subreddit name with prefix, e.g. "r/OpenAI".
                                title:
                                  anyOf:
                                    - type: string
                                    - type: 'null'
                                  description: Subreddit display title.
                                description:
                                  anyOf:
                                    - type: string
                                    - type: 'null'
                                  description: Public, short description of the subreddit.
                                subscribers:
                                  anyOf:
                                    - type: number
                                    - type: 'null'
                                  description: Subscriber count.
                                over18:
                                  type: boolean
                                  description: Whether the subreddit is marked NSFW.
                                subredditType:
                                  anyOf:
                                    - type: string
                                    - type: 'null'
                                  description: >-
                                    Access type, e.g. "public", "restricted",
                                    "private".
                                url:
                                  anyOf:
                                    - type: string
                                    - type: 'null'
                                  description: Site-relative path, e.g. "/r/OpenAI/".
                                communityUrl:
                                  type: string
                                  description: Absolute URL to the subreddit on reddit.com.
                                iconUrl:
                                  anyOf:
                                    - type: string
                                    - type: 'null'
                                  description: >-
                                    Community icon (falls back to the legacy
                                    icon), if any.
                                bannerUrl:
                                  anyOf:
                                    - type: string
                                    - type: 'null'
                                  description: Banner image URL, if any.
                                createdUtc:
                                  anyOf:
                                    - type: number
                                    - type: 'null'
                                  description: Creation time as a Unix epoch in seconds.
                                type:
                                  type: string
                                  enum:
                                    - community
                              required:
                                - id
                                - fullname
                                - name
                                - namePrefixed
                                - title
                                - description
                                - subscribers
                                - over18
                                - subredditType
                                - url
                                - communityUrl
                                - iconUrl
                                - bannerUrl
                                - createdUtc
                                - type
                              additionalProperties: false
                            - type: object
                              properties:
                                id:
                                  type: string
                                  description: >-
                                    Base-36 account id without the `t2_` prefix,
                                    e.g. "10knboj9s0".
                                username:
                                  type: string
                                  description: Reddit username, e.g. "OpenAI".
                                profileUrl:
                                  type: string
                                  description: >-
                                    Absolute profile URL
                                    (https://www.reddit.com/user/<username>/).
                                commentKarma:
                                  anyOf:
                                    - type: number
                                    - type: 'null'
                                  description: Comment karma.
                                linkKarma:
                                  anyOf:
                                    - type: number
                                    - type: 'null'
                                  description: Post (link) karma.
                                createdUtc:
                                  anyOf:
                                    - type: number
                                    - type: 'null'
                                  description: >-
                                    Account creation time as a Unix epoch in
                                    seconds.
                                iconUrl:
                                  anyOf:
                                    - type: string
                                    - type: 'null'
                                  description: Profile/snoovatar avatar URL, if any.
                                isGold:
                                  type: boolean
                                  description: Whether the account has Reddit Premium.
                                isMod:
                                  type: boolean
                                  description: Whether the account moderates any subreddit.
                                isEmployee:
                                  type: boolean
                                  description: Whether the account is a Reddit employee.
                                verified:
                                  type: boolean
                                  description: Whether the account is verified.
                                hasVerifiedEmail:
                                  type: boolean
                                  description: Whether the account has a verified email.
                                acceptFollowers:
                                  type: boolean
                                  description: Whether the account accepts followers.
                                type:
                                  type: string
                                  enum:
                                    - user
                              required:
                                - id
                                - username
                                - profileUrl
                                - commentKarma
                                - linkKarma
                                - createdUtc
                                - iconUrl
                                - isGold
                                - isMod
                                - isEmployee
                                - verified
                                - hasVerifiedEmail
                                - acceptFollowers
                                - type
                              additionalProperties: false
                        description: Matching results across posts, communities, and users.
                      query:
                        type: string
                        description: The query string that was searched on Reddit.
                      after:
                        anyOf:
                          - type: string
                          - type: 'null'
                        description: >-
                          Pagination cursor for the next page (Reddit `after`
                          fullname), or null when there are no more results.
                    required:
                      - results
                      - query
                      - after
                    additionalProperties: false
                required:
                  - timeMs
                  - creditsCost
                  - data
                additionalProperties: false
        '400':
          description: Default Response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  message:
                    type: string
                    description: Human-readable description of what went wrong.
                required:
                  - status
                  - message
                additionalProperties: false
        '401':
          description: Default Response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  message:
                    type: string
                    description: Human-readable description of what went wrong.
                required:
                  - status
                  - message
                additionalProperties: false
        '402':
          description: Default Response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  message:
                    type: string
                    description: Human-readable description of what went wrong.
                required:
                  - status
                  - message
                additionalProperties: false
        '404':
          description: Default Response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  message:
                    type: string
                    description: Human-readable description of what went wrong.
                required:
                  - status
                  - message
                additionalProperties: false
        '500':
          description: Default Response
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    enum:
                      - error
                  message:
                    type: string
                    description: Human-readable description of what went wrong.
                required:
                  - status
                  - message
                additionalProperties: false
      security:
        - bearerAuth: []
components:
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        A Bridgly API key (`bgly_…`). Metered endpoints deduct credits from the
        resolved account.

````