Create a poll
realtime_kit.active_session.create_poll(strmeeting_id, ActiveSessionCreatePollParams**kwargs) -> ActiveSessionCreatePollResponse
POST/accounts/{account_id}/realtime/kit/{app_id}/meetings/{meeting_id}/active-session/poll
Creates a new poll in an active session for the given meeting ID.
Security
API Token
The preferred authorization scheme for interacting with the Cloudflare API. Create a token.
Example:
Accepted Permissions (at least one required)
Create a poll
import os
from cloudflare import Cloudflare
client = Cloudflare(
api_token=os.environ.get("CLOUDFLARE_API_TOKEN"), # This is the default and can be omitted
)
response = client.realtime_kit.active_session.create_poll(
meeting_id="meeting_id",
account_id="023e105f4ecef8ad9ca31a8372d0c353",
app_id="app_id",
options=["string"],
question="question",
)
print(response.data){
"data": {
"action": "action",
"poll": {
"id": "id",
"options": [
{
"count": 0,
"text": "text",
"votes": [
{
"id": "id",
"name": "name"
}
]
}
],
"question": "question",
"anonymous": true,
"created_by": "created_by",
"hide_votes": true,
"voted": [
"string"
]
}
},
"success": true
}Returns Examples
{
"data": {
"action": "action",
"poll": {
"id": "id",
"options": [
{
"count": 0,
"text": "text",
"votes": [
{
"id": "id",
"name": "name"
}
]
}
],
"question": "question",
"anonymous": true,
"created_by": "created_by",
"hide_votes": true,
"voted": [
"string"
]
}
},
"success": true
}