> ## 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.

# Get poll



## OpenAPI

````yaml /api-reference/openapi.json get /api/v1/polls/{poll_hash}
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_hash}:
    parameters:
      - 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:
        - Polls
      summary: Get poll
      parameters:
        - name: poll_hash
          in: path
          description: Poll member_hash or admin_hash
          required: true
          schema:
            type: string
      responses:
        '200':
          description: poll found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Poll'
        '401':
          description: unauthorized
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Unauthorized'
        '404':
          description: poll not found
      security:
        - bearerAuth: []
components:
  schemas:
    Poll:
      type: object
      properties:
        admin_url:
          type: string
          format: uri
          nullable: true
          description: Admin URL (owner/admin access only)
        public_url:
          type: string
          format: uri
        member_hash:
          type: string
          description: Public poll identifier (use for read/submit)
        admin_hash:
          type: string
          nullable: true
          description: Admin identifier (only returned to owner)
        title:
          type: string
        description:
          type: string
          nullable: true
        location:
          type: string
          nullable: true
        type:
          type: string
          example: Polls::Voting
        status:
          type: string
          enum:
            - active
            - closed
        options_count:
          type: integer
        voters_count:
          type: integer
          nullable: true
        created_at:
          type: string
          format: date-time
          nullable: true
        updated_at:
          type: string
          format: date-time
          nullable: true
        url:
          type: string
          format: uri
        settings:
          $ref: '#/components/schemas/PollSettings'
        configuration_hints:
          type: object
          nullable: true
          description: Allowed values for selected configuration fields (owner/admin only)
        voter_required_fields:
          $ref: '#/components/schemas/RequiredFields'
        option_required_fields:
          $ref: '#/components/schemas/RequiredFields'
      required:
        - public_url
        - member_hash
        - title
        - type
        - status
    Unauthorized:
      type: object
      properties:
        error:
          type: string
          example: Unauthorized
    PollSettings:
      type: object
      properties:
        access_by_provider:
          type: string
          nullable: true
          enum:
            - facebook
            - google_oauth2
            - github
            - organization_sso
        additional_attributes:
          type: object
          nullable: true
        additional_option_attributes:
          type: object
          nullable: true
        advent_calendar_shape:
          type: string
          nullable: true
          enum:
            - number
            - star
            - snow
            - square
            - circle
            - list
        allow_attachments:
          type: boolean
          nullable: true
        allow_change_sort:
          type: boolean
          nullable: true
        allow_comments:
          type: boolean
          nullable: true
        allow_description:
          type: boolean
          nullable: true
        allow_group_submissions:
          type: boolean
          nullable: true
        allow_info_link:
          type: boolean
          nullable: true
        allow_new_options:
          type: boolean
          nullable: true
        allow_new_rows:
          type: boolean
          nullable: true
        allow_search:
          type: boolean
          nullable: true
        allow_share:
          type: boolean
          nullable: true
        allow_subtitle:
          type: boolean
          nullable: true
        allow_voting:
          type: boolean
          nullable: true
        allowed_hosts:
          type: array
          items:
            type: string
          nullable: true
        anonymize_voter_names:
          type: boolean
          nullable: true
        custom_hash:
          type: boolean
          nullable: true
        deadline_submission:
          type: string
          format: date-time
          nullable: true
        deadline_voting:
          type: string
          format: date-time
          nullable: true
        default_sort:
          type: string
          nullable: true
          enum:
            - options.average_rating desc
            - options.rating desc
            - options.content asc
            - options.created_at asc
            - options.created_at desc
            - options.author_name asc
            - options.updated_at desc
          description: Sort order of the options. `null` keeps the manual order.
        default_states:
          type: array
          nullable: true
          items:
            type: string
            enum:
              - incoming
              - investigation
              - planned
              - in_implementation
              - rejected
              - done
          description: 'Collection polls only: option states selected by default.'
        disable_participant_sign_up:
          type: boolean
          nullable: true
        dot_vote_icon:
          type: string
          nullable: true
          enum:
            - dot
            - heart
            - star
            - 'yes'
        effect:
          type: string
          nullable: true
          enum:
            - snow
            - fireflies
            - rain
            - flickering_stars
            - spiders
        file_size_max_mb:
          type: number
          format: float
          nullable: true
        file_size_min_mb:
          type: number
          format: float
          nullable: true
        forward_url_parameters:
          type: boolean
          nullable: true
        group_submission_max_entries:
          type: integer
          nullable: true
        hidden_author_name:
          type: boolean
          nullable: true
        hidden_best_rating:
          type: boolean
          nullable: true
        hidden_image_name:
          type: boolean
          nullable: true
        hidden_participants:
          type: boolean
          nullable: true
        hide_options:
          type: boolean
          nullable: true
        hide_results:
          type: boolean
          nullable: true
        hide_tags:
          type: boolean
          nullable: true
        hide_votes:
          type: boolean
          nullable: true
        image_min_height:
          type: integer
          nullable: true
        image_min_smallest_side_length:
          type: integer
          nullable: true
        image_min_width:
          type: integer
          nullable: true
        image_orientation:
          type: string
          nullable: true
          enum:
            - all
            - portrait
            - landscape
        indexing:
          type: boolean
          nullable: true
        jury_mode:
          type: boolean
          nullable: true
        limit_per_option:
          type: integer
          nullable: true
        limit_per_option_type:
          type: string
          nullable: true
          enum:
            - no_limit
            - global_limit
            - uniq_limit
        notify_new_options:
          type: boolean
          nullable: true
        option_limit:
          type: integer
          nullable: true
        option_type:
          type: string
          nullable: false
          enum:
            - Options::AdventCalendarOption
            - Options::AudioOption
            - Options::CategorizedOption
            - Options::CollectionOption
            - Options::ColumnOption
            - Options::DateOption
            - Options::DatePeriodOption
            - Options::DateTimeOption
            - Options::ImageOption
            - Options::LandingPageOption
            - Options::PhotoOption
            - Options::SurveyStep
            - Options::TextOption
            - Options::TimePeriodOption
            - Options::VideoFileOption
            - Options::VideoOption
            - TableCell
          description: >-
            Option class used by this poll. The values allowed for a given poll
            type are listed in `configuration_hints`.
        option_vote_requirement:
          type: string
          nullable: false
          enum:
            - optional
            - single_option
            - all_options
        options_per_page:
          type: integer
          nullable: true
        options_visible_before_voting:
          type: boolean
          nullable: true
        participant_limitation_type:
          type: string
          nullable: false
          enum:
            - check_nothing
            - check_cookie
            - check_ip
            - check_account
            - check_invitation
            - check_slack
            - check_anonymous_invitation
            - check_provider
            - check_double_opt_in
        photo_gallery_full_width:
          type: boolean
          nullable: true
        photo_gallery_image_mode:
          type: string
          nullable: true
          enum:
            - contain
            - cover
        photo_gallery_layout:
          type: string
          nullable: true
          enum:
            - auto
            - square
            - portrait
            - landscape
            - single_column
        prevent_vote_for_own_options:
          type: boolean
          nullable: true
        privacy_policy:
          type: string
          nullable: true
        privacy_policy_for_option_creators:
          type: boolean
          nullable: true
        privacy_policy_for_voters:
          type: boolean
          nullable: true
        private_comments:
          type: boolean
          nullable: true
        public_admin_link:
          type: boolean
          nullable: true
        publisher:
          type: string
          nullable: true
        publisher_email:
          type: string
          nullable: true
        publisher_info:
          type: string
          nullable: true
        randomize_options:
          type: boolean
          nullable: true
        rating_method:
          type: string
          nullable: true
          enum:
            - average_by_voted
            - average_by_all_voters
        require_all_dots:
          type: boolean
          nullable: false
          default: false
          description: >-
            Dot voting only: all available points must be assigned before a
            participant's votes count toward the results. Cannot be changed
            after participation has started. Reset to false for other vote
            types.
        require_approval:
          type: boolean
          nullable: true
        require_author_name:
          type: boolean
          nullable: true
        require_description:
          type: boolean
          nullable: true
        require_voter_name:
          type: boolean
          nullable: false
        restrict_view_access:
          type: boolean
          nullable: true
        restricted_double_opt_in_domains:
          type: array
          nullable: true
        show_as_list:
          type: boolean
          nullable: true
        show_metadata:
          type: boolean
          nullable: true
        show_photo_info_by_default:
          type: boolean
          nullable: true
        social_media_description:
          type: string
          nullable: true
        social_media_image_data:
          type: object
          nullable: true
        social_media_title:
          type: string
          nullable: true
        start_date_submission:
          type: string
          format: date-time
          nullable: true
        start_date_voting:
          type: string
          format: date-time
          nullable: true
        submission_fee:
          type: number
          format: float
          nullable: true
        submission_fee_title:
          type: string
          nullable: true
        submission_fee_type:
          type: string
          nullable: true
          enum:
            - submission_fee
            - submission_donation
        target:
          type: string
          nullable: false
          enum:
            - best_option
            - best_distribution
            - lowest_resistance
            - table
            - free_table
            - survey
            - pairwise_comparison
          description: >-
            Evaluation target. Fixed by the poll type except for
            `Polls::Voting`, see `configuration_hints`.
        terms:
          type: string
          nullable: true
        terms_for_option_creators:
          type: boolean
          nullable: true
        terms_for_voters:
          type: boolean
          nullable: true
        thank_you_page:
          type: boolean
          nullable: true
        thank_you_page_data:
          type: object
          nullable: true
        thank_you_page_submitter:
          type: boolean
          nullable: true
        thank_you_page_submitter_data:
          type: object
          nullable: true
        timezone:
          type: string
          nullable: true
        vote_limit_per_option:
          type: integer
          nullable: true
        vote_limit_per_option_min:
          type: integer
          nullable: true
        vote_limit_per_voter:
          type: integer
          nullable: true
        vote_per_day:
          type: boolean
          nullable: true
        vote_type:
          type: string
          nullable: true
          enum:
            - Votes::BooleanVote
            - Votes::BooleanPlusVote
            - Votes::BooleanThumbVote
            - Votes::BooleanPlusThumbVote
            - Votes::BooleanHeartVote
            - Votes::RatingVote
            - Votes::DotVote
            - Votes::RangeVote
            - Votes::EmojiVote
            - Votes::SuperlativeVote
            - Votes::CellVote
            - Votes::ColumnVote
            - Votes::PairwiseVote
            - Votes::TendencyVote
            - Votes::QuickQuestionSingleVote
            - Votes::QuickQuestionMultiVote
          description: >-
            Vote class used by this poll. The values allowed for a given poll
            type are listed in `configuration_hints`.
        voting_categories:
          type: array
          nullable: true
          description: >-
            Voting categories: the categories or aspects by which an option can
            be voted. Pass a list of names when creating or updating a poll; the
            show response lists them as objects with `id` and `name`. If voting
            categories are set, a vote always needs a `voting_category_id`.
          items:
            oneOf:
              - type: string
                example: creativity
              - type: object
                properties:
                  id:
                    type: integer
                  name:
                    type: string
        voting_fee:
          type: number
          format: float
          nullable: true
        voting_fee_title:
          type: string
          nullable: true
        voting_fee_type:
          type: string
          nullable: true
          enum:
            - voting_fee
            - voting_donation
            - voting_sell_votes
        white_label:
          type: boolean
          nullable: true
    RequiredFields:
      type: array
      description: >-
        Attributes the poll configuration makes mandatory when a voter or an
        option is created. Entries are attribute names; the last entry is an
        object `{ "additional_attributes": [...] }` listing the ids of the
        required additional attributes, when the poll defines any (the double
        opt in address is listed as `optin_email`).
      items:
        oneOf:
          - type: string
          - type: object
      example:
        - user_name
        - terms_accepted
        - additional_attributes:
            - ID1
            - optin_email
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: opaque
      description: Personal API token — find yours under My Account → API.

````

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