Create an OpenCode Server
Creates a hosted OpenCode Server in the workspace with a random id. OpenCode’s own settings (models, providers, agents) are managed in OpenCode itself; this resource holds the platform guardrails around it. With an Idempotency-Key, a retry of the same request returns the server it created; the same key on a different request answers 409.
Headers
Body
Response
OpenCode Server created
ACTIVE: serves OpenCode protocol traffic. SUSPENDED: the gateway refuses protocol traffic until it is resumed. DELETED: terminal; the id stays reserved. SUSPENDING, RESUMING and DELETING: a requested change is in progress; its Operation finishes when the server reached the new state. A deletion always finishes.
ACTIVE, SUSPENDING, SUSPENDED, RESUMING, DELETING, DELETED