IrisGPT API Documentation
Introduction
IrisAgent's IrisGPT AI answers can be used an API to power intelligent conversations on any of your frontend webpages. It can search through your internal and external knowledge articles, community forums, product documentation, and other informational content.
API Guide
Below is a curl command to call our IrisGPT API:
curl -X POST --location "https://frontend-api-server-v2.api.irisagent.com/v1/irisgpt/ask" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer REPLACE_ME_BUSINESS_ID" \
-H "X-Language-Iso-Code: en" \
-d '{
"query": "how do agents use knowledge",
"sessionId": "1234",
"productId": "Single Sign-On",
"userId": "2345"
}'
Here, the inputs are:
- query: [Required] URL-encoded query from the user
- REPLACE_ME_BUSINESS_ID: This is the ID provided by the IrisAgent team
- sessionId: [Optional] This is the session ID for the chat to retain context and provide contextual responses
- productId: [Optional] If you have multiple products and knowledge base segmented by products, you can provide the product ID here
- userId: [Optional] This is the ID of the user asking the question to personalize the response
Below is a sample output of the API:
{
"result": {
"htmltext": "Agents can leverage knowledge to help customers by using the Knowledge Capture app. This app allows agents to search the Help Center without leaving the ticket, insert links to relevant Help Center articles in ticket comments, add inline feedback to existing articles, and create new articles while answering tickets using a pre-defined template. This helps agents assist customers effectively while also enhancing self-service options for other customers.\n<br>\nCheck out this article for more information:\n<ul> <li style=\"list-style-position: inside;\"><a href='https://d3v-irisagent.zendesk.com/hc/en-us/articles/360046592594-How-can-agents-leverage-knowledge-to-help-customers' target='_blank'>How can agents leverage knowledge to help customers?</a></li> </ul>",
"links": [
{
"text": "How can agents leverage knowledge to help customers?",
"url": "https://d3v-irisagent.zendesk.com/hc/en-us/articles/360046592594-How-can-agents-leverage-knowledge-to-help-customers"
}
],
"linksTitle": "Check out this article for more information:",
"plaintext": "Agents can leverage knowledge to help customers by using the Knowledge Capture app. This app allows agents to search the Help Center without leaving the ticket, insert links to relevant Help Center articles in ticket comments, add inline feedback to existing articles, and create new articles while answering tickets using a pre-defined template. This helps agents assist customers effectively while also enhancing self-service options for other customers.",
"mdText": "Agents can leverage knowledge to help customers by using the Knowledge Capture app. This app allows agents to search the Help Center without leaving the ticket, insert links to relevant Help Center articles in ticket comments, add inline feedback to existing articles, and create new articles while answering tickets using a pre-defined template. This helps agents assist customers effectively while also enhancing self-service options for other customers. - Check if the control number is mandatory for the account you are trying to use. If it is, make sure the control number is correctly entered.\n- Verify that you have the necessary permissions to edit or create journal entries, as permissions can affect your ability to make changes.\n- If the journal entry is already posted, you may need to reverse it and create a new entry with the correct control number.\n## Check out the following resource(s) for more information:\n- [Need to change control while Journal Entry Posting.](https://example.com/670da173611ddba46ef12ed1)\n- [ACCOUNTING SETTINGS: Journals](https://example.com/670da22d611ddba46ef13675)",
"source": "python-ml",
"urls": [
"https://d3v-irisagent.zendesk.com/hc/en-us/articles/360046592594-How-can-agents-leverage-knowledge-to-help-customers"
]
}
}