Rig and animate 3D models from Claude Code with the afk-rig MCP server
Don't have your coding agent hand-build bones and skin weights. Add the afk-rig MCP server and Claude Code rigs a character, an animal or a prop in one tool call, with every animation for its body type.
October 25, 2026
Ask an AI coding agent to "rig this model and make it walk" and it will usually try to do the whole thing itself: write a Blender Python script that places bones, run automatic weights, keyframe a walk cycle, render a frame to check it, and go round again when something looks wrong. Sometimes that works. Often it burns a long session and still hands you a character whose knees bend the wrong way.
The afk-rig MCP server gives the agent a better option: one tool that sends the model to afk.ai's AI rigger and writes back a rigged GLB with a skeleton, skin weights and every animation for its body type. The agent spends its effort on the part it's good at, which is wiring the result into your game.
Why hand-rigging is hard for an agent
Rigging looks like a coding task, but most of it is judgment about a shape the agent can't see well.
- It can't see the mesh. An agent works from vertex coordinates and bounding boxes, so it guesses where the shoulders, hips and knees are. On a stylized character, a dog or a dragon, those guesses are often off, and a joint in the wrong place ruins every animation after it.
- Skin weights are the hard part. Blender's automatic weights fail on many real-world meshes, the ones with separate parts, holes or overlapping pieces, with "Bone Heat Weighting: failed to find solution for one or more bones". The agent then loops on mesh fixes it can't check by eye.
- Animations are made one keyframe at a time. A believable walk, a run and an idle for a horse is a lot of keyframes to get right without watching them. Every new body type starts from zero.
- Every attempt costs time and tokens, and two runs on the same model rarely give the same result.
What the afk-rig tool does instead
afk-rig hands the model to the same rigger as afk.ai/rig. An AI trained to find body parts places a skeleton made for that kind of body, the skin weights come from a process tuned on a wide range of models, and the animations were made for that exact skeleton, so they fit without retargeting. The agent makes one tool call and gets a finished file back.
| The agent rigs it by hand | The agent calls afk-rig | |
|---|---|---|
| Work | Scripts, test renders and fixes, often many rounds | One tool call |
| Time | Anything from minutes to a long session | Usually 30 seconds to a minute |
| Skeleton | Guessed from coordinates | Placed by a model trained to find body parts |
| Skin weights | Automatic weights, which fail on many meshes | Tuned for real-world meshes |
| Animations | Keyframed by hand, one at a time | Up to 172 for a human, 6 to 19 for every other body type |
| Body types | Whatever the script handles | People, animals, birds, dragons, dinosaurs, spiders, snakes, fish, kangaroos, frogs, ghosts and objects |
Set it up
Make an API key on the developer dashboard, then add the server to Claude Code:
claude mcp add afk-rig -e AFK_API_KEY=afk_... -- npx -y afk-rig mcp
For Cursor and other MCP clients, add it to mcp.json:
{
"mcpServers": {
"afk-rig": { "command": "npx", "args": ["-y", "afk-rig", "mcp"], "env": { "AFK_API_KEY": "afk_..." } }
}
}
The server gives the agent four tools:
rig_modelrigs a model file and writes the rigged .glb with its animationslist_body_typeslists the body types and each one's animationsget_accountshows what's left on your accountrig_statuschecks on a rig started somewhere else (rig_modelwaits for its own)
Things to ask it
Once it's added, you ask in plain language and the agent picks the tool and its options:
- "Rig
models/knight.glbas a human and load it in the three.js scene with the Walk animation playing." - "Rig
models/wolf.glbas a four-legged animal with only Idle, Walk and Run, then make a Godot scene that switches between them." - "Rig every .glb in
assets/propsas an object with Bounce and Spin, and use them for the coin and gem pickups." - "What animations does the dragon type have? Rig
dragon.glbwith the flying ones and set up an AnimationPlayer for them." - "Rig
horse.glb, then import it into Unity as a Generic rig and build an animator controller with Walk, Trot and Run."
Let the agent do the rest
Rigging is where an agent wastes the most effort for the least result. Wiring is where it shines: writing the three.js AnimationMixer code, the Godot AnimationPlayer setup, a Unity animator controller, blending between clips, or a script that rigs every model a level needs. Let afk-rig make the rigged file and let the agent build everything around it.
For what the API can rig, objects included, see what you can build with the afk.ai rigging API.
Questions
Does the MCP server work with clients other than Claude Code?
Yes. It's a standard MCP server on stdio (npx afk-rig mcp), so Cursor, Windsurf, Claude Desktop and other MCP clients can run it with the same command and an AFK_API_KEY in its environment.
Where does the rigging happen?
On afk.ai's servers. The tool uploads the model, waits for the rig and writes the finished .glb to your project. Every model goes through an adult-content check first, and one it turns down fails.
Which models can it rig?
GLB, glTF with embedded buffers, or FBX, up to 80 MB, without Draco or meshopt compression. Pick the body type that matches the model: human, fox (four-legged animals), horse (hoofed animals), bird, dragon, kaiju (dinosaurs), spider, snake, fish, kangaroo, frog, ghost or object.
Can I use the rigged models commercially?
Yes. The skeletons and animations are CC0, and your model stays yours.
Rig models from code
Every animation for the body type, in one GLB, from your terminal, your code or your AI agent.