-
Notifications
You must be signed in to change notification settings - Fork 4
Autotracker API
kbranch edited this page Sep 18, 2024
·
11 revisions
Magpie can communicate with an external autotracker via JSON sent over WebSockets. When autotracking is enabled, the page polls for a server at ws://127.0.0.1:17026/
(or optionally another IP configured in the settings).
All messages include a type
property that indicates the purpose of the message.
All commands are optional, pick and choose what you want to support.
Once connected, Magpie will immediately send a handshake
message.
Messages from Magpie to autotracker:
- handshake - Includes which autotracking features the user has enabled and protocol version
- sendFull - Requests that the autotracker resend everything
- rom - The entire ROM the user is playing, base64 encoded
Messages from autotracker to Magpie:
- handshAck - Acknowledgement of the handshake command
- item - Owned inventory items
- check - Which checks have been checked
- entrance - How entrances are mapped
- location - Link's current coordinates and map
- romRequest - A request for Magpie to send a copy of the ROM
- romAck - Acknowledgement of receipt of a ROM
- settings - The settings used to generate the ROM
- spoiler - The ROM's JSON spoiler log
- gfx - The name of the active graphics pack
- refresh - Tells Magpie to refresh the UI, usually after sending multiple other messages back to back
- alert - Sends Magpie a message to show to the user
- slot_data - Sends Magpie the contents of Archipelago's slot_data, unprocessed
Current protocol version: 1.31
- Added the
alert
command from the autotracker
- ER now includes
:inside
versions of all entrances - Added a
name
parameter to thehandshAck
command
- Added the
flags
parameter to thehandshake
command
- Added the
drawFine
parameter to thelocation
command
- Added the
handshAck
command - Added the
sendFull
command - Only the
handshake
andhandshAck
commands include the protocol version now