Fix build stamp visibility, add create world UI, and add Save as New World to editor
checkpoint / checkpoint (push) Successful in 5m54s
checkpoint / checkpoint (push) Successful in 5m54s
This commit is contained in:
@@ -247,6 +247,19 @@ func get_worlds(skip: int = 0, limit: int = 50, visibility: String = "") -> Dict
|
||||
return await request(HTTPClient.METHOD_GET, path, "", "application/json", true)
|
||||
|
||||
|
||||
## Create a new world owned by the current user (requires auth).
|
||||
## On success, result.data is the created World object containing {"id", "name", ...}.
|
||||
func create_world(world_name: String, description: String = "", visibility: String = "public", category: String = "Building", tags: Array = []) -> Dictionary:
|
||||
var payload: Dictionary = {
|
||||
"name": world_name,
|
||||
"description": description,
|
||||
"visibility": visibility,
|
||||
"category": category,
|
||||
"tags": tags,
|
||||
}
|
||||
return await request(HTTPClient.METHOD_POST, "/api/worlds/", JSON.stringify(payload), "application/json", true)
|
||||
|
||||
|
||||
## Ping the backend health endpoint (no auth).
|
||||
func health_check() -> Dictionary:
|
||||
return await request(HTTPClient.METHOD_GET, "/api/health", "", "application/json", false)
|
||||
|
||||
Reference in New Issue
Block a user