Transformice Api -

tfm.exec.giveCheese() : Instantly awards cheese to a specific mouse.

Transformice is a flash-turned-HTML5 multiplayer puzzle-platformer. Atelier 801 has never released an official external API. However, the game operates over a (XMLSocket/WebSocket) using a proprietary text-based protocol. Community developers have reverse-engineered this protocol to create:

: Shaman saves, gathered cheese, completed maps, and historical rank data.

Using the API, developers can programmatically access a wide array of information: transformice api

If you need official game data integration, contact Atelier 801 for partnership (rarely granted). For hobby projects, use the documented WebSocket patterns with respect for the game's fair play policies.

The term "Transformice API" generally refers to a combination of official data endpoints provided by Atelier 801 and community-maintained wrappers designed to parse raw game data. Unlike modern web games that offer standard RESTful JSON APIs, Transformice natively utilizes custom binary socket connections for live gameplay and specific web-based endpoints for static data retrieval. Community developers use these pathways to access:

Atelier 801 exposes raw data via specific web URLs, often used to feed the official standalone forums and profile pages. These endpoints return structured text or XML data containing player IDs, registration dates, and basic profile info. Developers cache this data to build external leaderboard websites. 2. Socket-Based Connections (Live Data & Bots) For hobby projects, use the documented WebSocket patterns

It sends and receives "packets" (encoded data) to simulate a player's actions. 3. Data APIs (External Stats)

-- Simple entry point: Spawn a piece of cheese when a round begins function eventNewGame() local roomData = tfm.get.room print("Now playing on map code: " .. roomData.currentMap) end Use code with caution. 2. Event-Driven Programming Model

The engine operates on an asynchronous, event-driven pattern. Instead of utilizing long-running infinite loops, your script registers specific hook functions that the game server invokes when standard user behaviors occur. Crucial Event Triggers minimal server implementation

eventChatCommand : Triggers when a player types a message starting with ! . eventKeyboard : Captures player keystrokes and positions.

Never hardcode your main account credentials into public open-source repositories. Use environment variables ( .env ) to store login tokens and passwords securely. It is highly recommended to use a dedicated "throwaway" alternative account for your automated bots.

To interact with Transformice data outside of the game client, you need a modern backend environment. Python and Node.js are the most popular choices due to their strong socket handling capabilities. Prerequisites (v16+) or Python (3.9+) A text editor (like VS Code) Basic knowledge of TCP sockets and asynchronous programming Installing Dependencies

— An asynchronous Transformice networking library that includes packet definitions, client implementation, minimal server implementation, and proxy tools. While documentation is sparse, the library is actively maintained, with Discord support available.