Skip to content
Scalekit Docs
Talk to an Engineer Dashboard

Connect AI agents to Daytona

Scalekit connector
Open markdown

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

Tools
100
What they doRead · write · destructive
42 · 49 · 942 read49 write9 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 Daytona connection

    In AgentKit > Connections, create a Daytona 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 = 'daytona'
    const identifier = 'user_123'
    // Generate an authorization link for the user
    const { link } = await actions.getAuthorizationLink({ connectionName: connector, identifier })
    console.log('Authorize Daytona:', 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: 'daytona_get_current_api_key',
    toolInput: {},
    })
    console.log(result)
    Terminal window
    npx tsx quickstart.mts

    Each user opens the link once and enters their Daytona 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
  • daytona_check_port_in_useCheck whether a specific port is in use inside a started Daytona sandbox.Read-only

    Check Port in Use

    Check whether a specific port is in use inside a started Daytona sandbox. Returns isInUse as true or false. Use daytona_check_port_in_use to confirm a server has started. Use daytona_list_ports to see all open ports.

    Inputs

    portintegerrequired
    Port number to check, between 3000 and 9999. Example: 3000
    sandbox_idstringrequired
    ID of a started sandbox (the UUID in the `id` field from daytona_list_sandboxes or daytona_get_sandbox, not the name). The sandbox must be in the started state and in the US region. Example: 3f2b8c1e-5a4d-4e6f-9b7a-1c2d3e4f5a6b
  • daytona_download_fileRead the contents of a file inside a started Daytona sandbox.Read-only

    Download File

    Read the contents of a file inside a started Daytona sandbox. Returns the file contents; text files come back as a string. Use daytona_download_file to read source files, logs or outputs. Use daytona_get_file_info for metadata only. Binary files are not decoded.

    Inputs

    pathstringrequired
    Path of the file to read. Example: /home/daytona/workspace/main.py
    sandbox_idstringrequired
    ID of a started sandbox (the UUID in the `id` field from daytona_list_sandboxes or daytona_get_sandbox, not the name). The sandbox must be in the started state and in the US region. Example: 3f2b8c1e-5a4d-4e6f-9b7a-1c2d3e4f5a6b
  • daytona_find_in_filesSearch the contents of files under a directory inside a started Daytona sandbox for a text pattern (like grep).Read-only

    Find in Files

    Search the contents of files under a directory inside a started Daytona sandbox for a text pattern (like grep). Returns matches with file, line number and the matching line content. Use daytona_find_in_files to locate code or text. Use daytona_search_files to match file names, and daytona_replace_in_files to change matches.

    Inputs

    pathstringrequired
    Directory to search in. Example: /home/daytona/workspace
    patternstringrequired
    Text pattern to search for. Example: TODO
    sandbox_idstringrequired
    ID of a started sandbox (the UUID in the `id` field from daytona_list_sandboxes or daytona_get_sandbox, not the name). The sandbox must be in the started state and in the US region. Example: 3f2b8c1e-5a4d-4e6f-9b7a-1c2d3e4f5a6b
  • daytona_get_current_api_keyGet details of the Daytona API key used for this connection.Read-only

    Get Current API Key

    Get details of the Daytona API key used for this connection. Returns the key's name, masked value, permissions, createdAt and expiresAt. Use daytona_get_current_api_key to check which permissions the connected key has when a call returns 403.

    Inputs

    This tool takes no inputs.

  • daytona_get_file_infoGet metadata for one file or folder inside a started Daytona sandbox.Read-only

    Get File Info

    Get metadata for one file or folder inside a started Daytona sandbox. Returns name, path, isDir, size, mode, permissions, owner, group and modifiedAt. Use daytona_get_file_info to check that a path exists or read its size and permissions. Use daytona_download_file for the contents.

    Inputs

    pathstringrequired
    Path of the file or folder. Example: /home/daytona/workspace/main.py
    sandbox_idstringrequired
    ID of a started sandbox (the UUID in the `id` field from daytona_list_sandboxes or daytona_get_sandbox, not the name). The sandbox must be in the started state and in the US region. Example: 3f2b8c1e-5a4d-4e6f-9b7a-1c2d3e4f5a6b
  • daytona_get_organizationGet the details and per-sandbox limits of a Daytona organization.Read-only

    Get Organization

    Get the details and per-sandbox limits of a Daytona organization. Returns the organization's id, name, suspension status, defaultRegionId and limits such as maxCpuPerSandbox, maxMemoryPerSandbox and maxDiskPerSandbox. Use daytona_get_organization to read limits before sizing sandboxes. Use daytona_get_organization_usage for current quota usage.

    Inputs

    organization_idstringrequired
    ID of the Daytona organization. Every sandbox object carries it in its `organizationId` field (see daytona_get_sandbox). Example: 2c9a7a4e-1f0b-4d1e-8c3a-6f5e4d3c2b1a
  • daytona_get_organization_usageGet the current CPU, memory, disk and GPU usage of a Daytona organization against its quotas, per region and sandbox class.Read-only

    Get Organization Usage

    Get the current CPU, memory, disk and GPU usage of a Daytona organization against its quotas, per region and sandbox class. Returns regionUsage entries with total quotas and current usage for CPU, memory, disk and GPU. Use daytona_get_organization_usage to check headroom before creating sandboxes. Use daytona_get_organization for per-sandbox limits. The API key needs the read:billing or write:sandboxes permission.

    Inputs

    organization_idstringrequired
    ID of the Daytona organization. Every sandbox object carries it in its `organizationId` field (see daytona_get_sandbox). Example: 2c9a7a4e-1f0b-4d1e-8c3a-6f5e4d3c2b1a
  • daytona_get_port_preview_urlGet the HTTP preview URL for a port inside a Daytona sandbox, so a web app or API running there can be reached from a browser.Read-only

    Get Port Preview URL

    Get the HTTP preview URL for a port inside a Daytona sandbox, so a web app or API running there can be reached from a browser. Returns the preview url, the sandboxId and an access token (send it as the x-daytona-preview-token header when the sandbox is private). Use daytona_get_port_preview_url for a standard preview link. Use daytona_get_signed_preview_url for a self-contained link that expires.

    Inputs

    portintegerrequired
    Port number inside the sandbox where your app or server is listening, between 3000 and 9999. Example: 3000
    sandbox_id_or_namestringrequired
    ID or name of the sandbox. Use daytona_list_sandboxes to find it. Example: my-sandbox