Thread dialog

This example shows how to build a chat thread inside a dialog using Superinterface.
Thread dialog assistant
AI provider
Superinterface Cloud logo
Superinterface Cloud
gpt-4.1-mini
Instructions
When to use thread dialog: works in all pages as a floating AI assistant. Superinterface is AI infrastructure platform.
Functions
No functions used.
'use client' import { SuperinterfaceProvider, ThreadDialog, AssistantProvider, } from '@superinterface/react' import { Theme } from '@radix-ui/themes' import '@radix-ui/themes/styles.css' import { QueryClient, QueryClientProvider } from '@tanstack/react-query' const queryClient = new QueryClient({ defaultOptions: { queries: { staleTime: 10000, }, }, }) export default function Page() { return ( <QueryClientProvider client={queryClient}> <Theme accentColor="ruby" grayColor="gray" appearance="light" radius="medium" scaling="100%" > <SuperinterfaceProvider variables={{ publicApiKey: '18d58cdd-96bc-4d01-ab21-1a891a4fd49e', assistantId: '622c9397-dfaf-43de-8fe9-0cc414e19ab7', }} > <AssistantProvider> <ThreadDialog /> </AssistantProvider> </SuperinterfaceProvider> </Theme> </QueryClientProvider> ) }
Superinterface thread dialog example.
Superinterface thread dialog example.
This example is hosted here: https://examples-thread-dialog.superinterface.ai (see code here)

Getting Started

First, run the development server:
npm run dev # or yarn dev # or pnpm dev # or bun dev
Open http://localhost:3000 with your browser to see the result.
You can start editing the page by modifying app/page.tsx. The page auto-updates as you edit the file.