Developers
Build with StrawPoll
Create polls and forms from your own code, collect responses and read the results. One API key and a few lines are all it takes.
Create your first poll
Three steps from nothing to a live poll.
01
Create an API key
Create one in Settings → API keys and put it in an environment variable, so it stays out of your code:
export STRAWPOLL_API_KEY="sp_your_key"02
Run a script
Save the script and run it. It publishes a poll and prints its voting and results links.
curl -s -X POST "https://new.strawpoll.com/api/v4/polls" \ -H "X-API-Key: $STRAWPOLL_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "title": "Where should we go for lunch?", "options": ["Pizza", "Sushi", "Tacos"] }' \ | jq -r '.urls.voteUrl, .urls.resultsUrl'Runsh create-poll.sh· Needs jq03
Read the results
Fetch the poll by its id, the end of its link. Each option comes with its votes.
curl "https://new.strawpoll.com/api/v4/polls/w8Jq3KdN" \ -H "X-API-Key: $STRAWPOLL_API_KEY"
Everything for developers
- API reference Every endpoint with its parameters, payloads and responses.
- Playground Send real requests with your key, right from the browser.
- AI assistants (MCP) Let Claude, ChatGPT and other agents create polls for you.
- Embeds Put a poll on your website with an iframe or a script tag.
- Webhooks Get every new response posted to your server.
- OpenAPI spec Generate a client or import the API into Postman or Insomnia.
- Poll API v3 The previous API, still running for existing integrations.
- llms.txt A summary of StrawPoll and its API for language models.