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

# List poll votes

> Returns one page of the votes of the poll, oldest first. Polls that hide their votes only list them with admin access. Pass `voter_id` or `option_id` to list the votes of one participant or one option. Use the X-Total-Pages / X-Total-Count response headers to page through the full list.



## OpenAPI

````yaml /api-reference/openapi.json get /api/v1/polls/{poll_id}/votes
openapi: 3.0.1
info:
  title: PollUnit API
  version: v1
  description: Programmatic access to PollUnit.
servers:
  - url: https://pollunit.com
    description: Production
  - url: http://localhost:3000
    description: Development
security:
  - bearerAuth: []
paths:
  /api/v1/polls/{poll_id}/votes:
    parameters:
      - name: poll_id
        in: path
        description: Poll member_hash or admin_hash
        required: true
        schema:
          type: string
      - name: organization_id
        in: query
        required: false
        description: >-
          public_id of an organization the user belongs to. When given, the
          request runs in that organization context instead of the personal
          account.
        schema:
          type: string
    get:
      tags:
        - Votes
      summary: List poll votes
      description: >-
        Returns one page of the votes of the poll, oldest first. Polls that hide
        their votes only list them with admin access. Pass `voter_id` or
        `option_id` to list the votes of one participant or one option. Use the
        X-Total-Pages / X-Total-Count response headers to page through the full
        list.
      parameters:
        - name: voter_id
          in: query
          required: false
          description: 'Voter public_id: only list the votes of this participant.'
          schema:
            type: string
        - name: option_id
          in: query
          required: false
          description: >-
            Option public_id: only list the votes for this option. Ignored when
            `voter_id` is given.
          schema:
            type: string
        - name: page
          in: query
          required: false
          description: Page to return, 1-based. Defaults to 1.
          schema:
            type: integer
        - name: per
          in: query
          required: false
          description: Votes per page. Defaults to 30. At most 100.
          schema:
            type: integer
      responses:
        '200':
          description: votes listed
          headers:
            X-Page:
              schema:
                type: integer
              description: Current page, 1-based
            X-Per-Page:
              schema:
                type: integer
              description: Votes per page
            X-Total-Pages:
              schema:
                type: integer
              description: Number of pages
            X-Total-Count:
              schema:
                type: integer
              description: Total number of votes matching the request
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/Vote'
        '401':
          description: unauthorized
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Unauthorized'
        '403':
          description: poll hides its votes
        '404':
          description: poll, participant or option not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/NotFound'
      security:
        - bearerAuth: []
components:
  schemas:
    Vote:
      type: object
      description: >-
        A vote of one participant for one option. Which value field is set
        depends on the poll's `vote_type`.
      properties:
        id:
          type: string
          description: Vote id
        type:
          type: string
          example: Votes::RatingVote
        created_at:
          type: string
          format: date-time
          nullable: true
        updated_at:
          type: string
          format: date-time
          nullable: true
        option_id:
          type: string
          nullable: true
          description: >-
            Option public_id. For pairwise comparisons the option that won the
            comparison.
        loser_option_id:
          type: string
          nullable: true
          description: >-
            Pairwise comparisons only: option public_id of the option that lost
            the comparison.
        voter_id:
          type: string
          nullable: true
          description: Voter public_id
        vote:
          anyOf:
            - type: number
              nullable: true
            - type: string
              nullable: true
          description: >-
            The value of the vote, whichever of `vote`, `vote_date`, `vote_text`
            or the decimal value is set.
        vote_date:
          type: string
          format: date
          nullable: true
          description: Day the vote was cast on, for polls with `vote_per_day`.
        vote_text:
          type: string
          nullable: true
          description: Value of text votes, e.g. table columns.
        paid:
          type: boolean
          nullable: true
          description: >-
            Admin access only, and only for polls with a voting wallet. `false`
            while bought votes are not paid yet.
        voting_category_id:
          type: integer
          nullable: true
          description: Only for polls with `voting_categories`.
      required:
        - id
        - type
    Unauthorized:
      type: object
      properties:
        error:
          type: string
          example: Unauthorized
    NotFound:
      type: object
      properties:
        error:
          type: string
          example: Not Found
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: opaque
      description: Personal API token — find yours under My Account → API.

````