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

# Create Audience

> Creates a custom audience from an uploaded CSV file and starts processing it.



## OpenAPI

````yaml /openapi/api-v1-native.yml post /audiences
openapi: 3.1.0
info:
  title: Whop API
  description: >-
    Hand-written V1 endpoints. Merged into the GraphqlRestProxy-generated schema
    at build time.
  version: v1
servers:
  - url: https://{defaultHost}
    variables:
      defaultHost:
        default: api.whop.com/api/v1
security: []
paths:
  /audiences:
    post:
      tags:
        - Audiences
      summary: Create Audience
      description: >-
        Creates a custom audience from an uploaded CSV file and starts
        processing it.
      operationId: createAudience
      parameters: []
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                account_id:
                  type: string
                  description: The ID of the account that will own the audience.
                name:
                  type: string
                  description: A display name for the audience.
                column_mapping:
                  type: object
                  additionalProperties:
                    type: string
                  description: >-
                    Map of identity field (email, phone, first_name, last_name,
                    country) to the CSV column header that holds it. Map at
                    least an email or phone column.
                file_id:
                  type: string
                  description: >-
                    A direct upload ID returned by the standard media upload
                    endpoint.
              required:
                - account_id
                - name
                - column_mapping
                - file_id
        required: true
      responses:
        '201':
          description: audience created
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Audience'
        '401':
          $ref: '#/components/responses/Unauthorized'
          description: missing or invalid authentication
      security:
        - bearerAuth:
            - audience:update
components:
  schemas:
    Audience:
      type: object
      properties:
        id:
          type: string
          description: The ID of the audience, which will look like adaud_*************
        name:
          type: string
          description: The display name of the audience
        status:
          type: string
          description: >-
            Processing status: pending, processing, syncing, ready, partial, or
            failed
        total_rows:
          type: number
          description: Total data rows detected in the uploaded CSV
        processed_rows:
          type: number
          description: Rows ingested so far
        matched_rows:
          type: number
          description: Rows uploaded to the ad platform
        progress_percent:
          type: number
          description: Processing progress from 0 to 100
        error_message:
          type:
            - string
            - 'null'
          description: Populated when the audience is partial or failed
        platform_audience_ids:
          type: array
          description: External ad-platform audience IDs created for this audience
        created_at:
          type: number
          description: When the audience was created, as a Unix timestamp
        updated_at:
          type: number
          description: When the audience was last updated, as a Unix timestamp
      required:
        - id
        - name
        - status
        - total_rows
        - processed_rows
        - matched_rows
        - progress_percent
        - error_message
        - platform_audience_ids
        - created_at
        - updated_at
    V1ErrorResponse:
      type: object
      properties:
        error:
          type: object
          properties:
            type:
              type: string
              description: Machine-readable error code.
            message:
              type: string
              description: Human-readable error message.
          required:
            - type
            - message
      required:
        - error
  responses:
    Unauthorized:
      description: Unauthorized
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/V1ErrorResponse'
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: auth-scheme
      description: >-
        An account API key, account scoped JWT, app API key, or user OAuth
        token.

````