opencode/packages/codemode/test/fixtures/openapi-transports.json
opencode-agent[bot] b2e3569add
test(codemode): isolate OpenAPI fixtures (#49667)
Co-authored-by: rekram1-node <rekram1-node@users.noreply.github.com>
2026-09-17 23:01:36 -05:00

148 lines
3.1 KiB
JSON

{
"openapi": "3.1.0",
"info": {
"title": "CodeMode Transport Coverage",
"version": "1.0.0"
},
"paths": {
"/records/{recordID}": {
"get": {
"operationId": "records.get",
"parameters": [
{
"name": "recordID",
"in": "path",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "Record",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/Record"
}
}
}
}
}
}
},
"/events": {
"get": {
"operationId": "events.subscribe",
"responses": {
"200": {
"description": "Events",
"content": {
"text/event-stream": {
"schema": {
"type": "string"
}
}
}
}
}
}
},
"/files/{path}": {
"get": {
"operationId": "files.read",
"parameters": [
{
"name": "path",
"in": "path",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "File",
"content": {
"application/octet-stream": {
"schema": {
"type": "string",
"format": "binary"
}
}
}
}
}
},
"put": {
"operationId": "files.write",
"parameters": [
{
"name": "path",
"in": "path",
"required": true,
"schema": {
"type": "string"
}
}
],
"requestBody": {
"required": true,
"content": {
"application/octet-stream": {
"schema": {
"type": "string",
"format": "binary"
}
}
}
},
"responses": {
"204": {
"description": "Written"
}
}
}
},
"/terminals/{terminalID}/connect": {
"get": {
"operationId": "terminals.connect",
"x-websocket": true,
"parameters": [
{
"name": "terminalID",
"in": "path",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"101": {
"description": "Connected"
}
}
}
}
},
"components": {
"schemas": {
"Record": {
"type": "object",
"properties": {
"id": {
"type": "string"
},
"value": {
"type": "string"
}
},
"required": ["id", "value"],
"additionalProperties": false
}
}
}
}