The open-source AI receptionist for businesses. Answers every call, books the appointment and hands over to a person when needed. You own the code and the data.
TypeScript ai-receptionistanswering-serviceappointment-bookinglivekitlocal-firstmcpopen-sourceself-hostedsiptelephonytypescriptvoice-agentvoice-ai
// Workspace settings › General: the business card with Edit and the Calls lines (LIN-837), no workspace call language
// (removed 2026-11-16; the assistant's main language picks the call language), and during support access every field is
// read-only and says why.
import { renderToStaticMarkup } from 'react-dom/server'
import { expect, test, vi } from 'vitest'
vi.mock('./settings-api.ts', () => ({
useWorkspaceSettings: () => ({ data: null, error: null, reload: async () => {} }),
patchWorkspaceSettings: vi.fn(),
refreshWorkspaceSettings: vi.fn(),
callAction: vi.fn(),
useWriteAction: () => vi.fn(),
}))
vi.mock('../store.tsx', () => ({ useRun: () => vi.fn(), useRows: () => [] }))
vi.mock('../shell/WorkspaceSwitcher.tsx', () => ({ useWorkspaces: () => [] }))
const { WorkspaceGeneral } = await import('./WorkspaceGeneral.tsx')
const { SupportAccessContext } = await import('../supportAccess.ts')
const render = (canEdit: boolean, supportAccess = false, hash = '#workspace/general/edit') => {
vi.stubGlobal('window', { location: { hash }, addEventListener() {}, removeEventListener() {} })
return renderToStaticMarkup(
<SupportAccessContext.Provider value={supportAccess}>
<WorkspaceGeneral canEdit={canEdit} name="Brightwater Plumbing & Heating" onRenamed={() => {}} toast={() => {}} />
</SupportAccessContext.Provider>,
)
}
test('closed: the business card with Edit, then Recordings and (owners and admins) Export calls as lines', () => {
const admin = render(true, false, '#workspace/general')
expect(admin).toContain('<h2>Brightwater Plumbing & Heating</h2>')
expect(admin).toContain('>Edit<')
expect(admin).not.toContain('id="ws-name"')
expect(admin).toContain('Recordings')
expect(admin).toContain('Export calls')
expect(admin).not.toContain('Caller privacy notice')
const member = render(false, false, '#workspace/general')
// Members only look: Show, never Details or Change.
expect(member).toContain('>Show<')
expect(member).not.toContain('>Details<')
expect(member).not.toContain('>Change<')
expect(member).not.toContain('Export calls')
// A link to a line opens it.
expect(render(true, false, '#workspace/general/export')).toContain('Export CSV')
})
test('there is no call language field, for admins and read-only members alike', () => {
for (const canEdit of [true, false]) {
const html = render(canEdit)
expect(html).not.toContain('ws-language')
expect(html).not.toContain('Call language')
}
})
test('during support access every field is read-only and says why', () => {
const html = render(false, true)
expect(html).toContain('Read-only while you are signed in as another user.')
expect(html).not.toContain('Only admins can change this.')
// The name reads as text, not as a field that looks as if it could change.
expect(html).toContain('<span class="ws-value-text" id="ws-name">')
expect(html).not.toMatch(/<input[^>]*id="ws-name"/)
})