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

# Recipients Count by channel

> # Description

Get the recipients count by channel of a campaign. `campaignId` url param is the campaign id used to count the recipients.

# Response
```json
{
    "emailRecipientsCount": 5,
    "smsRecipientsCount": 4
}
```

where:

- `emailRecipientsCount`: Total of recipients with emails filtered by the type passed in query param `type`.  
- `smsRecipientsCount`: Total of recipients with sms filtered by the type passed in query param `type`.

# Description

Get the recipients count by channel of a campaign. `campaignId` url param is the campaign id used to count the recipients.

# Response

```json theme={null}
{
    "emailRecipientsCount": 5,
    "smsRecipientsCount": 4
}
```

where:

* `emailRecipientsCount`: Total of recipients with emails filtered by the type passed in query param `type`.
* `smsRecipientsCount`: Total of recipients with sms filtered by the type passed in query param `type`.

##### Query Parameters

| Parameter | Description | Required | Example |
| --------- | ----------- | -------- | ------- |
| `type`    | —           | No       | —       |


## OpenAPI

````yaml GET /campaigns-service/v1/campaigns/{campaignId}/recipients/channels/count
openapi: 3.0.3
info:
  title: SightX API
  version: 1.0.0
  description: >-
    SightX REST API documentation. Most responses are JSON; some export
    endpoints return files. API access is a paid add-on — contact
    sales@sightx.io for details.
servers:
  - url: https://auth.admin.sightx.io
    description: Authentication (Production)
  - url: https://auth.staging-admin.sightx.io
    description: Authentication (Staging)
security:
  - AuthorizationHeader: []
paths:
  /campaigns-service/v1/campaigns/{campaignId}/recipients/channels/count:
    get:
      summary: Recipients Count by channel
      description: >-
        # Description


        Get the recipients count by channel of a campaign. `campaignId` url
        param is the campaign id used to count the recipients.


        # Response

        ```json

        {
            "emailRecipientsCount": 5,
            "smsRecipientsCount": 4
        }

        ```


        where:


        - `emailRecipientsCount`: Total of recipients with emails filtered by
        the type passed in query param `type`.  

        - `smsRecipientsCount`: Total of recipients with sms filtered by the
        type passed in query param `type`.
      operationId: >-
        recipients-count-by-channel-get-campaigns-service-v1-campaigns-campaignid-recipients-channels-count
      parameters:
        - name: Authorization
          in: header
          required: true
          schema:
            type: string
        - name: type
          in: query
          required: false
          schema:
            type: string
      responses:
        '200':
          description: Successful response
        '400':
          description: Bad request
        '401':
          description: Unauthorized
        '500':
          description: Internal server error
      servers:
        - url: https://campaigns.sightx.io
components:
  securitySchemes:
    AuthorizationHeader:
      type: apiKey
      in: header
      name: Authorization
      description: Access token obtained from the m2m-token endpoint.

````