From a new workspace to your first cited answer in about 15 minutes.
This guide takes you from a new workspace to a Knowledge Search Agent answering questions in Slack or Microsoft Teams, with citations from your own documents.
In the web app, go to Knowledge → New knowledge base. Give it a name (ops-eu, support, finance) and choose the region if your plan offers more than one. A knowledge base is the unit of access: users and agents are granted knowledge bases, not individual sources.
Click Add source and choose a connector — for a first test, a Google Drive folder or a SharePoint library with 50–500 documents is ideal. Authorise with an account that can see everything you want indexed; permissions are synced along with the content, so users will still only see what they are allowed to see.
The first sync usually takes a few minutes. You can watch progress under Sources → Sync status.
Go to Settings → Apps and install for your workspace. Then invite the app to a channel:
/invite @brewmycode
Grant the channel access to the knowledge base you created under Knowledge → ops-eu → Access.
In the channel:
@brewmycode What is our approval threshold for supplier invoices?
The agent replies in a thread with the answer and numbered citations. Click a citation to open the exact passage in the source. If the knowledge base doesn't contain the answer, the agent says so.
Create an API key under Settings → API keys and run:
curl https://api.brewmycode.com/v1/queries \
-H "Authorization: Bearer $BMC_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"knowledge_base": "ops-eu",
"query": "What is our approval threshold for supplier invoices?",
"as_user": "marja@example.com"
}'
The response includes answer, citations[] and confidence. See the Queries endpoint.