Poll Fields

Field Type Description
closed_at string The time at which the poll closes in ISO 8601 format.
created_at string The time at which the poll was created in ISO 8601 format.
id string Primary identifier for a poll. This will be an integer, but it is always expressed as a string to avoid limitations with the way JavaScript integers are expressed. This id space is unique to poll objects. There can be a Post and User with the same ID; no relation is implied.
is_anonymous boolean Whether poll results are anonymous, or if who responded to what option is displayed when the poll is over (or the creator of the poll looks at it).
is_public boolean Whether poll is public or private. If private, it still may be attached to a public object, such as a post or a message.
max_options integer How many options can be selected at once by responders. Default is 1.
options object A list of 2 to 10 responses for the poll.
Field Type Description
text string Up to 64 Unicode characters. One response for users to choose for the poll. Any spaces, including line endings, will be replaced with a single space.
position integer Order of the option in the list of options, starting at 1 and going up sequentially. Assigned by the API if the user does not specify them.
is_your_response boolean Optional. Present if authenticated as a user. True if user responded to the poll with this option.
respondents integer Optional. Present if authenticated user a) created the poll, b) has responded to the poll, or c) the poll is closed.
respondent_ids object Optional. Present if is_anonymous is false and a condition for respondents above is also met.
poll_token string A token to access and respond to the poll. Only included on creation, if included in the query string, or if the Polls scope gives you access to the poll.
prompt string A readable name of the poll. This is the prompt users will be responding to for the Options. Up to 256 Unicode characters. Be sure to escape if necessary.
source object An embedded object of the client that created the poll.
type string The type of poll. Generally uses a reversed domain name to identify the intended purpose. Non-core poll types (io.pnut.core.*) are not authenticated by the server; clients should not assume other clients created their poll types the same way.
user object This is an embedded User object. In certain cases, this key may be omitted.
raw object The raw items attached to this object. Only included if query parameter specified.
Field Type Description
type string The type of raw item this is.
value object The values and fields you specify for this raw item.

General Poll Parameters

Any endpoint that returns poll objects can be subject to these parameters.

General Parameters

Name Type Description
include_closed integer (0 or 1) Include closed polls. Only applicable to the user's poll stream. Defaults to true.
include_private integer (0 or 1) Include private polls. Only applicable to the user's poll stream. Defaults to true.
poll_types string Comma-separated list of poll types to retrieve. Only applicable to the user's poll stream. If not included, will return any polls the app is authorized to view.
exclude_poll_types string Comma-separated list of poll types not to retrieve. Only applicable to the user's poll stream. Ignored if poll_types set.
include_raw integer (0 or 1) Include raw on all objects. Defaults to false.
include_poll_raw integer (0 or 1) Include raw on all poll objects. Defaults to false.