create_poll
Create polls with customizable types (proposal, poll, count, score, ranked_choice, meeting, dot_vote) and options. Attach to a group or discussion thread.
Instructions
Create a new Loomio poll. Required: title, poll_type — one of 'proposal' (built-in agree / disagree / abstain), 'poll' (single-choice), 'count' (count signers), 'score' (1-5 rating, configurable via min_score / max_score), 'ranked_choice' (STV), 'meeting' (time poll), 'dot_vote' (point allocation, see dots_per_person). For every type except 'proposal' you MUST supply options (array of strings). Either supply group_id for a standalone poll or discussion_id to attach to an existing thread. Optional: details + details_format, closing_at (ISO-8601), anonymous, hide_results ('off' / 'until_vote' / 'until_closed'), specified_voters_only, shuffle_options, notify_on_closing_soon, recipient fields. KNOWN UPSTREAM LIMITATION: Loomio's b2 permitted_params omits :private, so the auto-created Topic always defaults to private: true and groups with public-discussions-only policy reject the create with a 422 and empty errors hash. See NOTES-ON-LOOMIO-API.md. Workaround at the moment: create polls only in groups that allow private discussions.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| title | Yes | Poll title (required). | |
| poll_type | Yes | Poll type. One of: proposal, poll, count, score, ranked_choice, meeting, dot_vote. | |
| group_id | No | Group the poll belongs to. Required when not attaching to an existing discussion via discussion_id. | |
| discussion_id | No | Attach the poll to an existing discussion. When set, group_id is taken from the discussion. | |
| details | No | Optional poll body / context. | |
| details_format | No | Format of `details`. Defaults to 'md'. | |
| options | No | Voting options. `proposal` has built-in agree/disagree/abstain options; for poll / count / score / ranked_choice / meeting / dot_vote you MUST supply your own. | |
| closing_at | No | ISO-8601 timestamp at which the poll closes. | |
| specified_voters_only | No | If true, only users in recipient_user_ids / recipient_emails can vote. | |
| hide_results | No | Results visibility policy. Defaults to 'off'. | |
| shuffle_options | No | If true, shuffle option display order. | |
| anonymous | No | If true, hide voter identities. | |
| recipient_audience | No | ||
| notify_on_closing_soon | No | Who Loomio notifies as the closing date approaches. Defaults to 'nobody'. | |
| recipient_user_ids | No | ||
| recipient_emails | No | ||
| recipient_message | No | ||
| notify_recipients | No | If false, suppress the initial notification email. Defaults to false. |