Jump to: navigation, search

Feedback

The Feedback API gives users a way to send feedback on how useful the responses were.

Important
The Feedback covered by this API conveys how relevant specific answers have been in response to the search questions. This kind of information is not available for browsing articles based on categories.

Authorization

The operations carried out by the Feedback API can be accessed by all roles.

Complex types

UnansweredRequestBody

Field Type Description
question String QNA question
answer String QNA question
categories RequestKbCategory related categories
knowledgebases String [] Related knowledgebases

FederatedVoteDocument

Field Type Description
KbId String Identifier of knowledgebase
docId String Identifier of document

FederatedVoteRequest

Field Type Description
selection DocumentVote [] List of documents in voting selection
like DocumentVote The one document that must be voted positive against another documents from list of "selection" that must be voted as negative.
request SearchRequest Search request used for obtaining of "selection".

RatingRequest

Field Type Description
comment String Text of comment
rating integer Rating value. 1..5

HistoryRecordId Complex Type

Field Type Description
recordId String Identifier of record in history storage

VoteComment Complex Type

Field Type Description
comment String Text of user comment

DocumentRateResponse

Field Type Description
avgRate float Average user rate
rateCounters int [5] Number of user votes for each document rate value:

rateCounters[0] - counter for rate=1 star
....
rateCounters[4] - counter for rate=5 stars

visits int count of user visits

API Reference

No Answer

Description Marks a query as not having a valid answer in the knowledge base
URL /feedback/{kbId}/noAnswer
Method POST
Request Content-Type
Response Content-Type application/json
Role Any
URL Identifiers
Parameter Type Description
{kbId} String Knowledge base ID
URL Parameters
Parameter Type Required Default Description
lang String Yes "_default" Language ID
sessionId String No Session ID
tenantId String Yes Tenant identifier
Request Search query, as described in "Search for answers" section
Parameter Type Required Default Description
question String Yes User question (query)
categories String[] No Related categories
Response HistoryRecordId
Notes In case of success returns payload in response field of "response" of declared structure.

In case of error returns code and description of error.

Register Vote

Description Records the user rating for the document within the query
URL /feedback/{kbId}/documents/{docId}/vote
Method POST
Request Content-Type
Response Content-Type application/json
Role Any
URL Identifiers
Parameter Type Description
{kbId} String Knowledge base ID
{docId} String Document ID
URL Parameters
Parameter Type Required Default Description
relevant Boolean No true Was the search result relevant?
lang String Yes "_default" Language ID
sessionId String No Unique session ID
tenantId String Yes Tenant identifier
Request SearchRequest
Response HistoryRecordId
Notes In case of success returns payload in response field of "response" of declared structure.

In case of error returns code and description of error.

Advance Register Vote

Description Records user rating for the document within query
URL /feedback/{kbId}/documents/{docId}/advancevote
Method POST
Request Content-Type
Response Content-Type application/json
Role Any
URL Identifiers
Parameter Type Description
{kbId} String Knowledgebase identifier
{docId} String Document identifier
URL Parameters
Parameter Type Required Default Description
relevant Boolean No "_default" Whether the search result was relevant?
lang String Yes "_default" Language identifier
sessionId String No Session identifier
tenantId String Yes Tenant identifier
Request AdvanceVote
Response HistoryRecordId
Notes In case of success returns payload in response field of "response" of declared structure.

Register unanswered federated search request

Description Saves information about federated search request that had no relevant answer (similar to noAnswer, but for federated search)
URL /feedback/unanswered
Method POST
Request Content-Type
Response Content-Type application/json
Role Any
URL Identifiers
URL Parameters
Parameter Type Required Default Description
lang String Yes "_default" Language identifier
sessionId String No Session identifier
tenantId String Yes Tenant identifier
Request SearchRequest
Response HistoryRecordId
Notes In case of success returns payload in response field of "response" of declared structure.

In case of error returns code and description of error.

Register usage of document content

Description Saves information about fact of usage of content of document for answering to user question by agent from agent workspace
URL /feedback/{kbId}/documents/{docId}/use
Method POST
Request Content-Type
Response Content-Type application/json
Role Any
URL Identifiers
Parameter Type Description
kbId String Knowledge base identifier
docId String Document identifier
URL Parameters
Parameter Type Required Default Description
lang String Yes "_default" Language identifier
sessionId String No Session identifier
tenantId String Yes Tenant identifier
Request SearchRequest
Response HistoryRecordId
Notes In case of success returns payload in response field of "response" of declared structure.

In case of error returns code and description of error.

Extend feedback with rating and comment

Description Adds comment and user rating to vote, registered by POST /feedback/vote
URL /feedback/vote/{voteId}
Method PUT
Request Content-Type
Response Content-Type application/json
Role Any
URL Identifiers
Parameter Type Description
voteId String Record identifier, obtained as response after executing POST /feedback/vote
URL Parameters
Parameter Type Required Default Description
lang String Yes "_default" Language identifier
sessionId String No Session identifier
tenantId String Yes Tenant identifier
Request RatingRequest
Response HistoryRecordId
Notes In case of success returns payload in response field of "response" of declared structure.

In case of error returns code and description of error.

Federated vote

Description Registers vote against result of federated search
URL /feedback/langs/{lang}/vote/
Method POST
Request Content-Type
Response Content-Type application/json
Role Any
URL Identifiers
Identifier Type Description
lang String Language identifier
URL Parameters
Parameter Type Required Default Description
sessionId String No Session identifier
tenantId String Yes Tenant identifier
Request FederatedVoteRequest
Response HistoryRecordId
Notes In case of success returns payload in response field of "response" of declared structure.

In case of error returns code and description of error.

Register Visit

Description Increments the counter of the viewed document
URL /feedback/{kbId}/documents/{docid}/visit
Method POST
Request Content-Type
Response Content-Type application/json
Role Any
URL Identifiers
Parameter Type Description
{kbId} String Knowledge base ID
{docId} String Unique document ID
URL Parameters
Parameter Type Required Default Description
lang String Yes "_default" Language
sessionId String No Unique session ID for history tracking
tenantId String Yes Tenant identifier
Request SearchRequest
Response HistoryRecordId
Notes Returns id of the history record that was created as a result of the visit registering.

Add user comment to particular vote

Description Adds text of user comment to record of particular vote
URL /vote/{voteId}/
Method PUT
Response Content-Type application/json
Role Any
URL Identifiers
Parameter Type Description
{voteId} String Identifier of the record in history storage, obtained as a result of registering the vote.
URL Parameters
Parameter Type Required Default Description
tenantId String Yes Tenant identifier
Request Body VoteComment
Response HistoryRecordId
Notes Returns the same record id that was sent as the voteId in the parameters.

Register user rating for document

Description Registers user rating of particular document (with optional search context )
URL /{kbId}/documents/{docId}/rating
Method POST
Request Content-Type
Response Content-Type application/json
Role Any
URL Identifiers
Parameter Type Description
kbId String Knowledge base identifier
docId String Document identifier
URL Parameters
Parameter Type Required Default Description
lang String Yes "_default" Language identifier
sessionId String No Session identifier
tenantId String Yes Tenant identifier
Request RatingRequest
Response DocumentRateResponse
Notes In case of success returns payload in response field of "response" of declared structure.

In case of error returns code and description of error.

Register of fact of receiving new interaction by agent UI

Description Creates history record of type INTERACTION
URL /feedback/interaction
Method PUT
Request Content-Type
Response Content-Type application/json
Role Any
URL Identifiers
URL Parameters
Parameter Type Required Default Description
sessionId String No Session identifier
tenantId String Yes Tenant identifier
Request
Response HistoryRecordId
Notes In case of success returns payload in response field of "response" of declared structure.

In case of error returns code and description of error.

This page was last edited on June 21, 2017, at 14:12.
Comments or questions about this documentation? Contact us for support!