-
Notifications
You must be signed in to change notification settings - Fork 2
Inter App Communication
B9ChatAI supports the utilization of URLs with the b9chatai://
or b9software.chat-ai://
prefix. These URLs can be used to interact with B9ChatAI and carry out particular tasks in other applications.
By using Raycast Quicklinks, you can invoke B9ChatAI in this powerful productivity application to quickly switch to a specific conversation and send content quickly.
In the conversation menu, you can copy the link used for Quicklink:
Simply paste the copied link when creating a Quicklink:
Currently, you can send text via JavaScript bookmarks. In the menu above the chat, you can find the option to copy the chat browser bookmark. Clicking on it will copy the bookmark URL to the clipboard:
Video:
jsbookmark-chrome.mp4
Reference steps:
- Copy the bookmark link from the app menu
- Add a bookmark in Chrome and modify the URL
- Select text, click on the link in the bookmark bar; if everything works correctly, the selected text will be sent to the app
Video:
jsbookmark-demo-safari.mp4
Reference steps:
- Copy the bookmark link from the app menu
- Create a bookmark
- Find the bookmark you just created and modify the address
- Select text, click on the link in the bookmark bar; if everything works correctly, the selected text will be sent to the app
Tip: Safrai can always show the Favorites bar in the menu
You can control B9ChatAI through the open
command
# Send "say hello from Terminal" to the default chat
open "b9chatai://send?text=say%20hello%20from%20Terminal"
# Send content to a chat with conversation ID 'demo'
open "b9chatai://send?id=demo&text=say%20hello%20from%20Terminal"
An app invocation link generally consists of the following three parts:
- Scheme, which can be
b9chatai://
orb9software.chat-ai://
- Command: Tells the app which action to perform
- Parameters: Contains several parameters
All fields are case-sensitive.
Supported from v0.2, currently supports two parameters
-
id, optional, chat ID, you can copy and set them in the chat settings.
- If not specified, it first looks for a chat with an ID of 'default'; if none is found, it uses the first chat in the list
- If the specified ID does not exist, no action is performed
-
text, optional, the text content to be sent. Not sending text is equivalent to activating the specified chat, which can be used to switch between chats
You can download this helper program to debug link invocation