Skip to main content

Stories Widget Events

You can recieve widget interaction data by subscribing to Story Widget Events.

  • iOS: use the IASEvent.Story.storyWidgetEvent()
  • Android: InAppStoryManager.getInstance().setStoryWidgetCallback()
  • JS: inAppStoryManager.on("widgetEvent", (payload) => {});

The names of widget events and the data that they return are listed below.

Click on link/button in story's slide

KeyTypeDescription
story_idIntunique story ID
feed_idInt?ID of the feed the story was opened from. null if it's single
slide_indexIntindex of story's slide where callback was called
widget_idStringunique widget ID
widget_labelStringbutton text
widget_valueStringbutton url

w-quiz-answer

Click on any point in "quiz" widget

KeyTypeDescription
story_idIntunique story ID
feed_idInt?ID of the feed the story was opened from. null if it's single
slide_indexIntindex of story's slide where callback was called
widget_idStringunique widget ID
widget_labelStringquiz question
widget_answerIntanswer index. For example A = 0, B = 1 etc.
widget_answer_labelStringanswer text
duration_msInthow much time did it take to answer

w-quiz-grouped-answer

Click on any point in "quiz category grouped" widget

KeyTypeDescription
story_idIntunique story ID
feed_idInt?ID of the feed the story was opened from. null if it's single
slide_indexIntindex of story's slide where callback was called
widget_idStringunique widget ID
widget_labelStringquiz question
widget_answerIntanswer index. For example A = 0, B = 1 etc.
widget_answer_labelStringanswer text
duration_msInthow much time did it take to answer

w-data-input-focus

Click input field in "ask question" widget (show dialog)

KeyTypeDescription
story_idIntunique story ID
feed_idInt?ID of the feed the story was opened from. null if it's single
slide_indexIntindex of story's slide where callback was called
widget_idStringunique widget ID
widget_labelStringquestion text

w-data-input-save

Send data in "ask question" widget (close dialog)

KeyTypeDescription
story_idIntunique story ID
feed_idInt?ID of the feed the story was opened from. null if it's single
slide_indexIntindex of story's slide where callback was called
widget_idStringunique widget ID
widget_labelStringquestion text
widget_valueStringsent text from dialog

w-range-slider-answer

Send slider value in "feedback" widget. Can be called on click or slider changes (optionally)

KeyTypeDescription
story_idIntunique story ID
feed_idInt?ID of the feed the story was opened from. null if it's single
slide_indexIntindex of story's slide where callback was called
widget_idStringunique widget ID
widget_labelStringquestion text
widget_answerIntsent value (from 0 to 100)

w-poll-answer

Click on any point in "poll" widget (yes/no)

KeyTypeDescription
story_idIntunique story ID
feed_idInt?ID of the feed the story was opened from. null if it's single
slide_indexIntindex of story's slide where callback was called
widget_idStringunique widget ID
widget_labelStringpoll question text
widget_answerIntanswer index (0 to left or 1 to right button)
widget_answer_labelStringanswer text
duration_msInthow much time did it take to answer

w-poll-clarification

Send data from dialog in "poll" widget after choosing answer (if set)

KeyTypeDescription
story_idIntunique story ID
feed_idInt?ID of the feed the story was opened from. null if it's single
slide_indexIntindex of story's slide where callback was called
widget_idStringunique widget ID
widget_labelStringpoll question text
widget_answerIntanswer index (0 to left or 1 to right button)
widget_answer_labelStringanswer text
duration_msInthow much time did it take to answer
widget_valueStringsent text from dialog

w-poll-layers-answer

Click on any point in "poll with layers" widget (yes/no)

KeyTypeDescription
story_idIntunique story ID
feed_idInt?ID of the feed the story was opened from. null if it's single
slide_indexIntindex of story's slide where callback was called
widget_idStringunique widget ID
widget_labelStringpoll's question text
widget_answerIntanswer's index (0 to left or 1 to right button)
duration_msInthow much time did it take to answer

w-vote-answer

Click on any point in "vote" widget

KeyTypeDescription
story_idIntunique story ID
feed_idInt?ID of the feed the story was opened from. null if it's single
slide_indexIntindex of story's slide where callback was called
widget_idStringunique widget ID
widget_labelStringvote question text
widget_answerIntanswer index (0 to N-1 where N - num of answer points)
widget_valueStringanswer text
duration_msInthow much time did it take to answer

w-rate-answer

Click on "rate us" widget

KeyTypeDescription
story_idIntunique story ID
feed_idInt?ID of the feed the story was opened from. null if it's single
slide_indexIntindex of story's slide where callback was called
widget_idStringunique widget ID
widget_labelStringwidget text
widget_answerIntanswer index (0 to 5)
widget_valueStringuser input text
duration_msInthow much time did it take to answer

w-test-answer

Click on any point in "test" widget

KeyTypeDescription
story_idIntunique story ID
feed_idInt?ID of the feed the story was opened from. null if it's single
slide_indexIntindex of story's slide where callback was called
widget_idStringunique widget ID
widget_labelStringtest's question text
widget_answerIntanswer index (0 to N-1 where N - num of answer points or -1 - for widget without answer (timer expired))
widget_answer_labelStringanswer text
widget_answer_scoreInthow much points user get for this answer
duration_msInthow much time did it take to answer

w-copy

Click on "copy" widget

KeyTypeDescription
story_idIntunique story ID
feed_idInt?ID of the feed the story was opened from. null if it's single
slide_indexIntindex of story's slide where callback was called
widget_idStringunique widget ID
widget_labelStringbutton's text
widget_valueStringcopied text

w-share

Click on "share" widget

KeyTypeDescription
story_idIntunique story ID
feed_idInt?ID of the feed the story was opened from. null if it's single
slide_indexIntindex of story's slide where callback was called
widget_idStringunique widget ID
widget_labelStringbutton text
widget_valueStringshared text
widget_answerInt0 - share successful, 1 - share canceled
widget_answer_labelStringsharing application package

w-goods-open

Opens goods list in SDK

KeyTypeDescription
story_idIntunique story ID
feed_idInt?ID of the feed the story was opened from. null if it's single
slide_indexIntindex of story's slide where callback was called
widget_idStringunique widget ID

w-goods-click

Click on any good in list

KeyTypeDescription
story_idIntunique story ID
feed_idInt?ID of the feed the story was opened from. null if it's single
slide_indexIntindex of story's slide where callback was called
widget_idStringunique widget ID
widget_valueStringgood's sku

w-products-click

Click on "products" widget

KeyTypeDescription
story_idIntunique story id
feed_idInt?unique feed id where stories was opened. Null if it's single.
slide_indexIntindex of story's slide where callback was called
widget_idStringunique widget id
widget_labelStringbutton's text
widget_valueNumber[]offers sku (platform internal ids)

w-products-open

Opens a product list in SDK

KeyTypeDescription
story_idIntunique story id
feed_idInt?unique feed id where stories was opened. Null if it's single.
slide_indexIntindex of story's slide where callback was called
widget_idStringunique widget id
widget_labelStringbutton's text
widget_valueNumber[]offers sku (platform internal ids)
widget_itemsNumber[]offers ids

w-products-card-click

Click on offer card in a product list

KeyTypeDescription
story_idIntunique story id
feed_idInt?unique feed id where stories was opened. Null if it's single.
slide_indexIntindex of story's slide where callback was called
widget_idStringunique widget id
widget_labelStringbutton's text
widget_valueNumberoffer id
widget_value_idNumberoffer id (platform internal id)

w-products-add-to-cart

Adding a product to cart event

KeyTypeDescription
story_idIntunique story id
feed_idInt?unique feed id where stories was opened. Null if it's single.
slide_indexIntindex of story's slide where callback was called
widget_idStringunique widget id
quantityNumberOffers quantity
widget_valueNumberoffer id
widget_value_idNumberoffer id (platform internal id)

w-products-go-to-cart

Go to product cart event

KeyTypeDescription
story_idIntunique story id
feed_idInt?unique feed id where stories was opened. Null if it's single.
slide_indexIntindex of story's slide where callback was called
widget_idStringunique widget id

Click on product card in a product carousel

KeyTypeDescription
story_idIntunique story id
feed_idInt?unique feed id where stories was opened. Null if it's single.
slide_indexIntindex of story's slide where callback was called
widget_idStringunique widget id
widget_valueNumberoffer id
widget_value_idNumberoffer id (platform internal id)

Click on button "Buy now"

KeyTypeDescription
story_idIntunique story id
feed_idInt?unique feed id where stories was opened. Null if it's single.
slide_indexIntindex of story's slide where callback was called
widget_idStringunique widget id
widget_valueNumberoffer id
widget_value_idNumberoffer id (platform internal id)

Adding a product to cart event

KeyTypeDescription
story_idIntunique story id
feed_idInt?unique feed id where stories was opened. Null if it's single.
slide_indexIntindex of story's slide where callback was called
widget_idStringunique widget id
quantityNumberOffers quantity
widget_valueNumberoffer id
widget_value_idNumberoffer id (platform internal id)

Go to product cart event

KeyTypeDescription
story_idIntunique story id
feed_idInt?unique feed id where stories was opened. Null if it's single.
slide_indexIntindex of story's slide where callback was called
widget_idStringunique widget id

w-barcode

Click on "barcode" widget

KeyTypeDescription
story_idIntunique story id
feed_idInt?unique feed id where stories was opened. Null if it's single.
slide_indexIntindex of story's slide where callback was called
widget_idStringunique widget id
widget_labelStringbutton's text
widget_valueStringcopied text

w-tooltip-show

Widget "tooltip" rendering on slide start

KeyTypeDescription
story_idIntunique story id
feed_idInt?unique feed id where stories was opened. Null if it's single.
slide_indexIntindex of story's slide where callback was called
widget_idStringunique widget id
widget_labelStringbutton's text
widget_tooltip_templateNumberTooltip content template (0 - without template. 1 - ERID template)

w-tooltip-click

Click on "tooltip" widget

KeyTypeDescription
story_idIntunique story id
feed_idInt?unique feed id where stories was opened. Null if it's single.
slide_indexIntindex of story's slide where callback was called
widget_idStringunique widget id
widget_labelStringbutton's text
widget_tooltip_templateNumberTooltip content template (0 - without template. 1 - ERID template)

w-tooltip-copy-click

Copy content from tooltip in "tooltip" widget (applicable only for ERID template)

KeyTypeDescription
story_idIntunique story id
feed_idInt?unique feed id where stories was opened. Null if it's single.
slide_indexIntindex of story's slide where callback was called
widget_idStringunique widget id
widget_labelStringbutton's text
widget_valueStringcopied text
widget_tooltip_templateNumberTooltip content template (0 - without template. 1 - ERID template)

w-reactions-answer

Click on any reaction in "reactions" widget

KeyTypeDescription
story_idIntunique story id
slide_indexIntindex of story's slide where callback was called
widget_idStringunique widget id
widget_answerIntreaction index (0 to N-1 where N - num of reactions)
duration_msInthow much time did it take to answer

w-scratch-card-complete

Complete scratch the layer on the "scratch card" widget

KeyTypeDescription
story_idIntunique story id
slide_indexIntindex of story's slide where callback was called
widget_idStringunique widget id
duration_msInthow much time did it take to scratch the layer