Skip to main content
Agent Builder allows users to create, deploy, and manage AI agents directly within LangSmith. This page explains how to enable Agent Builder on a self-hosted LangSmith instance.
Self-hosted LangSmith is an add-on to the Enterprise plan. For more details, refer to Pricing. Contact our sales team if you want to get a license key to trial LangSmith in your environment.

Components

Agent Builder consists of the following components:
  • agentBootstrap: Job that deploys the LangSmith Deployment (agent) needed for Agent Builder.
  • agentBuilder
    • toolServer: Provides MCP tool execution for agents.
    • triggerServer: Handles webhooks and scheduled triggers.
    • agent: The main agent that will handle agent generation and where all the assistants will be created.

Enable Agent Builder

To enable Agent Builder, add the following to your values.yaml:
backend:
  agentBootstrap:
    enabled: true

config:
  agentBuilder:
    enabled: true
    encryptionKey: "<key>"

agentBuilderToolServer:
  enabled: true

agentBuilderTriggerServer:
  enabled: true

Generate an encryption key

Agent Builder requires a Fernet encryption key to securely store secrets. Generate one using Python:
python -c "from cryptography.fernet import Fernet; print(Fernet.generate_key().decode())"
You can store the encryption key in a predefined Kubernetes secret using the agent_builder_encryption_key parameter. See Use an existing secret for details.

Enable OAuth tools and triggers (optional)

To enable OAuth-based tools (like Gmail, Slack, GitHub), configure the oauthProviderOrgId and add provider IDs for each integration you want to enable. You can enable any combination of providers.

Available providers

ProviderTools enabledTrigger enabledSetup guide
githubOAuthProviderGitHub-See below
googleOAuthProviderGmail, Google Calendar, Google Sheets, BigQueryGmailSee below
linearOAuthProviderLinear-See below
linkedinOAuthProviderLinkedIn-See below
slackOAuthProviderSlackSlackSee below

General configuration

Add the following to your values.yaml. Include only the providers you need.
backend:
  agentBootstrap:
    enabled: true

config:
  agentBuilder:
    # Organization ID where OAuth providers are configured
    oauthProviderOrgId: "<your-org-id>"
    oauth:
      # Add provider IDs for integrations you want to enable,
      # Slack requires additional configuration
      slackOAuthProvider: "<provider-id>"
      slackSigningSecret: "<signing-secret>"
      slackBotId: "<bot-id>"
      googleOAuthProvider: "<provider-id>"
      linkedinOAuthProvider: "<provider-id>"
      linearOAuthProvider: "<provider-id>"
      githubOAuthProvider: "<provider-id>"
The provider ID must be unique and cannot end with -agent-builder or -oauth-provider.

Provider setup guides

To enable GitHub OAuth for Agent Builder, you need to create a GitHub OAuth app and configure it with the required permissions.
1

Create a GitHub OAuth app

2

Configure the app

Fill in the application details. You can name it whatever you like and leave the default checkbox settings.
3

Set permissions

Give the app read/write permissions to Pull Requests and Issues.
4

Add callback URL

Set the callback URL, replacing <hostname> with your LangSmith hostname and <provider-id> with your provider ID:
https://<hostname>/host-oauth-callback/<provider-id>
5

Generate client secret

Click Generate a new client secret and copy both the Client ID (shown at the top of the app page) and the Client Secret.
6

Configure OAuth provider in LangSmith

In LangSmith, go to Settings > OAuth Providers and add a new provider:
  • Client ID: from GitHub app
  • Client Secret: from GitHub app
  • Authorization URL: https://github.com/login/oauth/authorize
  • Token URL: https://github.com/login/oauth/access_token
  • Provider ID: Unique string, for example: github
7

Deploy

Add the following to your values.yaml and deploy:
config:
  agentBuilder:
    oauthProviderOrgId: "<your-org-id>"
    oauth:
      githubOAuthProvider: "<provider-id>"
8

Install the app on repositories

After creating the app, you need to:
  1. Authenticate the app to your GitHub account.
  2. Go to Settings > Applications > Installed GitHub Apps and install the app on the repositories you want it to access.
For private repositories, you must explicitly install the app on each repository you want Agent Builder to access.
To enable Google OAuth for Agent Builder, you need to create an OAuth client in GCP and configure it with the required URLs and credentials.
1

Create OAuth client in GCP

Create a new OAuth client app (Web application) in Google Cloud Console.
2

Add URLs to GCP

Add the following URLs to your OAuth client, replacing <hostname> with your LangSmith hostname and <provider-id> with the provider ID you’ll use (e.g., google):Authorized JavaScript origins:
  • https://<hostname>
Authorized redirect URIs:
  • https://<hostname>/api-host/v2/auth/callback/<provider-id>
  • https://<hostname>/host-oauth-callback/<provider-id>
3

Copy credentials

Copy the Client ID and Client Secret from the GCP OAuth app.
4

Configure OAuth provider in LangSmith

In LangSmith, go to Settings > OAuth Providers and add a new provider:
  • Client ID: Find in GCP
  • Client Secret: Find in GCP
  • Authorization URL: https://accounts.google.com/o/oauth2/auth
  • Token URL: https://oauth2.googleapis.com/token
  • Provider ID: Unique string, for example: google
5

Deploy

Add the LangSmith OAuth provider ID to your values.yaml and deploy:
config:
  agentBuilder:
    oauthProviderOrgId: "<your-org-id>"
    oauth:
      googleOAuthProvider: "<provider-id>"
To enable Linear OAuth for Agent Builder, you need to create a Linear OAuth app and configure it with the required credentials.
1

Create a Linear OAuth app

Go to Linear Settings > API > Applications and create a new OAuth application.
2

Add callback URL

Set the callback URL, replacing <hostname> with your LangSmith hostname and <provider-id> with your provider ID:
https://<hostname>/host-oauth-callback/<provider-id>
3

Copy credentials

After creating the app, copy the Client ID and Client Secret.
4

Configure OAuth provider in LangSmith

In LangSmith, go to Settings > OAuth Providers and add a new provider:
  • Client ID: from Linear app
  • Client Secret: from Linear app
  • Authorization URL: https://linear.app/oauth/authorize
  • Token URL: https://api.linear.app/oauth/token
  • Provider ID: Unique string, for example: linear
5

Deploy

Add the following to your values.yaml and deploy:
config:
  agentBuilder:
    oauthProviderOrgId: "<your-org-id>"
    oauth:
      linearOAuthProvider: "<provider-id>"
To enable LinkedIn OAuth for Agent Builder, you need to create a LinkedIn OAuth app and configure it with the required credentials.
1

Create a LinkedIn OAuth app

Go to linkedin.com/developers/apps and create a new app.
2

Configure OAuth settings

In your app settings, go to the Auth tab.
3

Add redirect URI

Add the following redirect URI, replacing <hostname> with your LangSmith hostname and <provider-id> with your provider ID:
https://<hostname>/host-oauth-callback/<provider-id>
4

Copy credentials

Copy the Client ID and Client Secret from the Auth tab.
5

Configure OAuth provider in LangSmith

In LangSmith, go to Settings > OAuth Providers and add a new provider:
  • Client ID: from LinkedIn app
  • Client Secret: from LinkedIn app
  • Authorization URL: https://www.linkedin.com/oauth/v2/authorization
  • Token URL: https://www.linkedin.com/oauth/v2/accessToken
  • Provider ID: Unique string, for example: linkedin
6

Deploy

Add the following to your values.yaml and deploy:
config:
  agentBuilder:
    oauthProviderOrgId: "<your-org-id>"
    oauth:
      linkedinOAuthProvider: "<provider-id>"
To enable Slack OAuth for Agent Builder, you need to create a Slack app and configure it with the required scopes, credentials, and event subscriptions.
1

Create a Slack app

Go to api.slack.com/apps and click Create New App.
2

Add scopes

In OAuth & Permissions, add the following scopes:
  • channels:history
  • channels:read
  • chat:write
  • groups:history
  • groups:read
  • im:history
  • im:read
  • im:write
  • mpim:history
  • team:read
  • users:read
  • users:read.email
3

Copy credentials from Slack

Copy the Client ID, Client Secret, and Signing Secret from the Slack app settings.
4

Configure OAuth provider in LangSmith

In LangSmith, go to Settings > OAuth Providers and add a new provider:
  • Client ID: Find in Slack app
  • Client Secret: Find in Slack app
  • Authorization URL: https://slack.com/oauth/v2/authorize
  • Token URL: https://slack.com/api/oauth.v2.access
  • Provider ID: Unique string, for example: slack
5

Add redirect URI to Slack

Add the following redirect URI to your Slack app under OAuth & Permissions > Redirect URLs, replacing <hostname> with your LangSmith hostname and <provider-id> with your provider ID (e.g., slack):
https://<hostname>/host-oauth-callback/<provider-id>
6

Get the bot ID

  1. Get the bot token from OAuth & Permissions in your Slack app.
  2. Run the following command:
curl -X POST https://slack.com/api/auth.test \
  -H "Authorization: Bearer <bot-token>"
  1. Copy the bot_id from the response.
7

Deploy LangSmith

Add the following to your values.yaml and deploy:
config:
  agentBuilder:
    oauthProviderOrgId: "<your-org-id>"
    oauth:
      slackOAuthProvider: "<provider-id>"
      slackSigningSecret: "<signing-secret>"
      slackBotId: "<bot-id>"
8

Enable event subscriptions

  1. After deployment, go to Event Subscriptions in your Slack app and enable events.
  2. Set the Request URL to:
    https://<hostname>/v1/triggers/webhooks/d809e66e-0000-4000-8000-000000000002
    
  3. Add the following bot events:
    • message.channels
    • message.groups
    • message.im
    • message.mpim
9

Set up triggers and tools

  1. Add the Slack bot to the channel you want it to read from.
  2. When configuring the Slack tool or trigger in Agent Builder, provide the channel ID and channel name.

Connect these docs to Claude, VSCode, and more via MCP for real-time answers.