HTTP Transport
This page describes the current HTTP transport exposed by ss-server.
Routes
POST /rpcGET /healthzPOST /upload/{resource_id}/{file_id}GET /download/{resource_id}/{file_id}
JSON-RPC
POST /rpc expects a full JsonRpcRequestMessage JSON body.
Example:
Regular methods return:
200 OKContent-Type: application/json- a full
JsonRpcResponseMessage
Streaming Responses
session.run_turn still uses POST /rpc, but the response becomes:
200 OKContent-Type: text/event-stream
Rules:
- the first event name is always
ack - all following event names are
message
Binary Upload and Download
Binary routes do not use JSON-RPC envelopes.
- upload bodies are raw bytes
x-file-nameis optional- missing
Content-Typeis normalized toapplication/octet-stream
Current built-in resource files:
character:{character_id}/covercharacter:{character_id}/archivepackage_import:{import_id}/archivepackage_export:{export_id}/archive
POST /upload/{resource_id}/{file_id}
Success response:
200 OKContent-Type: application/json- body:
ResourceFilePayload
Current built-in behavior:
- character cover upload
.chrcharacter import- ZIP upload into a temporary data-package import slot
GET /download/{resource_id}/{file_id}
Success response:
200 OK- raw bytes
Content-Typeset to the logical file type
Current built-in behavior:
- download cover bytes
- export
.chr - download a prepared data-package ZIP
Errors
/rpcparse failures:400 Bad RequestwithErrorPayload- binary routes may return:
400 Bad Request404 Not Found409 Conflict500 Internal Server Error