Skip to main content
Glama
Bambu Studio MCP

Bambu Studio MCP

Bambu Studio MCP

An MCP server that lets any LLM client slice, paint and check 3D prints through the Bambu Studio command line — for every Bambu printer and nozzle installed on your machine, with your own filament presets, and with settings chosen per type of object.

Unofficial. Not affiliated with, endorsed by or supported by Bambu Lab. "Bambu Lab" and "Bambu Studio" are trademarks of their owners.

It never prints. No tool sends anything to a printer, over LAN or cloud, and nothing is ever opened in your Bambu Studio window. The server runs the headless slicer and writes files; you open the result in Bambu Studio and press print yourself.

Leia em português

What it does

Tool

list_printers

Every installed printer + nozzle: bed, height, forbidden zones, defaults

list_presets

Process and filament presets compatible with a printer — yours included

get_settings

Every valid setting key with its value, and which ones can be set per object

list_object_types

functional, decorative, miniature, flat, enclosure, vase, draft, print_in_place

analyze_model

Size, fit, overhangs, bed contact, flat tops, suggested object type — plus a preview image

slice_model

Meshes → Bambu project → sliced and verified: time, grams per filament, purge, colour changes

compare_slices

The same model sliced several ways (process, support_type, wall_loops…) side by side

slice_project

Re-slice an existing .3mf (e.g. from MakerWorld) with other settings, filaments or printer — every plate, or just the one you want (plate)

paint_model

Colour a single mesh by rules — height, facing, image projection, bucket fill — with preview

self_test

Proves the colour-paint encoding on your machine (run after updating Bambu Studio)

Per-object and per-part settings, modifier volumes (a region with its own settings), negative volumes and support blockers/enforcers are all supported.

Why "verified"

Bambu Studio's CLI answers Success. for prints that are wrong. While building this, it did so for: colour parts that dropped onto the bed as loose objects, a weight of 0 g, and a prime tower inside the printer's forbidden zone. Every slice here is checked against what the project was meant to be, and the result carries a problems list. A non-empty list means the print is not ready.

One thing the checks deliberately do not claim: in a multi-plate project Bambu reports each plate's objects in model coordinates, and only the first plate sits at the bed's origin — the rest come back on a layout grid whose stride Bambu does not publish. Those plates are checked for whether the layout fits the bed and whether objects collide, which holds wherever the origin is, and the result says their exact placement was not judged instead of guessing it.

Related MCP server: snapmaker-u1-mcp

Requirements

  • Bambu Studio installed and opened at least once (it installs the printer profiles). Tested with 02.08.02.61.

  • Python 3.10+.

Install

pip install git+https://github.com/welingtonmatos/bambu-studio-mcp

or without installing anything permanently, with uv:

uvx --from git+https://github.com/welingtonmatos/bambu-studio-mcp bambu-studio-mcp

Connect it to your client

Claude Code

claude mcp add bambu-studio -- bambu-studio-mcp

Claude Desktop (claude_desktop_config.json) and most other clients:

{
  "mcpServers": {
    "bambu-studio": { "command": "bambu-studio-mcp" }
  }
}

If the client cannot find the command, use the full path of the bambu-studio-mcp executable inside your Python environment.

Non-default locations — set these environment variables:

Variable

Default

BAMBU_STUDIO_EXE

Windows C:\Program Files\Bambu Studio\bambu-studio.exe · macOS /Applications/BambuStudio.app/Contents/MacOS/BambuStudio · Linux bambu-studio on PATH

BAMBU_STUDIO_CONFIG_DIR

Windows %APPDATA%\BambuStudio · macOS ~/Library/Application Support/BambuStudio · Linux ~/.config/BambuStudio

BAMBU_STUDIO_MCP_CACHE

per-user cache folder

Using it

Ask in plain language — the model picks the tools:

"Slice bracket.stl for my P1S as a functional part in PETG and tell me how long it takes."

"I have keychain-black.stl and keychain-gold.stl for the A1 mini. How much of the filament is purge? Would 3 per plate be faster per unit?"

"Paint everything above 3.3 mm of sign.stl gold and the rest black, then show me the preview."

"Compare tree and normal supports for statue.stl."

Colour words in file or mesh names choose filament slots automatically (-black, -gold, -red, and the Portuguese -preto, -dourado, -vermelho, …); a part without one is the base colour.

Paint rules

[
  {"type": "height",  "from": 3.3, "to": 99,                   "filament": 2},
  {"type": "facing",  "direction": "up", "angle": 20,          "filament": 2},
  {"type": "image",   "file": "logo.png", "view": "top",
                      "colors": {"#FF0000": 3, "#FFFFFF": 4},  "tolerance": 80},
  {"type": "body",    "index": 1,                              "filament": 3},
  {"type": "fill",    "point": [12.0, 4.5, 3.8], "angle": 30,  "filament": 4}
]

Rules apply in order. Any rule accepts "within": [x0,y0,z0,x1,y1,z1] and "only_from": slot. Image projection paints side walls with the colour of their inside, so raised letters come out whole.

How it works

  • Configuration for any printer. There is no public schema for a project's settings, so the server asks Bambu Studio to write it: it slices a 20 mm cube with the printer's default process and filament, once with 1 filament and once with 2, and keeps what Bambu Studio saved. Comparing the two shows how every setting grows per filament. Cached per printer; refreshed when Bambu Studio updates. Presets are read from your installation and never bundled.

  • Object types start from Bambu's own profiles — functional applies exactly what Bambu's "0.20mm Strength" changes — and pick the installed process whose layer height suits the nozzle. Every value used was sliced and confirmed to be kept by Bambu Studio and to have an effect.

  • Automatic adjustments add tree supports (overhangs ≥ 3 % of the surface, ignoring hidden interfaces between parts) and an 8 mm brim (tall/narrow or little bed contact), per object. Anything you set explicitly wins. Turn off with auto_adjust: false.

  • Colour changes are counted from the G-code; the number in Bambu's result.json is wrong.

  • Paint is written per triangle in the same attribute the GUI brush uses; boundaries are made crisp by subdividing triangles to the requested resolution (mesh stays watertight).

Tested

OS

Windows 11

Bambu Studio

02.08.02.61 (profiles BBL 02.08.00.06)

Sliced end to end

A1 mini (0.4), P1S (0.4)

Listed, not sliced

the other 54 installed printer/nozzle presets

macOS and Linux paths follow Bambu Studio's documented locations but are untested — reports and pull requests are welcome. Dual-nozzle printers (H2D/H2C) are listed but not yet verified.

Limitations

  • Purge volumes use Bambu Studio's uncalibrated default (280 mm³ between any two filaments). Open the project in Bambu Studio and sync the AMS to recalculate them for your exact colours.

  • slice_model builds a single plate (slice_project reads and slices multi-plate files); height-range modifiers are not supported yet.

  • Paint is per whole triangle (after subdivision); very fine artwork needs a small resolution, which makes larger files.

Development

git clone https://github.com/welingtonmatos/bambu-studio-mcp && cd bambu-studio-mcp
python -m venv .venv && .venv/bin/pip install -e ".[dev]"     # Windows: .venv\Scripts\pip
pytest            # tests marked 'studio' are skipped when Bambu Studio is not installed

License

MIT — see LICENSE. This package contains no Bambu Studio code or profiles; it runs the Bambu Studio executable you installed and reads the profiles on your machine.

Available Tools

11 tools
analyze_modelA
Read-onlyIdempotent

Geometry before slicing: size, fit on the printer, overhang share, bed contact, slenderness, flat tops and which installed layer heights hit them exactly, suggested object types, plus a preview image of the model.

Inputs: path (required), nozzle, printer.

compare_slicesB
Read-onlyIdempotent

Slice the same model several ways and compare time, grams, colour changes, support time and how far flat tops fall from the layer grid. vary='process' (values optional: the sensible layer heights for the nozzle) or any setting key with explicit values, e.g. vary='support_type', values=['tree(auto)','normal(auto)']. Nothing is saved.

Inputs: vary (required), objects (required), printer (required), nozzle, +6 more.

get_environmentB
Read-onlyIdempotent

Where Bambu Studio and its profiles are, profile version, cache folder, safety guarantees.

Inputs: no named parameters.

get_settingsA
Read-onlyIdempotent

Every valid setting key with its current value for printer+process. Filter with words ('support', 'wall', 'infill', 'brim', 'ironing', 'seam'). 'per_object' tells which keys may be set per object/part. Use the exact keys in slice_model 'settings'.

Inputs: printer (required), query, nozzle, process.

list_object_typesA
Read-onlyIdempotent

Object types and what each changes from the printer's default (functional, decorative, miniature, flat, enclosure, vase, draft, print_in_place, standard).

Inputs: no named parameters. Returns: result

list_presetsC
Read-onlyIdempotent

Process or filament presets compatible with a printer, including the user's own presets.

Inputs: kind (required), printer (required), query, nozzle. Returns: result

list_printersB
Read-onlyIdempotent

Installed printer presets (one per printer + nozzle): bed size, max height, forbidden zones, number of extruders, default process and filament. 'query' filters by words, e.g. 'P1S 0.4'.

Inputs: query. Returns: result

paint_modelA
Idempotent

Colour a single mesh by rules -- the Bambu Studio brush, automated -- then slice and verify.

Rules apply in order (later wins); each needs 'type' and usually 'filament': {"type":"height","from":3.3,"to":99,"filament":2} {"type":"facing","direction":"up","angle":20,"filament":2} {"type":"image","file":"logo.png","view":"top","colors":{"#FF0000":3},"tolerance":80} {"type":"body","index":1,"filament":3} {"type":"fill","point":[x,y,z],"angle":30,"filament":4} Any rule accepts "within":[x0,y0,z0,x1,y1,z1] and "only_from":slot. z is measured from the part's base. Returns the result and a preview image -- check it before trusting the paint.

Inputs: path (required), rules (required), printer (required), output_dir (required), +9 more.

self_testB
Read-onlyIdempotent

Slice six colour bands to prove the paint codes on this machine. Run after updating Bambu Studio.

Inputs: nozzle, printer.

slice_modelA
Idempotent

Build a Bambu Studio project from meshes, slice it headless and verify the result.

Writes <output_dir>/.3mf (saved by Bambu Studio itself, G-code inside) and -report.md. Returns time, grams per filament, purge, colour changes and 'problems'. object_type picks process and settings; auto_adjust adds supports/brim when the geometry needs them; 'settings' (global) always wins. Never prints.

Inputs: objects (required), printer (required), output_dir (required), name, +7 more.

slice_projectA
Idempotent

Slice an existing Bambu Studio project (.3mf, e.g. from MakerWorld) keeping its objects, paint and modifiers, optionally with another process, filaments, settings or even another printer (objects are then re-arranged for the new bed). The original file is never modified.

Inputs: path (required), output_dir (required), name, nozzle, +5 more.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A3.6/5.0

    Scored across 11 tools

    Disambiguation4/5

    Most tools have clearly distinct purposes (analysis, painting, environment, presets). The three slicing tools (slice_model, slice_project, compare_slices) share the core 'slice' action but are differentiated by input source and whether output is saved, so confusion is limited to a single family.

    Naming Consistency5/5

    All eleven tools follow a consistent snake_case verb_noun pattern (list_object_types, analyze_model, slice_model, get_settings, etc.). No mixed conventions or stylistic drift.

    Tool Count5/5

    Eleven tools is well within the ideal 3-15 range for a headless slicer service. Each tool covers a distinct capability (discovery, analysis, slicing, comparison, painting, validation) with no filler.

    Completeness4/5

    The surface covers the full discover-analyze-slice-verify lifecycle: resource listing, geometry analysis, slicing (model and project), variation comparison, painting, environment introspection and self-test. Actual printing is intentionally excluded, and export/preview handling is adequate, leaving only minor gaps.

    Maintenance

    ActivityMaintained
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      Not graded
      quality
      C
      maintenance
      Wraps the OrcaSlicer CLI to enable AI agents to slice 3D models, run parameter sweeps, and analyze G-code.
      124 PyPI
      1
      MIT
    • A
      license
      C
      quality
      C
      maintenance
      Enables AI agents to perform reproducible Snapmaker U1 headless slicing with Snapmaker Orca, including model/profile discovery, STL/3MF-to-G-code slicing, G-code analysis, controlled overrides, and slice or orientation comparisons without GUI automation or printer control.
      33
      1
      MIT
    • A
      license
      Not graded
      quality
      B
      maintenance
      Enables slicing 3MF projects with a local Bambu Studio installation and exploring the resulting toolpaths, layers, print times, and filament usage in an interactive 3D viewer inside ChatGPT.
      AGPL 3.0
    • A
      license
      Not graded
      quality
      C
      maintenance
      Enables plain-English slicing guidance, profile discovery and comparison, 3MF/STL inspection and optimization, headless slicing with cost/time metrics, GUI automation, and live printer/AMS monitoring and control for Bambu Lab 3D printers.
      MIT