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

# Post apiv1campaignsmatch channels



## OpenAPI

````yaml https://backend.aflux.ai/openapi post /api/v1/campaigns/match-channels
openapi: 3.0.3
info:
  title: AdFlux Backend API
  version: v1
servers:
  - url: /
security: []
tags:
  - name: auth
  - name: users
  - name: uploads
  - name: projects
  - name: campaigns
  - name: placements
  - name: billing
  - name: payments
  - name: image-generations
paths:
  /api/v1/campaigns/match-channels:
    post:
      tags:
        - campaigns
      operationId: campaignsMatchChannels
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CampaignMatchChannelsRequest'
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CampaignChannelCandidateListResponse'
        default:
          $ref: '#/components/responses/DefaultError'
      security:
        - Bearer: []
components:
  schemas:
    CampaignMatchChannelsRequest:
      type: object
      required:
        - projectId
        - adCopy
        - platform
      properties:
        projectId:
          type: string
          format: uuid
        adCopy:
          type: string
          maxLength: 8000
          description: >-
            The ad text, markup and all, used here only as the brief a channel
            search is derived from. Deliberately NOT judged as publishable copy:
            this request carries no destinationUrl, so the rule about foreign
            domains cannot be evaluated, and half a verdict would teach the
            advertiser the wrong lesson about what is checked. Campaign create
            is where the text is judged.
        platform:
          $ref: '#/components/schemas/CampaignPlatform'
        objective:
          $ref: '#/components/schemas/CampaignObjective'
          nullable: true
    CampaignChannelCandidateListResponse:
      type: object
      required:
        - matchToken
        - channels
      properties:
        matchToken:
          type: string
        channels:
          type: array
          items:
            $ref: '#/components/schemas/CampaignChannelCandidate'
        filters:
          $ref: '#/components/schemas/CampaignFilters'
          nullable: true
          description: >-
            Present only for match-channels-by-prompt, which is the only search
            that INFERS its filters instead of being told them: it reports back
            what it read out of the prompt. The ad-copy and look-alike searches
            take no filters from the caller, so they leave this absent.
    CampaignPlatform:
      type: string
      enum:
        - TELEGRAM
    CampaignObjective:
      type: string
      enum:
        - AWARENESS
        - TRAFFIC
        - CONVERSIONS
        - APP_INSTALLS
    CampaignChannelCandidate:
      type: object
      required:
        - channelId
        - platform
        - relevancy
        - score
        - avgReach
        - fraudScore
      properties:
        channelId:
          type: integer
          format: int64
        platform:
          $ref: '#/components/schemas/CampaignPlatform'
        channelUsername:
          type: string
          nullable: true
        channelTitle:
          type: string
          nullable: true
        subscribers:
          type: integer
          format: int32
          nullable: true
        relevancy:
          type: number
          format: double
        score:
          type: number
          format: double
        avgReach:
          type: integer
          format: int64
        fraudScore:
          type: number
          format: double
        managerUsername:
          type: string
          nullable: true
    CampaignFilters:
      type: object
      description: >-
        The channel filters a search actually applied. Reported back by
        match-channels-by-prompt so the advertiser can see how his own words
        were read — "20K+ subscribers" comes back as minSubscribers=20000 — and
        correct them if they were read wrong. Every field is optional on
        purpose: only what the prompt actually stated is filled, and an absent
        field means no such filter narrowed the search. `ranking` and
        `minManagerContactConfidence` always come back, because the search
        always ranks somehow and always applies a contact requirement.
      properties:
        minSubscribers:
          type: integer
          format: int64
          nullable: true
        maxSubscribers:
          type: integer
          format: int64
          nullable: true
        maxFraudScore:
          type: number
          format: double
          nullable: true
        minAvgReach:
          type: integer
          format: int64
          nullable: true
        language:
          type: string
          nullable: true
          description: >-
            ISO 639-1 code of the audience language the search filtered on
            ("English-speaking traders" comes back as "en"). Absent when the
            language was not pinned by us and the search instead filtered on the
            language of the query text itself.
        ranking:
          type: string
          enum:
            - balanced
            - max_reach
            - max_engagement
          nullable: true
        minManagerContactConfidence:
          type: string
          enum:
            - any
            - low
            - medium
            - high
          nullable: true
    ErrorResponse:
      type: object
      required:
        - error
      properties:
        error:
          type: string
  responses:
    DefaultError:
      description: Error
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
  securitySchemes:
    Bearer:
      type: http
      scheme: bearer
      bearerFormat: JWT

````