-
Notifications
You must be signed in to change notification settings - Fork 34
prompts skip
lukebaker edited this page Jan 4, 2012
·
2 revisions
Description: Skip a prompt, optionally requesting next prompt
Format: XML
URL: POST /questions/7/prompts/1/skip.xml
Parameters:
-
skip: optional, hash. Hash containing the following fields:
- visitor_identifier: optional, string: Identifier of voter. If not specified, the default visitor (the question owner) will be used. Required for with_visitor_stats
- skip_reason: optional, string: Reason visitor decided not to vote
- appearance_lookup: optional, string: ID of the prompt’s appearance (if it was generated using :with_appearance)
- time_viewed: optional, int: *Number of miliseconds between appearance and skip
- force_invalid_vote: optional, boolean: force this vote to be considered invalid. NOTE: this is not yet available in the public API, but is available in the current pairwise code.
-
next_prompt: optional, hash: Request the next prompt. May contain the following fields:
- visitor_identifier: optional, string: Identifier of voter
- with_appearance: optional, bool: Whether request should generate a new appearance
- algorithm: optional, string = “catchup”: Use catchup algorithm for selecting the next prompt
- with_visitor_stats: optional, bool: Whether to return extra parameters visitor_votes and visitor_ideas
Returns: Skip object OR prompt object if next_prompt is specified
<?xml version="1.0" encoding="UTF-8"?>
<skip>
<appearance-id type="integer" nil="true"></appearance-id>
<created-at type="datetime">2010-07-06T22:09:25-04:00</created-at>
<id type="integer">2</id>
<missing-response-time-exp></missing-response-time-exp>
<prompt-id type="integer">1</prompt-id>
<question-id type="integer">7</question-id>
<site-id type="integer" nil="true"></site-id>
<skip-reason nil="true"></skip-reason>
<skipper-id type="integer">1</skipper-id>
<time-viewed type="integer" nil="true"></time-viewed>
<tracking nil="true"></tracking>
<updated-at type="datetime">2010-07-06T22:09:25-04:00</updated-at>
</skip>
or with :next_prompt defined:
<?xml version="1.0" encoding="UTF-8"?>
<prompt>
<created-at type="datetime">2010-07-08T10:49:51+00:00</created-at>
<id type="integer">16</id>
<question-id type="integer">7</question-id>
<tracking nil="true"></tracking>
<updated-at type="datetime">2010-07-08T10:49:51+00:00</updated-at>
<votes-count type="integer">0</votes-count>
<left-choice-text>NEWNEW2</left-choice-text>
<right-choice-text>foo</right-choice-text>
<left-choice-id type="integer">18</left-choice-id>
<right-choice-id type="integer">9</right-choice-id>
</prompt>
Notes:
- all params of :next_prompt are optional, but you need to specify one to return prompt
- left/right-choice-id fields are duplicated