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

# Get appointment reminder counts

> Counts the reminders matching the same filters as the list, except `status`: `sent`, `queued`, `error` and
`expired` by send status, and `pending_approval` for the queued reminders still awaiting approval. A reminder
the send job has not yet closed, though its appointment or session is over, still counts as queued and awaiting
approval until the job's next run (every five minutes).



## OpenAPI

````yaml /api-referansi/openapi.json get /v1/appointment-reminders/stats
openapi: 3.1.0
info:
  title: Flextell API
  version: 0.0.1
  description: >-
    Flextell REST API referansı. Kimlik doğrulama, scope ve istek kuralları için
    API sekmesindeki rehberlere bakın.
servers:
  - url: https://app.flextell.ai/api
    description: Üretim
security:
  - oauth2: []
  - bearer: []
paths:
  /v1/appointment-reminders/stats:
    get:
      tags:
        - AppointmentReminder
      summary: Get appointment reminder counts
      description: >-
        Counts the reminders matching the same filters as the list, except
        `status`: `sent`, `queued`, `error` and

        `expired` by send status, and `pending_approval` for the queued
        reminders still awaiting approval. A reminder

        the send job has not yet closed, though its appointment or session is
        over, still counts as queued and awaiting

        approval until the job's next run (every five minutes).
      operationId: appointmentReminder.stats
      parameters:
        - name: search
          in: query
          description: The search query.
          schema:
            type:
              - string
              - 'null'
            maxLength: 255
        - name: type[]
          in: query
          description: A reminder type to include.
          schema:
            type: array
            enum:
              - appointment
              - cancellation_follow_up
              - session_confirmation
              - reschedule_confirmation
            items:
              type: string
              enum:
                - appointment
                - cancellation_follow_up
                - session_confirmation
                - reschedule_confirmation
        - name: approval_status[]
          in: query
          description: An approval status to include.
          schema:
            type: array
            enum:
              - pending
              - approved
              - rejected
              - cancelled
            items:
              type: string
              enum:
                - pending
                - approved
                - rejected
                - cancelled
        - name: channel[]
          in: query
          description: A channel to include.
          schema:
            type: array
            items:
              type: string
              maxLength: 255
        - name: appointment_date_from
          in: query
          description: >-
            Filter reminders whose appointment is scheduled from this date
            (tenant timezone).
          schema:
            type:
              - string
              - 'null'
            format: date-time
        - name: appointment_date_to
          in: query
          description: >-
            Filter reminders whose appointment is scheduled up to this date
            (tenant timezone); a date-only value includes the whole day.
          schema:
            type:
              - string
              - 'null'
            format: date-time
        - name: scheduled_for_from
          in: query
          description: >-
            Filter reminders planned to be sent from this date (tenant
            timezone).
          schema:
            type:
              - string
              - 'null'
            format: date-time
        - name: scheduled_for_to
          in: query
          description: >-
            Filter reminders planned to be sent up to this date (tenant
            timezone); a date-only value includes the whole day.
          schema:
            type:
              - string
              - 'null'
            format: date-time
        - name: X-Tenant
          in: header
          required: true
          description: >-
            Tenant identifier. Send the Tenant ID in the `X-Tenant` header to
            scope API requests to a specific tenant.
          schema:
            type: number
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    type: string
                  data:
                    type: object
                    properties:
                      queued:
                        type: integer
                      sent:
                        type: integer
                      error:
                        type: integer
                      expired:
                        type: integer
                      pending_approval:
                        type: integer
                    required:
                      - queued
                      - sent
                      - error
                      - expired
                      - pending_approval
                required:
                  - success
                  - data
        '401':
          $ref: '#/components/responses/AuthenticationException'
        '403':
          $ref: '#/components/responses/AuthorizationException'
        '422':
          $ref: '#/components/responses/ValidationException'
        '428':
          description: >-
            Mandatory setup is incomplete. Finish the setup wizard first;
            `data.next_step` names the step to continue with.
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    type: boolean
                    examples:
                      - false
                  error_code:
                    type: string
                    enum:
                      - SETUP_REQUIRED
                    examples:
                      - SETUP_REQUIRED
                  message:
                    type: string
                    examples:
                      - Complete the required setup steps to continue.
                  data:
                    type: object
                    properties:
                      next_step:
                        type:
                          - string
                          - 'null'
                        examples:
                          - clinic_info
                    required:
                      - next_step
                required:
                  - success
                  - error_code
                  - message
                  - data
components:
  responses:
    AuthenticationException:
      description: Unauthenticated
      content:
        application/json:
          schema:
            type: object
            properties:
              message:
                type: string
                description: Error overview.
            required:
              - message
    AuthorizationException:
      description: Authorization error
      content:
        application/json:
          schema:
            type: object
            properties:
              message:
                type: string
                description: Error overview.
            required:
              - message
    ValidationException:
      description: Validation error
      content:
        application/json:
          schema:
            type: object
            properties:
              message:
                type: string
                description: Errors overview.
              errors:
                type: object
                description: A detailed description of each field that failed validation.
                additionalProperties:
                  type: array
                  items:
                    type: string
            required:
              - message
              - errors
  securitySchemes:
    oauth2:
      type: oauth2
      flows:
        authorizationCode:
          authorizationUrl: https://app.flextell.ai/oauth/authorize
          tokenUrl: https://app.flextell.ai/oauth/token
          scopes:
            '*': all
    bearer:
      type: http
      scheme: bearer

````

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