A key that only does what the chat does
The Opensolr Chat Bot you install on your own site answers your visitors from an Opensolr index. Your site keeps the API key and calls Opensolr for each answer. It works with your master API key, but it does not need everything that key can do. Give it a scoped key made for it instead: one box ticks exactly the endpoints the chat calls.
Create the key
- Open Account › API Keys.
- Name this key, for example Chat bot on www.example.com.
- Under What may this key do?, tick Chat bot: Opensolr Chat Bot.
- Under Which indexes may it touch?, tick only the index the chat answers from.
- Click Create key and copy it.
Put it in the chat admin
- Sign in to the chat admin on your site and open the Account tab.
- The Email stays the email of your Opensolr account.
- Paste the scoped key as the API key and click Test connection.
- Choose the index and click Save settings.
The key must be sent with the email of the account that created it, also when a colleague sets up the chat.
What the box ticks: 15 endpoints
Opensolr Chat Bot
| Endpoint | What it is used for |
|---|---|
get_index_list | Lists your indexes when you click Test connection in the chat admin. |
assistant_chat | Answers your visitors from your index, as the answer is written. |
vdb_search | Runs the /search command on your index. |
vdb_info | Reads how long a translation by the chat model may be. |
chat_completions | Runs the /translate command and recognizes the language of the text to translate. |
assistant_account | Runs the account commands (/account, /index, /ingestion, /errors, /support) for signed-in visitors. |
enrich_text | Runs the /language command. |
local_time | Runs the /time command. |
currency_rates | Runs the /rate command. |
vat_rates | Runs the /vat command. |
vat_check | Runs the /vatcheck command. |
geo_distance | Runs the /distance command. |
address_geo | Runs the /place command. |
postal_codes | Runs the /postal command. |
ip_geo | Runs the /ip command and gives the Stats the country of each visitor. |
Good to know
- A new version of the chat may start calling a new endpoint. If it answers
403 ERROR_SCOPED_KEY_ENDPOINT_NOT_ALLOWED, edit the key and tick the box again. - To cut the chat off from your account at once, revoke its key. You can change, revoke or regenerate it at any time on Account › API Keys. See Authentication and keys.