DreamBot API 4.0 + Claude

Write DreamBot OSRS scripts.
Let AI know the API.

A Python MCP server that gives Claude real-time access to DreamBot API 4.0 JavaDocs — so it stops guessing and starts writing correct code.

How it works

Two components working together on every script you write.

You ask Claude

Describe what you want your bot to do — withdraw logs, walk to a spot, check NPC state — in plain English.

Skill activates

The dreambot-scripting skill loads API 4.0 patterns and enforces correct import and method usage before any code is written.

MCP fetches docs

Five MCP tools pull live JavaDoc data — packages, classes, members — so every method call is grounded in the real API, not training guesses.

MCP Tools

Five tools that cover the full API discovery loop.

dreambot_search

Hybrid keyword + semantic search across the full API — start here every time.

// Input
query: "check if bank is open"
top_k: 8  // optional — max results (default: 8)

// Output
[Bank]  isOpen() → boolean
  → Returns true if the bank interface is open
  Package: org.dreambot.api.methods.container.impl.bank
dreambot_overview

Returns the full package list for DreamBot API 4.0 — a top-level map of everything available.

// Input: (none)

// Output
DreamBot API 4.0 — Package List
org.dreambot.api.methods.container.impl.bank
org.dreambot.api.methods.interactive
org.dreambot.api.methods.walking.impl
org.dreambot.api.methods.skills
... 40+ packages total
dreambot_package

Lists all classes inside a specific package with their JavaDoc href links.

// Input
package: "org.dreambot.api.methods.container.impl.bank"

// Output
Class Summary:
  Bank (href: Bank.html)
    → Provides all banking operations
  BankLocation (href: BankLocation.html)
    → Enum of all bank locations in OSRS
dreambot_member

Fetches all methods and fields for a specific class — the full member listing with signatures and descriptions.

// Input
package: "org.dreambot.api.methods.container.impl.bank"
href:    "Bank.html"

// Output (excerpt)
[static boolean] isOpen()
  → Returns true if the bank is open
[static boolean] open()
  → Attempts to open the nearest bank
[static boolean] withdraw(String name, int amount)
  → Withdraws amount of item by name
dreambot_tile

Converts an Explv map URL into ready-to-paste DreamBot Tile, Area, and walking snippet.

// Input
url: "https://explv.github.io/?centreX=3165&centreY=3487&centreZ=0&zoom=7"

// Single tile
new Tile(3165, 3487, 0)

// Area (±15 tiles around center)
new Area(3150, 3472, 3180, 3502)

// Walk and wait until within 5 tiles
Walking.walk(new Tile(3165, 3487, 0));
Sleep.sleepUntil(() -> Players.getLocal().distance(new Tile(3165, 3487, 0)) < 5, 10_000);

Claude Code Skill

One skill that primes Claude with everything it needs to write correct DreamBot scripts.

  • API 4.0 static-method access pattern (no MethodProvider)
  • Script skeleton with @ScriptManifest and AbstractScript
  • State machine structure for clean onLoop()
  • Banking, walking, NPC/object interaction patterns
  • Anti-ban timing with Calculations.random()
  • When to reach for each MCP tool
Activates on
DreamBot OSRS scripting RuneScape bot bot script write a script

The rule it enforces

// ✓ API 4.0 — always this
import org.dreambot.api.methods.container.impl.bank.Bank;
Bank.isOpen();
Bank.open();
Bank.withdraw("Logs", 28);

// ✗ API 3.x — never this
// getBank().open();  ← MethodProvider is deprecated

Setup

Three steps to get Claude writing DreamBot scripts with real API knowledge.

1

Install dependencies

Clone the repository and install the Python requirements.

pip install -r requirements.txt
2

Register the MCP server

Add the server to your claude_desktop_config.json (or equivalent MCP config file).

{
  "mcpServers": {
    "dreambot-scripting": {
      "command": "python",
      "args": ["C:/path/to/Dreambot-Scripting-MCP-main/server.py"]
    }
  }
}

Replace the path with your actual install location. The DreamBot API v4 folder must be present in the MCP root before starting the server.

3

Install the skill

Copy the skill file into your Claude Code plugins directory, then restart Claude Code.

# Source file (repo root)
dreambot-scripting.skill

# Copy to your Claude Code plugins directory, e.g.:
~/.claude/plugins/dreambot-scripting.skill

After restarting, Claude Code will automatically load the skill whenever you mention DreamBot, OSRS scripting, or writing a bot script.

On Windows, use %USERPROFILE%\.claude\plugins\ instead of ~/.claude/plugins/.