---
title: "Create a Vote"
method: POST
path: "/api/users/:userId/topics/:topicId/votes"
tags: ["vote"]
---

# Create a Vote

`POST /api/users/:userId/topics/:topicId/votes`

Create a Vote

## Path parameters

- `userId` string, required
- `topicId` string, required

## Request body

- object
  - `options` object[]
    - `value` string
  - `authType` 'soft' | 'hard'
  - `minChoices` integer
  - `maxChoices` integer
  - `delegationIsAllowed` boolean
  - `endsAt` string
  - `description` string
  - `type` 'regular' | 'multiple'

## Response `200`

New Vote created successfully

- object
  - `status` object
    - `code` integer
  - `data` Vote
    - `id` string
    - `minChoices` integer
    - `maxChoices` integer
    - `delegationIsAllowed` boolean
    - `createdAt` string
    - `endsAt` string
    - `description` string
    - `type` 'regular' | 'multiple'
    - `authType` 'soft' | 'hard'
    - `downloads` object
      - `bdocVote` string
      - `bdocFinal` string
      - `zipFinal` string
    - `options` object[]
      - `count` integer
      - `rows` object[]
        - `id` string
        - `value` string
        - `voteCount` integer
        - `selected` boolean

## Changes

> 10 revisions in range; 1 could not be searched.

- **2018-08-20** `3ff54b27e8aa` — 1 info
  - endpoint added
- **2018-08-20** `ba36cd387928` — 1 breaking
  - api path removed without deprecation

[Change history](https://skmtc.dev/citizenos/apis/citizenos-api/changes/api/users/:userId/topics/:topicId/votes/post.md)

---

[API](https://skmtc.dev/citizenos/apis/citizenos-api.md) · [All operations](https://skmtc.dev/citizenos/apis/citizenos-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/citizenos/citizenos-api/revisions/ca28908e6b75/schema)
