Skip to content

Connection Components

Production Integration

For production browser integration, use Configure.connections() and Configure.singleConnector() from https://configure.dev/js/configure.js. Raw components are available from import "configure/components" for local labs and advanced self-hosted surfaces.

Connection List

Show connector connection state for Gmail, Calendar, Drive, and Notion.

html
<script src="https://configure.dev/js/configure.js"></script>
<div id="configure-connections"></div>

<script>
  Configure.connections({
    el: "#configure-connections",
    publishableKey: "pk_...",
    agent: "your-agent",
    displayName: "Your Agent",
    token,
    connectors: ["gmail", "calendar", "drive", "notion"],
  });
</script>

After a user connects an account, opt into the matching server-side connector tool for turns that need it:

ts
const tools = profile.tools({
  connectors: ["gmail", "calendar"],
});

The component handles connection UX. The server still decides which connector tools are exposed to the model and executes Configure tool calls through profile.executeTool().

Raw component example:

ts
import "configure/components";
html
<configure-connection-list
  api-key="pk_..."
  connectors="gmail,calendar,drive,notion">
</configure-connection-list>
AttributeTypeDefaultDescription
api-keystring-Configure publishable key.
connectorsstringgmail,calendar,notionComma-separated connector IDs.
connectionsarray[]Connection data when assigned as a JS property.
EventDetailDescription
configure:tool-connect{ tool }User clicked connect.
configure:tool-disconnect{ tool }User clicked disconnect.
configure:tool-error{ tool, error }Connection error.

Single Connector

Use a focused single-connector surface when the model attempted a connector-backed tool and the user needs to connect or reconnect that account.

js
Configure.singleConnector({
  el: "#connector-slot",
  publishableKey: "pk_...",
  agent: "your-agent",
  displayName: "Your Agent",
  token,
  tool: "gmail",
  message: "Connect Gmail to search your emails",
});

Raw component example:

html
<configure-single-connector
  api-key="pk_..."
  tool-id="gmail"
  message="Connect Gmail to search your emails">
</configure-single-connector>

Personalization infrastructure for agents