00

Overview

Sockt is a compute-on-demand platform built for AI agents. Agents create sandboxes, pay per second in sats via Lightning, execute commands, and terminate — no human in the loop.

There are two integration paths: the MCP server at https://api.sockt.dev/v1/mcp (for LLM agents using tool-use), and the @sockt/client SDK (for programmatic access from TypeScript, Python, or Go).

Base URL

https://api.sockt.dev

Authentication

For credits billing, send Authorization: Bearer sockt_.... For sats billing, connect any external Lightning wallet as an MCP server and let the agent pay autonomously.

ModeRequestWhat happens
CreditsAuthorization: Bearer sockt_...Request is billed to your credits balance.
Lightning wallet MCPExternal wallet server connectedAgent creates and pays for sandboxes in sats using your connected wallet.

Rate Limits

300 requests/minute per API key. Excess requests receive 429 rate limited.

01

MCP Server

Configure Sockt in your MCP client by pointing to https://api.sockt.dev/v1/mcp.

Sockt MCP Setup

{
  "mcpServers": {
    "sockt": {
      "url": "https://api.sockt.dev/v1/mcp"
    }
  }
}

External Wallet MCP (Example: lnbot)

Sockt does not provide the wallet. Connect any Lightning wallet MCP server for agent payments.

{
  "mcpServers": {
    "lnbot": {
      "type": "url",
      "url": "https://api.ln.bot/v1/wallets/wal_sp28n1b9lj2ueemoip4n1qpxm3y0/mcp",
      "headers": {
        "Authorization": "Bearer uk_x53uqf3q7rl2zxom4zwmwet12lril07fhff7v4q3glbm7hoyprzlhf4rdeld"
      }
    }
  }
}

Available Tools

sandbox_createProvision a new sandbox on the specified tier. Returns sandbox ID and proxy URL.
sandbox_execRun a shell command inside a sandbox. Returns stdout, stderr, and exit code.
sandbox_write_fileWrite a file into the sandbox filesystem at a given path.
sandbox_read_fileRead the contents of a file from the sandbox filesystem.
sandbox_list_filesList files at a path inside the sandbox.
sandbox_statusGet current sandbox state: running, paused, terminated, etc.
sandbox_pausePause billing and execution for an idle sandbox.
sandbox_resumeResume a paused sandbox.
sandbox_terminateDestroy the sandbox and stop billing.
sandbox_extend_balanceAdd more sats or credits to a running sandbox.
02

SDK

The @sockt/client package provides a typed client for TypeScript and JavaScript. Python and Go clients are available under the sockt package name on their respective registries.

Install

npm install @sockt/client
# or
pip install sockt

TypeScript

import { ComputeClient } from '@sockt/client';

const client = new ComputeClient({ apiKey: process.env.SOCKT_API_KEY });

const sandbox = await client.createSandbox({
  tier: 'micro',
  billingMethod: 'credits',
});

const result = await sandbox.exec('python eval.py --dataset cifar10');
console.log(result.stdout);

await sandbox.terminate();

Python

from sockt import ComputeClient

client = ComputeClient(api_key=os.environ["SOCKT_API_KEY"])

sandbox = client.create_sandbox(tier="micro", billing_method="credits")

result = sandbox.exec("python eval.py --dataset cifar10")
print(result.stdout)

sandbox.terminate()

ComputeClient methods

MethodDescription
createSandbox({ tier, billingMethod })Create and start a sandbox. Returns sandbox object.
sandbox.exec(command)Run a shell command. Returns { stdout, stderr, exitCode }.
sandbox.writeFile(path, content)Write a file to the sandbox filesystem.
sandbox.readFile(path)Read a file from the sandbox filesystem.
sandbox.pause()Pause billing and freeze execution.
sandbox.resume()Resume from paused state.
sandbox.terminate()Destroy sandbox and stop billing.
sandbox.status()Get current sandbox state.
COMING SOON
RELATED
PricingSDK overviewUse casesHomepageTermsPrivacy