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

# Connect a social account

> Connects a Bluesky or Medium account with your credentials. Other networks connect only by browser sign-in in the Followr app.

- **Bluesky:** the `handle` (or email address), and an app password as `social_token` (Bluesky **Settings > Privacy and security > App passwords**). Accounts hosted by Bluesky are supported.
- **Medium:** an integration token as `social_token`.

Followr checks the credentials with the network, then copies the profile name, handle and picture. Credentials are never returned.

One account per network per company: if the network is already connected, you get `400`. A disconnected account comes back with its old `id`, and `200` instead of `201`.

Roles: owner, admin and user.




## OpenAPI

````yaml /api-reference/openapi.json post /companies/{company_id}/socialNetworks
openapi: 3.1.0
info:
  title: Followr API
  version: 1.0.0
  summary: Publish, schedule and create social media content programmatically.
  description: >
    The Followr REST API gives your code the same engine as the Followr app:
    brands, social accounts, posts and scheduling, the media library, AI
    generation, music and the social inbox.


    Send every request over HTTPS to `https://api.followr.ai/api`, with an API
    key as a Bearer token. Bodies are JSON.
  contact:
    name: Followr Support
    email: hello@followr.ai
    url: https://followr.ai
  termsOfService: https://followr.ai/terms
servers:
  - url: https://api.followr.ai/api
    description: Production
security:
  - bearerAuth: []
tags:
  - name: Users
    description: |
      The person behind an API key. Use `me` as the ID for the key's user.
  - name: Companies
    description: >
      Brands or client workspaces. Each uses the plan of the account that
      created it (`user_id`).
  - name: Team
    description: |
      Company members and their roles: invite, change roles, remove.
  - name: Brand style
    description: >
      How a company's AI pictures look, and the default brand sound for AI
      videos.
  - name: API keys
    description: |
      REST API keys, MCP keys and app sign-ins.
  - name: Social accounts
    description: >
      A social account is a profile, Page or channel a company has connected,
      such as an Instagram professional account or a LinkedIn page. A company
      has at most one per network. Most networks connect by browser sign-in in
      the Followr app; Bluesky and Medium can also connect through this API.
  - name: Pinterest
    description: >
      Every pin is published to a board. List or create boards here, then set
      the board ID on the Pinterest post.
  - name: YouTube
    description: >
      Video categories and playlists of a connected YouTube channel, for YouTube
      posts.
  - name: Canva
    description: >
      Canva connects like a social account (browser sign-in in the app) but
      doesn't publish. List the connected user's designs and export them as
      files for your posts.
  - name: Post groups
    description: >
      One piece of content and its schedule, with one post per network. The
      group decides when; each post decides what.
  - name: Posts
    description: >
      What goes out on one network (text, media, settings) and its publishing
      status.
  - name: Scheduling
    description: |
      Posting-time suggestions from the company's own results.
  - name: Queues
    description: >
      Weekly time slots that publish waiting post groups (Auto-Listing in the
      app). In paths, a queue is a `ruleGroup` and a slot is a `rule`.
  - name: Tags
    description: >
      Labels for post groups. They also decide which queue takes a waiting
      group.
  - name: Assets
    description: >
      An asset is one item in a company's media library: a picture, a video or a
      text. Its picture or video is an attached file (see **Files**). Posts list
      asset IDs in `assets_ids`.
  - name: Folders
    description: >
      Folders organize a company's media library and can be nested. Each asset
      is in one folder at most, or at the top level.
  - name: Files
    description: >
      Upload a picture, video or audio file to an asset, post cover, company
      logo, profile picture, avatar or voice sample. Leave `url` out and `PUT`
      the bytes to the returned `presigned_url` within 10 minutes, or send a
      public `url` for the server to download. No multipart. Full details: `POST
      /assets/{id}/image`.
  - name: Avatars
    description: >
      An avatar is a person shown in your company's videos: a name, a picture, a
      voice and optional scene pictures (the same person in other settings). One
      avatar per company can be the default.
  - name: Voices
    description: >
      A voice is what your company's videos and audio speak with. It points to a
      stock library voice through `platform_external_id` and can hold a sample
      recording. Saving one spends no credits.
  - name: AI generation
    description: >
      Generate text, images, videos and speech. Every generation is an AI
      result. Long ones answer at once with a `pending` result that you poll.
  - name: AI copywriting
    description: >
      Post copy, titles and thread splits for a social network, in the company's
      brand voice.
  - name: AI result groups
    description: >
      Related AI results: a chat conversation, a Creative Studio design or a
      video project.
  - name: Prompts
    description: |
      Saved prompt templates for text or image generation, per social network.
  - name: Video
    description: >
      Video engines and their prices, and video projects: avatar videos and
      short videos the server makes scene by scene, with captions, transitions
      and music.
  - name: Creative Studio
    description: >
      Social media graphics (single creatives, quote cards, carousels and more),
      planned slide by slide from a style preset and drawn as images.
  - name: Music
    description: >
      The catalog and two writing helpers (lyrics, style suggestions). Making
      music needs a plan that includes Music.
  - name: Music styles
    description: |
      A company's saved sounds, reused so its tracks sound like one artist.
  - name: Music tracks
    description: |
      AI songs and instrumentals: generate, poll, master, download.
  - name: Music releases
    description: >
      Singles, EPs and albums with store metadata, a cover, readiness checks and
      a ZIP kit you upload to a distributor yourself.
  - name: Conversations
    description: >
      Direct-message threads between your connected Facebook pages or Instagram
      accounts and people. Only the person can start one.
  - name: Messages
    description: |
      The messages in a conversation: read, reply or remove them.
  - name: Comments
    description: >-
      Comments on your Facebook and Instagram posts, and your team's public
      replies.
  - name: Contacts
    description: >
      People who messaged one of your accounts or commented on its posts, per
      company and network.
  - name: Internal notes
    description: >
      Notes your team and clients leave on a post group, post or library asset,
      for example to approve it. Never published.
  - name: Research
    description: |
      Current news to write about, from Followr's news provider.
  - name: Plan and usage
    description: |
      Plan allowances, usage, and the caps owners set for companies and members.
  - name: Billing
    description: |
      The key's user's invoices, past and upcoming.
  - name: Webhooks
    description: >
      Requests Followr sends to your server when a post is published or fails.
      See the webhooks guide for setup and verification.
paths:
  /companies/{company_id}/socialNetworks:
    post:
      tags:
        - Social accounts
      summary: Connect a social account
      description: >
        Connects a Bluesky or Medium account with your credentials. Other
        networks connect only by browser sign-in in the Followr app.


        - **Bluesky:** the `handle` (or email address), and an app password as
        `social_token` (Bluesky **Settings > Privacy and security > App
        passwords**). Accounts hosted by Bluesky are supported.

        - **Medium:** an integration token as `social_token`.


        Followr checks the credentials with the network, then copies the profile
        name, handle and picture. Credentials are never returned.


        One account per network per company: if the network is already
        connected, you get `400`. A disconnected account comes back with its old
        `id`, and `200` instead of `201`.


        Roles: owner, admin and user.
      operationId: createSocialAccount
      parameters:
        - $ref: '#/components/parameters/CompanyId'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              required:
                - type
                - social_token
              properties:
                type:
                  type: string
                  enum:
                    - bluesky
                    - medium
                  description: The network to connect.
                  example: bluesky
                social_token:
                  type: string
                  description: 'Bluesky: an app password. Medium: an integration token.'
                  example: YOUR_APP_PASSWORD
                handle:
                  type:
                    - string
                    - 'null'
                  description: >-
                    Required for Bluesky, ignored for Medium. The account's
                    handle or email address.
                  example: northsidecoffee.bsky.social
            examples:
              bluesky:
                summary: Connect Bluesky
                value:
                  type: bluesky
                  handle: northsidecoffee.bsky.social
                  social_token: YOUR_APP_PASSWORD
              medium:
                summary: Connect Medium
                value:
                  type: medium
                  social_token: YOUR_MEDIUM_INTEGRATION_TOKEN
      responses:
        '200':
          description: A disconnected account of this network, connected again.
          content:
            application/json:
              schema:
                type: object
                required:
                  - data
                properties:
                  data:
                    $ref: '#/components/schemas/SocialNetwork'
              example:
                data:
                  id: 3308
                  type: bluesky
                  name: Northside Coffee
                  email: null
                  username: northsidecoffee.bsky.social
                  external_id: did:plc:4n7xq2kz6vb3rj5w8ytm1hcd
                  page_id: null
                  instagram_id: null
                  preferences: null
                  created_at: '2026-12-01T14:03:11.000000Z'
                  updated_at: '2026-12-15T09:30:00.000000Z'
                  integrated_at: '2026-12-15T09:30:00.000000Z'
                  expires_at: null
        '201':
          description: Created. The account is connected.
          content:
            application/json:
              schema:
                type: object
                required:
                  - data
                properties:
                  data:
                    $ref: '#/components/schemas/SocialNetwork'
              example:
                data:
                  id: 3308
                  type: bluesky
                  name: Northside Coffee
                  email: null
                  username: northsidecoffee.bsky.social
                  external_id: did:plc:4n7xq2kz6vb3rj5w8ytm1hcd
                  page_id: null
                  instagram_id: null
                  preferences: null
                  created_at: '2026-12-15T09:30:00.000000Z'
                  updated_at: '2026-12-15T09:30:00.000000Z'
                  integrated_at: '2026-12-15T09:30:00.000000Z'
                  expires_at: null
        '400':
          description: The network is already connected, or it refused the credentials.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
              examples:
                alreadyConnected:
                  summary: Already connected
                  value:
                    message: This company already has a social network of type bluesky
                badBlueskyCredentials:
                  summary: Bluesky refused the credentials
                  value:
                    message: >-
                      Invalid Bluesky handle or app password. Please check your
                      credentials and try again.
                badMediumToken:
                  summary: Medium refused the token
                  value:
                    message: The token provided does not match with a Medium's user
        '401':
          $ref: '#/components/responses/Unauthenticated'
        '403':
          $ref: '#/components/responses/Forbidden'
        '404':
          $ref: '#/components/responses/NotFound'
        '422':
          $ref: '#/components/responses/ValidationFailed'
        '429':
          $ref: '#/components/responses/TooManyRequests'
components:
  parameters:
    CompanyId:
      name: company_id
      in: path
      required: true
      description: The ID of the company (brand) the resource belongs to.
      schema:
        type: integer
        minimum: 1
      example: 1287
  schemas:
    SocialNetwork:
      type: object
      description: >
        A profile, Page or channel connected to one company. Tokens and
        passwords are never returned.
      required:
        - id
        - type
        - created_at
        - updated_at
      properties:
        id:
          type: integer
          description: The ID of the social account.
          example: 3301
        type:
          $ref: '#/components/schemas/SocialNetworkType'
        name:
          type:
            - string
            - 'null'
          description: >-
            The display name. Facebook and Instagram use the chosen Page's name,
            or the connecting person's name before a Page is chosen.
          example: Northside Coffee
        email:
          type:
            - string
            - 'null'
          description: The email the network shared on connection, if any.
          example: null
        username:
          type:
            - string
            - 'null'
          description: The handle on the network, if any (for example the Bluesky handle).
          example: northsidecoffee
        external_id:
          type:
            - string
            - 'null'
          description: >
            The profile's ID on the network: the channel ID (YouTube), the DID
            (Bluesky), or the connecting Facebook user's ID (Facebook,
            Instagram).
          example: '10229384756102938'
        page_id:
          type:
            - string
            - 'null'
          description: >
            Facebook and Instagram: the Facebook Page the account publishes as
            (for Instagram, the Page linked to the professional account). They
            can't publish while it's `null`. LinkedIn: the organization ID, or
            `null` to publish as the person who connected. `null` for other
            networks.
          example: '104857392018475'
        instagram_id:
          type:
            - string
            - 'null'
          description: >-
            Instagram only. The professional account's ID, set when its Facebook
            Page is chosen.
          example: '17841400123456789'
        preferences:
          type:
            - object
            - 'null'
          description: >
            Network settings, or `null`. Known keys:


            - X (`twitter`): `verified`, true with a paid X subscription (allows
            long posts).

            - TikTok: `privacy_level_options` (allowed privacy levels),
            `max_video_post_duration_sec`, `duet_disabled`, `stitch_disabled`,
            `comment_disabled`, read from TikTok on connection.

            - YouTube: `region_code`, the region for video categories.
          additionalProperties: true
          example: null
        photo_posts:
          type: boolean
          description: >-
            TikTok only. Whether image posts without video can publish (as photo
            posts). When `false`, TikTok posts need a video.
          example: true
        created_at:
          type: string
          format: date-time
          description: When the account was first connected to the company.
          example: '2026-12-01T14:03:11.000000Z'
        updated_at:
          type: string
          format: date-time
          description: When the account last changed.
          example: '2026-12-14T08:00:04.000000Z'
        integrated_at:
          type:
            - string
            - 'null'
          format: date-time
          description: >-
            When the account was last connected or reconnected. Can be `null`
            for Medium.
          example: '2026-12-01T14:03:11.000000Z'
        expires_at:
          type:
            - string
            - 'null'
          format: date-time
          description: >
            When the connection should need renewing. A past date means it
            expired (refused or lapsed), and its posts don't publish until it's
            reconnected in the app. `null` for Bluesky and Medium, which don't
            expire on their own; a later refusal gives them a past date.
          example: '2027-02-12T08:00:04.000000Z'
        image:
          $ref: '#/components/schemas/File'
          description: >-
            The profile picture. Only with `include=image` or
            `include=image.thumbnail`.
    Error:
      type: object
      description: The body of every error response except validation errors.
      required:
        - message
      properties:
        message:
          type: string
          description: A human-readable explanation. Don't parse it; it may change.
          example: This action is unauthorized.
    SocialNetworkType:
      type: string
      description: >
        A social network. Posts can go to every value except `canva` (a source
        of designs) and `discord` (not supported for publishing).
      enum:
        - facebook
        - instagram
        - threads
        - twitter
        - linkedin
        - tiktok
        - youtube
        - pinterest
        - bluesky
        - discord
        - medium
        - canva
      example: instagram
    File:
      type: object
      description: >
        A stored file: an image, a video, an audio track or a document. Files
        belong to other resources (a user's avatar, an asset's image, a post's
        cover) and are returned with `include`.
      properties:
        id:
          type: integer
          example: 908112
        original_name:
          type:
            - string
            - 'null'
          description: The file name it was uploaded with.
          example: launch-banner.png
        purpose:
          type: string
          description: The role of the file on the resource that owns it.
          enum:
            - image
            - cover
            - favicon
            - images
            - scenes
            - thumbnail
            - videos
            - video
            - audio
            - audios
            - binary
            - binaries
            - source
            - master
            - package
          example: image
        visibility:
          type: string
          description: >-
            `public` files are served from the CDN at a stable URL. `private`
            files use a signed URL that expires after 12 hours. Use `public` for
            anything you publish.
          enum:
            - private
            - public
          example: public
        driver:
          type: string
          description: The storage backend. Informational only.
          enum:
            - s3
            - azure
            - r2
          example: r2
        status:
          type:
            - string
            - 'null'
          description: >
            Processing state: `pending`, then `analyzing`, then `analyzed` or
            `error`. After the bytes arrive, Followr records type, size and
            dimensions (and length, for video) and makes a thumbnail for images
            and videos. If the bytes never arrive, it stays `pending`.
          enum:
            - pending
            - analyzing
            - analyzed
            - error
            - null
          example: analyzed
        mime_type:
          type:
            - string
            - 'null'
          description: The file's media type. `null` until the file is analyzed.
          example: image/png
        extension:
          type: string
          description: The extension of the stored file name.
          example: png
        size:
          type:
            - integer
            - 'null'
          description: Size in bytes. `0` until the file is analyzed.
          example: 482113
        width:
          type:
            - integer
            - 'null'
          description: >-
            Width in pixels, for images and videos. `0` until the file is
            analyzed.
          example: 1080
        height:
          type:
            - integer
            - 'null'
          description: >-
            Height in pixels, for images and videos. `0` until the file is
            analyzed.
          example: 1350
        duration:
          type:
            - integer
            - 'null'
          description: Length in whole seconds, for video. `0` until the file is analyzed.
          example: 0
        caption_result:
          type:
            - string
            - 'null'
          description: Not filled for new uploads. Kept for older files.
          example: null
        read_result:
          type:
            - string
            - 'null'
          description: Not filled for new uploads. Kept for older files.
          example: null
        url:
          type: string
          format: uri
          description: >-
            Where to download the file. For `private` files, a signed URL that
            expires after 12 hours.
          example: >-
            https://cdn.followr.ai/files/assets/66120/images/3f9b2c1e-8d4a-4f6b-9c2e-7a1d5e8f0b3c.png
        presigned_url:
          type: string
          format: uri
          description: >
            Only in the response that starts an upload without a source `url`.
            `PUT` the bytes here, with the file's `Content-Type`, within 10
            minutes. No confirm call is needed.
          example: >-
            https://storage.example.com/files/assets/66120/images/3f9b2c1e-8d4a-4f6b-9c2e-7a1d5e8f0b3c.png?X-Amz-Expires=600&X-Amz-Signature=EXAMPLE_SIGNATURE
        created_at:
          type: string
          format: date-time
          example: '2026-12-01T14:03:11.000000Z'
        updated_at:
          type: string
          format: date-time
          example: '2026-12-01T14:03:15.000000Z'
        thumbnail:
          $ref: '#/components/schemas/FileSummary'
          description: >-
            A JPEG preview, at most 350 pixels wide, for images and videos. With
            `include`, for example `include=image.thumbnail`.
    ValidationError:
      type: object
      description: Returned with `422 Unprocessable Content` when the request isn't valid.
      required:
        - message
        - errors
      properties:
        message:
          type: string
          description: The first error, followed by a count of the others.
          example: The name field is required. (and 1 more error)
        errors:
          type: object
          description: >-
            Every invalid field, keyed by its path in the request
            (`rows.0.content` for nested fields), with one or more messages.
          additionalProperties:
            type: array
            items:
              type: string
          example:
            name:
              - The name field is required.
            publish_at:
              - The publish at field must be a valid date.
    FileSummary:
      type: object
      description: >-
        A stored file: an image, a video, an audio track or a document. Files
        belong to other resources (a user's avatar, an asset's image, a post's
        cover) and are returned with `include`.


        Related resources inside it are shown in brief.
      properties:
        id:
          type: integer
          example: 908112
        original_name:
          type:
            - string
            - 'null'
          description: The file name it was uploaded with.
          example: launch-banner.png
        purpose:
          type: string
          description: The role of the file on the resource that owns it.
          enum:
            - image
            - cover
            - favicon
            - images
            - scenes
            - thumbnail
            - videos
            - video
            - audio
            - audios
            - binary
            - binaries
            - source
            - master
            - package
          example: image
        visibility:
          type: string
          description: >-
            `public` files are served from the CDN at a stable URL. `private`
            files use a signed URL that expires after 12 hours. Use `public` for
            anything you publish.
          enum:
            - private
            - public
          example: public
        driver:
          type: string
          description: The storage backend. Informational only.
          enum:
            - s3
            - azure
            - r2
          example: r2
        status:
          type:
            - string
            - 'null'
          description: >
            Processing state: `pending`, then `analyzing`, then `analyzed` or
            `error`. After the bytes arrive, Followr records type, size and
            dimensions (and length, for video) and makes a thumbnail for images
            and videos. If the bytes never arrive, it stays `pending`.
          enum:
            - pending
            - analyzing
            - analyzed
            - error
            - null
          example: analyzed
        mime_type:
          type:
            - string
            - 'null'
          description: The file's media type. `null` until the file is analyzed.
          example: image/png
        extension:
          type: string
          description: The extension of the stored file name.
          example: png
        size:
          type:
            - integer
            - 'null'
          description: Size in bytes. `0` until the file is analyzed.
          example: 482113
        width:
          type:
            - integer
            - 'null'
          description: >-
            Width in pixels, for images and videos. `0` until the file is
            analyzed.
          example: 1080
        height:
          type:
            - integer
            - 'null'
          description: >-
            Height in pixels, for images and videos. `0` until the file is
            analyzed.
          example: 1350
        duration:
          type:
            - integer
            - 'null'
          description: Length in whole seconds, for video. `0` until the file is analyzed.
          example: 0
        caption_result:
          type:
            - string
            - 'null'
          description: Not filled for new uploads. Kept for older files.
          example: null
        read_result:
          type:
            - string
            - 'null'
          description: Not filled for new uploads. Kept for older files.
          example: null
        url:
          type: string
          format: uri
          description: >-
            Where to download the file. For `private` files, a signed URL that
            expires after 12 hours.
          example: >-
            https://cdn.followr.ai/files/assets/66120/images/3f9b2c1e-8d4a-4f6b-9c2e-7a1d5e8f0b3c.png
        presigned_url:
          type: string
          format: uri
          description: >
            Only in the response that starts an upload without a source `url`.
            `PUT` the bytes here, with the file's `Content-Type`, within 10
            minutes. No confirm call is needed.
          example: >-
            https://storage.example.com/files/assets/66120/images/3f9b2c1e-8d4a-4f6b-9c2e-7a1d5e8f0b3c.png?X-Amz-Expires=600&X-Amz-Signature=EXAMPLE_SIGNATURE
        created_at:
          type: string
          format: date-time
          example: '2026-12-01T14:03:11.000000Z'
        updated_at:
          type: string
          format: date-time
          example: '2026-12-01T14:03:15.000000Z'
        thumbnail:
          description: >-
            A JPEG preview, at most 350 pixels wide, for images and videos. With
            `include`, for example `include=image.thumbnail`.
          type: object
          title: File
  responses:
    Unauthenticated:
      description: The API key is missing, malformed, expired or revoked.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          examples:
            missing:
              summary: No valid key
              value:
                message: Unauthenticated.
            revoked:
              summary: Revoked key
              value:
                message: Token revoked
    Forbidden:
      description: >-
        The key is valid, but its user may not do this (their role doesn't allow
        it, or the account is suspended).
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          example:
            message: This action is unauthorized.
    NotFound:
      description: No resource with this ID, or it was deleted.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          example:
            message: No query results for model [App\Models\PostGroup] 99999999
    ValidationFailed:
      description: One or more fields are invalid.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ValidationError'
    TooManyRequests:
      description: Too many requests in the last minute. Wait `Retry-After` seconds.
      headers:
        Retry-After:
          $ref: '#/components/headers/Retry-After'
        X-RateLimit-Limit:
          $ref: '#/components/headers/X-RateLimit-Limit'
        X-RateLimit-Remaining:
          $ref: '#/components/headers/X-RateLimit-Remaining'
        X-RateLimit-Reset:
          $ref: '#/components/headers/X-RateLimit-Reset'
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          example:
            message: Too Many Attempts.
  headers:
    Retry-After:
      description: Seconds to wait before retrying.
      schema:
        type: integer
        example: 42
    X-RateLimit-Limit:
      description: Requests allowed per minute for the key's user.
      schema:
        type: integer
        example: 200
    X-RateLimit-Remaining:
      description: Requests left in the current one-minute window.
      schema:
        type: integer
        example: 0
    X-RateLimit-Reset:
      description: Unix timestamp (seconds) when the current window resets.
      schema:
        type: integer
        example: 1764672060
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: API key
      description: >
        Send your API key in the `Authorization` header:


        ```

        Authorization: Bearer YOUR_API_KEY

        ```


        Create keys in the Followr app under **Settings > API keys**. A key acts
        as its user, with that user's role in each company.

````

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