{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/pnut/json-schema/pnut-post-polls-request-schema.json",
  "title": "PostPollsRequest",
  "x-generated": "2026-10-28",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/_ae-authored/pnut-openapi-generated.yml#/components/schemas/PostPollsRequest",
  "type": "object",
  "properties": {
    "closed_at": {
      "type": "string",
      "description": "ISO 8601 timestamp at least 1 minute and no more than 2 weeks in the future, after which no one can respond to it"
    },
    "duration": {
      "type": "number",
      "description": "number of minutes the poll should be open, minimum of 1 and maximum of 20160"
    },
    "options": {
      "type": "array",
      "description": "List of 2 to 10 options must be specified, each with text and optional position"
    },
    "prompt": {
      "type": "string",
      "description": "256-character explanation or question for the options"
    },
    "type": {
      "type": "string",
      "description": "Reverse domain name-style identifier of the poll type. E.g., com.example.site"
    },
    "is_anonymous": {
      "type": "boolean",
      "description": "If false, user IDs will be identified in the final poll"
    },
    "is_public": {
      "type": "boolean",
      "description": "If true, poll is public"
    },
    "max_options": {
      "type": "number",
      "description": "Number of options a user can respond with, from 1 to the total number of options"
    }
  },
  "required": [
    "options",
    "prompt",
    "type"
  ]
}