client.api.ask.userHistory

User history APIs, available as client.api.ask.userHistory, for the current user's past conversation threads.

Instance methods

client.api.ask.userHistory.deleteAllThreads([options])

Delete all of the user's threads.

Parameter Type Description
options Object Request options. Optional.

Returns Promise<Object>.

client.api.ask.userHistory.deleteThread(threadId, [options])

Delete a thread.

Parameter Type Description
threadId string
options Object Request options. Optional.

Returns Promise<Object>.

client.api.ask.userHistory.deleteThreads(payload, [options])

Delete multiple threads.

Parameter Type Description
payload Object
options Object Request options. Optional.

Returns Promise<Object>.

client.api.ask.userHistory.dismissNotifications([options])

Dismiss all notifications.

Parameter Type Description
options Object Request options. Optional.

Returns Promise<Object>.

client.api.ask.userHistory.getNotifications([options])

Get notifications of updates to the user's threads.

Parameter Type Description
options Object Request options. Optional.

Returns Promise<Object>.

client.api.ask.userHistory.getThread(threadId, [payload], [options])

Get a thread, with the IDs of its questions.

Parameter Type Description
threadId string
payload Object Optional.
options Object Request options. Optional.

Returns Promise<Object>.

client.api.ask.userHistory.getThreads(payload, [options])

List the user's threads.

Parameter Type Description
payload Object
options Object Request options. Optional.

Returns Promise<Object>.

client.api.ask.userHistory.markThreadAsRead(threadId, [options])

Mark a thread as read, dismissing its notifications.

Parameter Type Description
threadId string
options Object Request options. Optional.

Returns Promise<Object>.

client.api.ask.userHistory.subscribeThread(threadId, [options])

Subscribe to updates of a thread.

Parameter Type Description
threadId string
options Object Request options. Optional.

Returns Promise<Object>.

client.api.ask.userHistory.unsubscribeThread(threadId, [options])

Unsubscribe from updates of a thread.

Parameter Type Description
threadId string
options Object Request options. Optional.

Returns Promise<Object>.

client.api.ask.userHistory.updateThread(threadId, payload, [options])

Update a thread, such as its title.

Parameter Type Description
threadId string
payload Object
options Object Request options. Optional.

Returns Promise<Object>.