Skip to content
Scalekit Docs
Talk to an Engineer Dashboard

Connect AI agents to Butterbase

Scalekit connector
Open markdown

The Butterbase connector lets your AI agent act in each user's Butterbase account. Each user connects their own Butterbase access token once, and Scalekit sends it with every call, so your agent never handles credentials. It comes with 210 tools.

Tools
210
What they doRead · write · destructive
92 · 96 · 2292 read96 write22 destructive
Users sign in with

Setup

  1. Install the SDK

    Terminal window
    npm install @scalekit-sdk/node dotenv
  2. Set your credentials

    Add your Scalekit credentials to your .env file. Find values in app.scalekit.com > Developers > API Credentials.

    .env
    SCALEKIT_ENVIRONMENT_URL=<your-environment-url>
    SCALEKIT_CLIENT_ID=<your-client-id>
    SCALEKIT_CLIENT_SECRET=<your-client-secret>
  3. Create the Butterbase connection

    In AgentKit > Connections, create a Butterbase connection. The name you give it is the connection_name your code passes. See Configure connections.

  4. Authorize a user and make your first call

    quickstart.mts
    import { ScalekitClient } from '@scalekit-sdk/node'
    import 'dotenv/config'
    import { createInterface } from 'node:readline/promises'
    const scalekit = new ScalekitClient(
    process.env.SCALEKIT_ENVIRONMENT_URL,
    process.env.SCALEKIT_CLIENT_ID,
    process.env.SCALEKIT_CLIENT_SECRET,
    )
    const actions = scalekit.actions
    const connector = 'butterbase'
    const identifier = 'user_123'
    // Generate an authorization link for the user
    const { link } = await actions.getAuthorizationLink({ connectionName: connector, identifier })
    console.log('Authorize Butterbase:', link)
    const rl = createInterface({ input: process.stdin, output: process.stdout })
    await rl.question('Press Enter after authorizing...')
    rl.close()
    // Make your first call
    const result = await actions.executeTool({
    connector,
    identifier,
    toolName: 'butterbase_apps_list',
    toolInput: {},
    })
    console.log(result)
    Terminal window
    npx tsx quickstart.mts

    Each user opens the link once and enters their Butterbase credentials there. See Authorize a user for the full flow and statuses.

Tools

Pass the exact name to execute_tool
Try in PlaygroundRequest a tool
  • butterbase_agent_getGet a single Butterbase agent's full configuration by name, including its model, graph_spec, visibility, and run limits.Read-only

    Get Agent

    Get a single Butterbase agent's full configuration by name, including its model, graph_spec, visibility, and run limits. Returns the agent object as Butterbase stores it. Use butterbase_agent_get to inspect one specific agent. Use butterbase_agents_list to browse every agent in the app.

    Inputs

    app_idstringrequired
    The Butterbase app's unique ID the agent belongs to.
    namestringrequired
    The unique name of the agent to fetch, as given when it was created (or seen in a prior butterbase_agents_list response).
  • butterbase_agent_run_events_listFetch every event recorded for an agent run as a single JSON array, instead of connecting to the run's live event stream.Read-only

    List Agent Run Events

    Fetch every event recorded for an agent run as a single JSON array, instead of connecting to the run's live event stream. Returns an array of event objects covering the run's lifecycle — run_start, node_start, node_end, tool_call_start, tool_call_end, llm_token_usage, run_paused, run_cancelled, run_failed, and run_end. Use butterbase_agent_run_events_list to review a run's full event history at any point after it starts. Use butterbase_agent_run_get instead for just the run's current summary state.

    Inputs

    app_idstringrequired
    The id of the Butterbase app the agent belongs to.
    idstringrequired
    The id of the run whose events you want to fetch.
    namestringrequired
    The unique name of the agent whose run's events you want to fetch.
  • butterbase_agent_run_getGet a single agent run's full state by id.Read-only

    Get Agent Run

    Get a single agent run's full state by id. Returns the run object, including its status and, once available, its output. Use butterbase_agent_run_get to inspect or poll one specific run. Use butterbase_agent_runs_list to find its id first.

    Inputs

    app_idstringrequired
    The Butterbase app's unique ID the agent belongs to.
    namestringrequired
    The unique name of the agent the run belongs to.
    run_idstringrequired
    The id of the run to fetch, as returned by butterbase_agent_run_create or a prior butterbase_agent_runs_list call.
  • butterbase_agent_runs_listList an agent's recent runs.Read-only

    List Agent Runs

    List an agent's recent runs. Returns an array of run objects with each run's id and status; Butterbase's docs don't itemize further response fields or pagination parameters for this endpoint. Use butterbase_agent_runs_list to see recent activity for one agent. Use butterbase_agent_run_get to fetch one run's full state.

    Inputs

    app_idstringrequired
    The Butterbase app's unique ID the agent belongs to.
    namestringrequired
    The unique name of the agent whose runs to list.
  • butterbase_agents_listList all agents defined in a Butterbase app.Read-only

    List Agents

    List all agents defined in a Butterbase app. Returns an array of agent objects, each with the agent's name, display name, description, default model, visibility, and run/budget limits. Use butterbase_agents_list to see which agents exist in an app before starting or configuring a run against one of them.

    Inputs

    app_idstringrequired
    The Butterbase app ID whose agents you want to list. Found in the app's dashboard URL or via Butterbase's apps listing.
  • butterbase_ai_config_getGet an app's AI gateway configuration in Butterbase.Read-only

    Get AI Config

    Get an app's AI gateway configuration in Butterbase. Returns a config object with the app's default model, its maximum tokens allowed per request, and its list of allowed models. Use butterbase_ai_config_get to check an app's current AI settings before calling butterbase_ai_config_update to change them.

    Inputs

    app_idstringrequired
    The id of the Butterbase app whose AI configuration to fetch.
  • butterbase_ai_models_listList the AI models available and allowed for use by one Butterbase app.Read-only

    List AI Models

    List the AI models available and allowed for use by one Butterbase app. Returns a JSON array of model objects (exact fields are not published in Butterbase's docs). Use butterbase_ai_models_list to see which model identifiers are valid before calling butterbase_chat_completions_create or butterbase_embeddings_create.

    Inputs

    app_idstringrequired
    The Butterbase app ID whose allowed AI models to list.
  • butterbase_ai_usage_getGet AI usage and cost statistics for a Butterbase app, optionally scoped to a date range.Read-only

    Get AI Usage

    Get AI usage and cost statistics for a Butterbase app, optionally scoped to a date range. Returns the total token count, total cost, and a per-model breakdown of tokens, cost, and request count. Use butterbase_ai_usage_get to monitor AI spend for an app over time, narrowing the results with a start and end date.

    Inputs

    app_idstringrequired
    The id of the Butterbase app whose AI usage to fetch.
    end_datestring
    End of the date range to report usage for, as YYYY-MM-DD. If omitted, usage is not bounded on the end date.
    start_datestring
    Start of the date range to report usage for, as YYYY-MM-DD. If omitted, usage is not bounded on the start date.