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

# Get Audience Counts

> Get the latest follower or subscriber count for every connected account in one Mallary profile.

Mallary updates supported audience counts once every 24 hours.

Use `profile_id` for a non-default profile. Omit it to use the default profile.

The response includes every connected account. `count` is the latest saved number when Mallary can collect it.

* YouTube returns `subscribers`.
* Facebook Pages, Instagram, Threads, X, and Pinterest return `followers`. Facebook may return `page_likes` when that is the only count the Page gives Mallary.
* TikTok and LinkedIn return `permission_required` until Mallary adds the needed permissions.
* Other platforms may return `unsupported` when they do not provide an account audience count.

Mallary does not add the counts together. The same person may follow more than one account.


## OpenAPI

````yaml GET /api/v1/audience
openapi: 3.0.3
info:
  title: Mallary API
  version: 1.4.0
  description: >
    Public API for multi-platform publishing, analytics, media upload, and
    webhooks.


    Authentication:

    - Use header `Authorization: Bearer {api_key}`.

    - API key identity is authoritative. Do not use `user_id` to identify a
    caller.


    Connection profiles:

    - Omit `profile_id` to use the authenticated user's default profile.

    - Send the profile's random public `profile_id` when you want to publish,
    list posts, read post analytics or audience counts, list platforms, update
    settings, or disconnect a platform for a non-default profile.

    - Use `GET /api/v1/profiles` to list profile IDs.

    - Per-platform account caps by plan: Free 1, Starter 4, Pro 10, Business 50.


    Rate limits (per user, per minute) depend on subscription plan:

    - plan_id 1: 75 req/min

    - plan_id 2: 150 req/min

    - plan_id 3: 750 req/min

    - plan_id 4: 1500 req/min
servers:
  - url: https://mallary.ai
    description: Production
security:
  - bearerAuth: []
externalDocs:
  description: Full product docs
  url: https://docs.mallary.ai/
paths:
  /api/v1/audience:
    get:
      summary: Get current audience counts
      description: >-
        Returns the latest follower or subscriber count for every connected
        account in one Mallary profile. Mallary refreshes supported counts once
        every 24 hours.
      operationId: listAudience
      parameters:
        - in: query
          name: profile_id
          required: false
          schema:
            $ref: '#/components/schemas/ProfileId'
          description: Connection profile to inspect. Omit to use the default profile.
      responses:
        '200':
          description: Audience counts retrieved
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AudienceResponse'
        '401':
          description: Missing or invalid API key
        '403':
          description: >-
            Audience analytics are not available for the current plan, or
            supplied `user_id` does not match the API key owner
        '429':
          description: Rate limit exceeded
components:
  schemas:
    ProfileId:
      type: string
      pattern: ^[A-Za-z0-9]{6,32}$
      example: AbC123xYz90
      description: Random public connection profile ID returned by `GET /api/v1/profiles`.
    AudienceResponse:
      type: object
      required:
        - status
        - data
      properties:
        status:
          type: string
          enum:
            - ok
        data:
          type: object
          required:
            - profile_id
            - generated_at
            - audience
          properties:
            profile_id:
              type: string
              pattern: ^[A-Za-z0-9]{6,32}$
              nullable: true
            generated_at:
              type: string
              format: date-time
            audience:
              type: array
              items:
                $ref: '#/components/schemas/AudienceItem'
    AudienceItem:
      type: object
      required:
        - platform
        - label
        - account
        - metric
        - count
        - status
      properties:
        platform:
          $ref: '#/components/schemas/PublicPlatform'
        label:
          type: string
        account:
          $ref: '#/components/schemas/AudienceAccount'
        metric:
          $ref: '#/components/schemas/AudienceMetric'
        count:
          type: integer
          format: int64
          minimum: 0
          nullable: true
        status:
          $ref: '#/components/schemas/AudienceStatus'
        status_message:
          type: string
          nullable: true
        captured_at:
          type: string
          format: date-time
          nullable: true
        last_attempt_at:
          type: string
          format: date-time
          nullable: true
        next_update_at:
          type: string
          format: date-time
          nullable: true
    PublicPlatform:
      type: string
      description: >-
        Canonical public platform identifier used in connected-platform
        listings.
      enum:
        - x
        - facebook
        - instagram
        - linkedin
        - youtube
        - tiktok
        - pinterest
        - reddit
        - threads
        - snapchat
    AudienceAccount:
      type: object
      properties:
        id:
          type: string
          nullable: true
        username:
          type: string
          nullable: true
        avatar_url:
          type: string
          format: uri
          nullable: true
    AudienceMetric:
      type: string
      enum:
        - followers
        - subscribers
        - page_likes
    AudienceStatus:
      type: string
      enum:
        - available
        - collecting
        - permission_required
        - reconnect_required
        - unsupported
        - error
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: 'Use `Authorization: Bearer {api_key}`'

````