> ## 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.

# Get a Facebook profile or Page

> Get a Facebook profile or Page from its link, username or numeric ID: name, username, bio, category, verified badge, follower and following counts, intro details such as city, work, address and contact email, websites, and profile and cover pictures. Costs 1 credit per request.



## OpenAPI

````yaml /openapi.json post /facebook/get-profile
openapi: 3.1.0
info:
  title: Bridgly API
  description: >-
    Web scraping API for LinkedIn, X (Twitter), Reddit, GitHub, Instagram and
    TikTok. Authenticated endpoints accept a Bridgly API key (`bgly_…`) via
    `Authorization: Bearer <token>`.
  version: 1.0.0
servers:
  - url: https://api.bridgly.app
    description: Production
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.
  - name: GitHub
    description: >-
      Fetch GitHub profiles, pinned repos, contributions, repositories, stars,
      and projects via GitHub's GraphQL API.
  - name: Instagram
    description: Scrape Instagram profiles, posts, followers, and search.
  - name: TikTok
    description: Fetch TikTok profiles.
  - name: Meta Ads
    description: >-
      Search the Meta Ad Library: ads, ad details, and advertisers on Facebook
      and Instagram.
  - name: Facebook
    description: >-
      Scrape Facebook profiles, Pages, posts, comments, groups, Marketplace, and
      search.
paths:
  /facebook/get-profile:
    post:
      tags:
        - Facebook
      summary: Get a Facebook profile or Page
      description: >-
        Get a Facebook profile or Page from its link, username or numeric ID:
        name, username, bio, category, verified badge, follower and following
        counts, intro details such as city, work, address and contact email,
        websites, and profile and cover pictures. Costs 1 credit per request.
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                profile:
                  type: string
                  minLength: 1
                  description: >-
                    The profile or Page: its link, username or numeric ID, e.g.
                    "https://www.facebook.com/NASA", "NASA" or
                    "100044561550831".
                cacheMaxAgeHours:
                  description: >-
                    Accept a cached result up to this many hours old, at no
                    cost; its `cachedAt` says when it was fetched. Without one
                    that recent, fresh data is fetched at the normal price.
                    Leave it out to always get fresh data, e.g. 24.
                  type: integer
                  exclusiveMinimum: 0
                  maximum: 9007199254740991
                cacheOnly:
                  description: >-
                    Return only a cached result, never fresh data. With
                    `cacheMaxAgeHours`, only one that recent; without it, the
                    latest of any age. Responds 404, at no cost, when there is
                    none, e.g. true.
                  type: boolean
              required:
                - profile
      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.
                  cachedAt:
                    anyOf:
                      - type: string
                        format: date-time
                        pattern: >-
                          ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$
                      - type: 'null'
                    description: >-
                      When the returned data was fetched, if it came from the
                      cache. Null when it was fetched fresh for this request.
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        description: Numeric profile ID, e.g. "100044561550831".
                      name:
                        anyOf:
                          - type: string
                          - type: 'null'
                        description: Display name.
                      username:
                        anyOf:
                          - type: string
                          - type: 'null'
                        description: >-
                          Username in the profile link, e.g. "NASA"; null when
                          the profile has none.
                      pageId:
                        anyOf:
                          - type: string
                          - type: 'null'
                        description: >-
                          Numeric ID of the Facebook Page behind the profile,
                          e.g. "54971236771", which other tools may use for it.
                      url:
                        anyOf:
                          - type: string
                          - type: 'null'
                        description: Profile link.
                      alternateName:
                        anyOf:
                          - type: string
                          - type: 'null'
                        description: Other name shown beside the name, such as a nickname.
                      isPage:
                        anyOf:
                          - type: boolean
                          - type: 'null'
                        description: >-
                          True for a Page (business, brand, organization), false
                          for a person.
                      isVerified:
                        anyOf:
                          - type: boolean
                          - type: 'null'
                        description: True when the profile shows the verified badge.
                      category:
                        anyOf:
                          - type: string
                          - type: 'null'
                        description: >-
                          Category shown on the profile, e.g. "Government
                          organization".
                      bio:
                        anyOf:
                          - type: string
                          - type: 'null'
                        description: Short bio shown under the name.
                      details:
                        type: array
                        items:
                          type: object
                          properties:
                            type:
                              anyOf:
                                - type: string
                                - type: 'null'
                              description: >-
                                What the detail is, as Facebook names it, e.g.
                                "CURRENT_CITY", "HOMETOWN", "BUSINESS_EMAIL",
                                "CONSOLIDATED_ADDRESS" or "RATINGS"; null when
                                Facebook gives it no type.
                            text:
                              type: string
                              description: >-
                                The detail as shown, e.g. "Lives in Palo Alto,
                                California" or "205 E Houston St, New York, NY,
                                United States, 10002".
                            links:
                              type: array
                              items:
                                type: object
                                properties:
                                  type:
                                    anyOf:
                                      - type: string
                                      - type: 'null'
                                    description: >-
                                      What the text links to, as Facebook names
                                      it, e.g. "User", "Page", "Group",
                                      "Hashtag" or "ExternalUrl".
                                  id:
                                    anyOf:
                                      - type: string
                                      - type: 'null'
                                    description: >-
                                      Numeric ID of the linked profile, Page,
                                      group or hashtag; null for a web link.
                                  name:
                                    anyOf:
                                      - type: string
                                      - type: 'null'
                                    description: >-
                                      Its name, or the text that links to it,
                                      e.g. "#travel".
                                  url:
                                    anyOf:
                                      - type: string
                                      - type: 'null'
                                    description: >-
                                      Its link; for a web link, the site it
                                      opens, e.g. "https://go.nasa.gov/4C7G3xx".
                                required:
                                  - type
                                  - id
                                  - name
                                  - url
                                additionalProperties: false
                              description: >-
                                Pages, profiles and sites the detail links to,
                                e.g. the city or the spouse.
                          required:
                            - type
                            - text
                            - links
                          additionalProperties: false
                        description: >-
                          Details from the profile intro: where they live and
                          work, contact email, address, ratings, price range and
                          similar.
                      followerCount:
                        anyOf:
                          - type: number
                          - type: 'null'
                        description: >-
                          Followers, as Facebook shows them; large counts are
                          rounded, e.g. 28000000 for "28M".
                      followingCount:
                        anyOf:
                          - type: number
                          - type: 'null'
                        description: Profiles this one follows, as Facebook shows it.
                      friendCount:
                        anyOf:
                          - type: number
                          - type: 'null'
                        description: >-
                          Friends, as Facebook shows it; null when hidden or for
                          Pages.
                      websites:
                        type: array
                        items:
                          type: string
                        description: >-
                          Website links listed on the profile, e.g.
                          "http://www.nasa.gov/".
                      profilePictureUrl:
                        anyOf:
                          - type: string
                          - type: 'null'
                        description: Profile picture URL.
                      coverPhotoUrl:
                        anyOf:
                          - type: string
                          - type: 'null'
                        description: Cover photo URL.
                    required:
                      - id
                      - name
                      - username
                      - pageId
                      - url
                      - alternateName
                      - isPage
                      - isVerified
                      - category
                      - bio
                      - details
                      - followerCount
                      - followingCount
                      - friendCount
                      - websites
                      - profilePictureUrl
                      - coverPhotoUrl
                    additionalProperties: false
                required:
                  - timeMs
                  - creditsCost
                  - cachedAt
                  - 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
        '403':
          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
        '422':
          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: []
      x-codeSamples:
        - lang: typescript
          label: Bridgly SDK
          source: |-
            import { Bridgly } from '@bridgly/sdk';

            const client = new Bridgly({ apiKey: process.env.BRIDGLY_API_KEY });

            const res = await client.facebook.getProfile({
              profile: "string",
            });
            if (res.type === 'success') console.log(res.data);
components:
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        A Bridgly API key (`bgly_…`). Metered endpoints deduct credits from the
        resolved account.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.