Warps
Base: /api/warps
Manage teleportation points (create, list, delete, teleport)
Handler: WarpHandler
Endpoints
GET
/api/warps
List Warps
List of all saved warp points.
Response Example
[{"name":"spawn","x":0.0,"y":64.0,"z":0.0,"world":"overworld","created_by":"Admin"},{"name":"arena","x":500.0,"y":70.0,"z":-100.0,"world":"overworld","created_by":"Admin"}]
cURL
curl http://localhost:5550/api/warps
POST
/api/warps/create
Create Warp
Creates a new warp point.
Request Body
| Field | Type | Required | Description |
|---|---|---|---|
name
|
string | Yes | Warp name |
x
|
number | Yes | X coordinate |
y
|
number | Yes | Y coordinate |
z
|
number | Yes | Z coordinate |
world
|
string | No | World (default: overworld) |
Response Example
{"success":true,"message":"Warp arena created"}
cURL
curl -X POST http://localhost:5550/api/warps/create \
-H 'Content-Type: application/json' \
-d '{"name":"arena","x":500,"y":70,"z":-100}'
Internal Behavior
Warp is immediately saved to data/warps.json.
DELETE
/api/warps/{name}
Delete Warp
Deletes a warp point.
Parameter
| Name | Type | Required | Description |
|---|---|---|---|
name
|
string | Yes | Warp name |
Response Example
{"success":true,"message":"Warp arena deleted"}
cURL
curl -X DELETE http://localhost:5550/api/warps/arena
POST
/api/warps/{name}/teleport/{player}
Teleport Player to Warp
Teleports a player to a warp point.
Parameter
| Name | Type | Required | Description |
|---|---|---|---|
name
|
string | Yes | Warp name |
player
|
string | Yes | Player name |
Response Example
{"success":true,"message":"Player Steve teleported to warp spawn"}
cURL
curl -X POST http://localhost:5550/api/warps/spawn/teleport/Steve