From 2c5b539acf208ffc9021dc23ff96b1636806a104 Mon Sep 17 00:00:00 2001 From: Christian Gleissner Date: Fri, 5 Jun 2026 18:06:40 +0100 Subject: [PATCH 1/5] Add menu screen and input endpoints to OpenAPI specification --- Ultimate_OpenAPI_specs.yaml | 317 ++++++++++++++++++ u2plus-open-api-spec.yaml | 641 ++++++++++++++++++++++-------------- 2 files changed, 709 insertions(+), 249 deletions(-) diff --git a/Ultimate_OpenAPI_specs.yaml b/Ultimate_OpenAPI_specs.yaml index 9fd990e..32845f9 100644 --- a/Ultimate_OpenAPI_specs.yaml +++ b/Ultimate_OpenAPI_specs.yaml @@ -17,6 +17,226 @@ components: in: header name: X-Password description: "The API password, if one is configured in the Network Settings." + schemas: + Errors: + type: object + required: [ errors ] + properties: + errors: + type: array + items: + type: string + MenuScreenBytes: + type: string + format: binary + description: | + Exactly 2000 bytes. Bytes 0..999 are the 40x25 firmware UI character + matrix. Bytes 1000..1999 are the matching 40x25 colour-attribute + matrix. Both matrices are row-major: offset = row * 40 + column. + In each colour-attribute byte, bits 0..3 are the foreground colour + and bits 4..7 are the background colour. + minLength: 2000 + maxLength: 2000 + InputTransition: + type: string + enum: + - press + - release + - tap + KeyboardInputName: + type: string + enum: + - inst_del + - return + - cursor_left_right + - f7 + - f1 + - f3 + - f5 + - cursor_up_down + - "0" + - "1" + - "2" + - "3" + - "4" + - "5" + - "6" + - "7" + - "8" + - "9" + - a + - b + - c + - d + - e + - f + - g + - h + - i + - j + - k + - l + - m + - "n" + - o + - p + - q + - r + - s + - t + - u + - v + - w + - x + - y + - z + - left_shift + - right_shift + - plus + - minus + - period + - colon + - at + - comma + - pound + - star + - semicolon + - clr_home + - equals + - arrow_up + - slash + - arrow_left + - ctrl + - space + - commodore + - run_stop + - restore + description: | + REST input name from the C64 keyboard matrix. `restore` is special: + firmware accepts it only as the sole input in a keyboard event with + transition `tap`. + JoystickInputName: + type: string + enum: + - up + - down + - left + - right + - fire + - fire2 + - fire3 + KeyboardInputEvent: + type: object + additionalProperties: false + required: + - kind + - inputs + - transition + properties: + kind: + type: string + const: keyboard + inputs: + type: array + minItems: 1 + maxItems: 8 + uniqueItems: true + items: + $ref: '#/components/schemas/KeyboardInputName' + transition: + $ref: '#/components/schemas/InputTransition' + JoystickInputEvent: + type: object + additionalProperties: false + required: + - kind + - port + - inputs + - transition + properties: + kind: + type: string + const: joystick + port: + type: integer + enum: + - 1 + - 2 + inputs: + type: array + minItems: 1 + maxItems: 7 + uniqueItems: true + items: + $ref: '#/components/schemas/JoystickInputName' + transition: + $ref: '#/components/schemas/InputTransition' + ReleaseAllInputEvent: + type: object + additionalProperties: false + required: + - kind + properties: + kind: + type: string + const: release_all + InputEvent: + oneOf: + - $ref: '#/components/schemas/KeyboardInputEvent' + - $ref: '#/components/schemas/JoystickInputEvent' + - $ref: '#/components/schemas/ReleaseAllInputEvent' + InputRequest: + type: object + additionalProperties: false + required: + - events + properties: + events: + type: array + minItems: 1 + maxItems: 64 + items: + $ref: '#/components/schemas/InputEvent' + KeyboardInputState: + type: object + required: + - inputs + properties: + inputs: + type: array + items: + $ref: '#/components/schemas/KeyboardInputName' + JoystickInputState: + type: object + required: + - port + - inputs + properties: + port: + type: integer + enum: + - 1 + - 2 + inputs: + type: array + items: + $ref: '#/components/schemas/JoystickInputName' + InputStateResponse: + allOf: + - $ref: '#/components/schemas/Errors' + - type: object + required: + - keyboard + - joysticks + properties: + keyboard: + $ref: '#/components/schemas/KeyboardInputState' + joysticks: + type: array + minItems: 2 + maxItems: 2 + items: + $ref: '#/components/schemas/JoystickInputState' security: - passwordHeader: [] tags: @@ -253,6 +473,103 @@ paths: responses: '200': description: "OK" + /machine:menu_screen: + get: + tags: + - Machine Control + summary: Read active firmware menu screen + description: | + Returns the active 40x25 firmware menu text-mode screen as two raw + matrices. The first 1000 bytes are character bytes; the second 1000 + bytes are colour-attribute bytes. This endpoint is intended to be used + with `/v1/machine:menu_button` and `/v1/machine:input` to drive and + inspect the firmware menu over REST. + operationId: machine_menu_screen + responses: + '200': + description: Readable 40x25 menu screen returned + headers: + Content-Length: + schema: + type: integer + const: 2000 + content: + application/octet-stream: + schema: + $ref: '#/components/schemas/MenuScreenBytes' + '404': + description: No readable menu screen is currently available + content: + application/json: + schema: + allOf: + - $ref: '#/components/schemas/Errors' + examples: + unavailable: + value: + errors: + - Menu screen unavailable. + /machine:input: + get: + tags: + - Machine Control + summary: Get REST-injected input state + description: Returns the currently active keyboard and joystick inputs injected through the REST input endpoint. Ultimate 64-class input hardware is required; on Ultimate-II+ hardware this returns HTTP 501. + operationId: machine_input_get + responses: + '200': + description: Input state returned + content: + application/json: + schema: + $ref: '#/components/schemas/InputStateResponse' + '501': + description: Keyboard and joystick injection are not available on this hardware + content: + application/json: + schema: + allOf: + - $ref: '#/components/schemas/Errors' + post: + tags: + - Machine Control + summary: Inject keyboard and joystick input + description: | + Applies a validated batch of keyboard, joystick, and release-all events, + then returns the resulting input state. The firmware validates the + complete batch before applying any event; invalid batches return HTTP + 400 and leave the current input state unchanged. When the firmware menu + is active, keyboard events are translated to menu keystrokes. + Ultimate 64-class input hardware is required; on Ultimate-II+ hardware + this returns HTTP 501. + operationId: machine_input_post + requestBody: + required: true + content: + application/json: + schema: + $ref: '#/components/schemas/InputRequest' + responses: + '200': + description: Events applied + content: + application/json: + schema: + $ref: '#/components/schemas/InputStateResponse' + '400': + description: Invalid body, content type, or event batch + content: + application/json: + schema: + allOf: + - $ref: '#/components/schemas/Errors' + '501': + description: Keyboard and joystick injection are not available on this hardware + content: + application/json: + schema: + allOf: + - $ref: '#/components/schemas/Errors' /machine:reset: put: tags: diff --git a/u2plus-open-api-spec.yaml b/u2plus-open-api-spec.yaml index 79542b9..e319c36 100644 --- a/u2plus-open-api-spec.yaml +++ b/u2plus-open-api-spec.yaml @@ -24,7 +24,7 @@ paths: tags: - About responses: - '200': + "200": description: Successful operation. content: application/json: @@ -36,16 +36,32 @@ paths: "errors": [ ] } schema: - allOf: - - $ref: '#/components/schemas/Errors' - type: object - properties: - version: - type: string - '404': + $ref: "#/components/schemas/VersionResponse" + "404": description: Not Found - '504': + "504": description: Gateway Timeout + /info: + get: + operationId: getInfo + summary: Get device information + description: Returns hardware metadata (product, firmware version, FPGA/core versions, hostname). Available on Ultimate firmware 3.12 and newer. On earlier releases the endpoint responds with HTTP 404. + tags: + - About + responses: + "200": + description: Successful operation. + content: + application/json: + schema: + $ref: "#/components/schemas/InfoResponse" + "404": + description: Not Found + content: + application/json: + schema: + allOf: + - $ref: "#/components/schemas/Errors" /machine:reset: put: operationId: resetMachine @@ -54,14 +70,14 @@ paths: tags: - Machine operations responses: - '200': + "200": description: Successful operation. content: application/json: schema: allOf: - - $ref: '#/components/schemas/Errors' - '404': + - $ref: "#/components/schemas/Errors" + "404": description: Not Found /machine:reboot: put: @@ -71,14 +87,14 @@ paths: tags: - Machine operations responses: - '200': + "200": description: Successful operation. content: application/json: schema: allOf: - - $ref: '#/components/schemas/Errors' - '404': + - $ref: "#/components/schemas/Errors" + "404": description: Not Found /machine:pause: put: @@ -90,14 +106,14 @@ paths: tags: - Machine operations responses: - '200': + "200": description: Successful operation. content: application/json: schema: allOf: - - $ref: '#/components/schemas/Errors' - '404': + - $ref: "#/components/schemas/Errors" + "404": description: Not Found /machine:resume: put: @@ -107,17 +123,17 @@ paths: tags: - Machine operations responses: - '200': + "200": description: Successful operation. content: application/json: schema: allOf: - - $ref: '#/components/schemas/Errors' - '404': + - $ref: "#/components/schemas/Errors" + "404": description: Not Found content: - application/json: { } + application/json: {} /machine:poweroff: put: operationId: powerOffMachine @@ -128,15 +144,153 @@ paths: tags: - Machine operations responses: - '200': + "200": description: Successful operation. content: application/json: schema: allOf: - - $ref: '#/components/schemas/Errors' - '404': + - $ref: "#/components/schemas/Errors" + "404": description: Not Found + /machine:menu_button: + put: + operationId: toggleMenuButton + summary: Toggle Ultimate menu button + description: Toggles the Ultimate firmware menu, equivalent to pressing the physical menu button. If the menu is closed it opens; if the menu is open it closes. + tags: + - Machine operations + responses: + "200": + description: Button event queued + content: + application/json: + schema: + allOf: + - $ref: "#/components/schemas/Errors" + /machine:menu_screen: + get: + operationId: getMenuScreen + summary: Read active firmware menu screen + description: | + Returns the active 40x25 firmware menu text-mode screen as two raw + matrices. The first 1000 bytes are character bytes; the second 1000 + bytes are colour-attribute bytes. This endpoint is intended to be used + with `/v1/machine:menu_button` and `/v1/machine:input` to drive and + inspect the firmware menu over REST. + tags: + - Machine operations + responses: + "200": + description: Readable 40x25 menu screen returned + headers: + Content-Length: + schema: + type: integer + const: 2000 + content: + application/octet-stream: + schema: + $ref: "#/components/schemas/MenuScreenBytes" + "404": + description: No readable menu screen is currently available + content: + application/json: + schema: + allOf: + - $ref: "#/components/schemas/Errors" + examples: + unavailable: + value: + errors: + - Menu screen unavailable. + /machine:input: + get: + operationId: getInputState + summary: Get REST-injected input state + description: Returns the currently active keyboard and joystick inputs injected through the REST input endpoint. Ultimate 64-class input hardware is required; on Ultimate-II+ hardware this returns HTTP 501. + tags: + - Machine operations + responses: + "200": + description: Input state returned + content: + application/json: + schema: + $ref: "#/components/schemas/InputStateResponse" + examples: + empty: + value: + keyboard: + inputs: [] + joysticks: + - port: 1 + inputs: [] + - port: 2 + inputs: [] + errors: [] + "501": + description: Keyboard and joystick injection are not available on this hardware + content: + application/json: + schema: + allOf: + - $ref: "#/components/schemas/Errors" + post: + operationId: injectInput + summary: Inject keyboard and joystick input + description: | + Applies a validated batch of keyboard, joystick, and release-all events, + then returns the resulting input state. The firmware validates the + complete batch before applying any event; invalid batches return HTTP + 400 and leave the current input state unchanged. When the firmware menu + is active, keyboard events are translated to menu keystrokes. + Ultimate 64-class input hardware is required; on Ultimate-II+ hardware + this returns HTTP 501. + tags: + - Machine operations + requestBody: + required: true + content: + application/json: + schema: + $ref: "#/components/schemas/InputRequest" + examples: + shifted_key_and_joystick: + value: + events: + - kind: joystick + port: 2 + inputs: + - up + - fire + transition: press + - kind: keyboard + inputs: + - left_shift + - a + transition: tap + responses: + "200": + description: Events applied + content: + application/json: + schema: + $ref: "#/components/schemas/InputStateResponse" + "400": + description: Invalid body, content type, or event batch + content: + application/json: + schema: + allOf: + - $ref: "#/components/schemas/Errors" + "501": + description: Keyboard and joystick injection are not available on this hardware + content: + application/json: + schema: + allOf: + - $ref: "#/components/schemas/Errors" /machine:readmem: get: operationId: readMemory @@ -169,11 +323,11 @@ paths: minimum: 0 example: 128 responses: - '200': + "200": description: Successful operation. content: application/octet-stream: {} - '400': + "400": description: Bad request content: application/json: @@ -195,8 +349,8 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '404': + - $ref: "#/components/schemas/Errors" + "404": description: Not Found /machine:writemem: put: @@ -206,7 +360,7 @@ paths: With this command, data can be written to C64 memory. To be more exact: this command writes data through DMA, so the memory map that is currently selected is used. Writing to the I/O registers of the 6510 is not possible. - + Data bytes are written in consecutive memory locations. The address argument specifies the memory location in hexadecimal format. The data argument contains a string of bytes in hexadecimal format. The maximum number of bytes written with this method is 128. @@ -233,7 +387,7 @@ paths: type: string example: "1024" responses: - '200': + "200": description: Successful operation. content: application/json: @@ -246,8 +400,8 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '400': + - $ref: "#/components/schemas/Errors" + "400": description: Bad request content: application/json: @@ -264,8 +418,8 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '404': + - $ref: "#/components/schemas/Errors" + "404": description: Not Found post: operationId: writeManyDataToMemoryPost @@ -273,7 +427,7 @@ paths: description: |- With this command, data can be written to C64 memory. The data, passed as a binary attachment, will be written to memory starting from the location indicated by the address argument, which shall be formatted in hexadecimal. - + The data should not wrap around $FFFF. tags: - Machine operations @@ -291,7 +445,7 @@ paths: application/octet-stream: schema: {} responses: - '200': + "200": description: Successful operation. content: application/json: @@ -304,8 +458,8 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '400': + - $ref: "#/components/schemas/Errors" + "400": description: Bad request content: application/json: @@ -322,8 +476,8 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '404': + - $ref: "#/components/schemas/Errors" + "404": description: Not Found /machine:debugreg: get: @@ -335,7 +489,7 @@ paths: tags: - Machine operations responses: - '200': + "200": description: Successful operation. content: application/json: @@ -348,8 +502,8 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '404': + - $ref: "#/components/schemas/Errors" + "404": description: Not Found put: operationId: writeDebugRegister @@ -370,7 +524,7 @@ paths: type: string example: "3F" responses: - '200': + "200": description: Successful operation. content: application/json: @@ -383,8 +537,8 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '404': + - $ref: "#/components/schemas/Errors" + "404": description: Not Found /runners:sidplay: put: @@ -413,7 +567,7 @@ paths: schema: type: string responses: - '200': + "200": description: Successful operation. content: application/json: @@ -430,10 +584,10 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '404': + - $ref: "#/components/schemas/Errors" + "404": description: Not Found - '500': + "500": description: Internal server error content: application/json: @@ -465,7 +619,7 @@ paths: application/octet-stream: schema: {} responses: - '200': + "200": description: Successful operation. content: application/json: @@ -482,10 +636,10 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '404': + - $ref: "#/components/schemas/Errors" + "404": description: Not Found - '500': + "500": description: Internal server error content: application/json: @@ -495,7 +649,7 @@ paths: { "errors" : [ "Undefined subsystem command" ] } - '507': + "507": description: Unknown content: application/json: @@ -523,7 +677,7 @@ paths: schema: type: string responses: - '200': + "200": description: Successful operation. content: application/json: @@ -540,10 +694,10 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '404': + - $ref: "#/components/schemas/Errors" + "404": description: Not Found - '500': + "500": description: Internal server error content: application/json: @@ -553,7 +707,7 @@ paths: { "errors" : [ "Undefined subsystem command" ] } - '507': + "507": description: Unknown content: application/json: @@ -575,7 +729,7 @@ paths: application/octet-stream: schema: {} responses: - '200': + "200": description: Successful operation. content: application/json: @@ -593,10 +747,10 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '404': + - $ref: "#/components/schemas/Errors" + "404": description: Not Found - '500': + "500": description: Internal server error content: application/json: @@ -606,7 +760,7 @@ paths: { "errors" : [ "Undefined subsystem command" ] } - '507': + "507": description: Unknown content: application/json: @@ -635,7 +789,7 @@ paths: schema: type: string responses: - '200': + "200": description: Successful operation. content: application/json: @@ -652,10 +806,10 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '404': + - $ref: "#/components/schemas/Errors" + "404": description: Not Found - '500': + "500": description: Internal server error content: application/json: @@ -665,7 +819,7 @@ paths: { "errors" : [ "Undefined subsystem command" ] } - '507': + "507": description: Unknown content: application/json: @@ -688,7 +842,7 @@ paths: application/octet-stream: schema: {} responses: - '200': + "200": description: Successful operation. content: application/json: @@ -706,10 +860,10 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '404': + - $ref: "#/components/schemas/Errors" + "404": description: Not Found - '500': + "500": description: Internal server error content: application/json: @@ -719,7 +873,7 @@ paths: { "errors" : [ "Undefined subsystem command" ] } - '507': + "507": description: Unknown content: application/json: @@ -748,7 +902,7 @@ paths: schema: type: string responses: - '200': + "200": description: Successful operation. content: application/json: @@ -761,10 +915,10 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '404': + - $ref: "#/components/schemas/Errors" + "404": description: Not Found - '500': + "500": description: Internal server error content: application/json: @@ -774,7 +928,7 @@ paths: { "errors" : [ "Undefined subsystem command" ] } - '507': + "507": description: Unknown content: application/json: @@ -795,15 +949,15 @@ paths: requestBody: content: application/octet-stream: - schema: { } + schema: {} responses: - '200': + "200": description: Successful operation. content: application/json: schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" examples: OK: value: |- @@ -815,9 +969,9 @@ paths: { "errors" : [ "Function run_prg does not have parameter invalidParameterName", "Function run_prg requires parameter file" ] } - '404': + "404": description: Not Found - '500': + "500": description: Internal server error content: application/json: @@ -827,7 +981,7 @@ paths: { "errors" : [ "Undefined subsystem command" ]x } - '507': + "507": description: Unknown content: application/json: @@ -856,7 +1010,7 @@ paths: schema: type: string responses: - '200': + "200": description: Successful operation. content: application/json: @@ -873,10 +1027,10 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '404': + - $ref: "#/components/schemas/Errors" + "404": description: Not Found - '500': + "500": description: Internal server error content: application/json: @@ -886,7 +1040,7 @@ paths: { "errors" : [ "Undefined subsystem command" ] } - '507': + "507": description: Unknown content: application/json: @@ -907,9 +1061,9 @@ paths: requestBody: content: application/octet-stream: - schema: { } + schema: {} responses: - '200': + "200": description: Successful operation. content: application/json: @@ -927,10 +1081,10 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '404': + - $ref: "#/components/schemas/Errors" + "404": description: Not Found - '500': + "500": description: Internal server error content: application/json: @@ -940,7 +1094,7 @@ paths: { "errors" : [ "Undefined subsystem command" ] } - '507': + "507": description: Unknown content: application/json: @@ -961,7 +1115,7 @@ paths: tags: - Floppy drives responses: - '200': + "200": description: Successful operation. content: application/json: @@ -1013,6 +1167,8 @@ paths: ], "errors": [] } + schema: + $ref: "#/components/schemas/DriveListResponse" /drives/{drive}:mount: put: operationId: putMountDiskImage @@ -1051,7 +1207,7 @@ paths: The type or format of the disk image.
Valid options are one of the following:
`d64`, `g64`, `d71`, `g71` or `d81` - + When this parameter is omitted, then the API will look at the file extension. name: type required: false @@ -1069,7 +1225,7 @@ paths: schema: type: string responses: - '200': + "200": description: Successful operation. content: application/json: @@ -1090,8 +1246,8 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '400': + - $ref: "#/components/schemas/Errors" + "400": description: Bad Request content: application/json: @@ -1106,9 +1262,9 @@ paths: { "errors" : [ "Invalid Type 'd65'" ] } - '404': + "404": description: Not Found - '500': + "500": description: Internal server error content: application/json: @@ -1118,7 +1274,7 @@ paths: { "errors" : [ "Undefined subsystem command" ] } - '507': + "507": description: Unknown content: application/json: @@ -1158,7 +1314,7 @@ paths: The type or format of the disk image.
Valid options are one of the following:
`d64`, `g64`, `d71`, `g71` or `d81` - + When this parameter is omitted, then the API will look at the file extension. name: type required: false @@ -1176,9 +1332,9 @@ paths: requestBody: content: application/octet-stream: - schema: { } + schema: {} responses: - '200': + "200": description: Successful operation. content: application/json: @@ -1195,8 +1351,8 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '400': + - $ref: "#/components/schemas/Errors" + "400": description: Bad Request content: application/json: @@ -1206,9 +1362,9 @@ paths: { "errors": [ "Invalid Drive 'c'" ] } - '404': + "404": description: Not Found - '500': + "500": description: Internal server error content: application/json: @@ -1223,7 +1379,7 @@ paths: { 'errors': ['Read operation on file failed'] } - '507': + "507": description: Unknown content: application/json: @@ -1252,7 +1408,7 @@ paths: Valid options are one of the following:
`a`, `b` responses: - '200': + "200": description: Successful operation. content: application/json: @@ -1264,8 +1420,8 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '400': + - $ref: "#/components/schemas/Errors" + "400": description: Bad Request content: application/json: @@ -1277,7 +1433,7 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" /drives/{drive}:remove: put: operationId: putRemoveDisk @@ -1297,7 +1453,7 @@ paths: Valid options are one of the following:
`a`, `b` responses: - '200': + "200": description: Successful operation. content: application/json: @@ -1309,8 +1465,8 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '400': + - $ref: "#/components/schemas/Errors" + "400": description: Bad Request content: application/json: @@ -1322,7 +1478,7 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" /drives/{drive}:unlink: put: operationId: putUnlinkDisk @@ -1343,7 +1499,7 @@ paths: Valid options are one of the following:
`a`, `b` responses: - '200': + "200": description: Successful operation. content: application/json: @@ -1355,8 +1511,8 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '400': + - $ref: "#/components/schemas/Errors" + "400": description: Bad Request content: application/json: @@ -1368,7 +1524,7 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" /drives/{drive}:on: put: operationId: putUnEnableDrive @@ -1388,7 +1544,7 @@ paths: Valid options are one of the following:
`a`, `b` responses: - '200': + "200": description: Successful operation. content: application/json: @@ -1400,8 +1556,8 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '400': + - $ref: "#/components/schemas/Errors" + "400": description: Bad Request content: application/json: @@ -1413,7 +1569,7 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" /drives/{drive}:off: put: operationId: putDisableDrive @@ -1430,11 +1586,11 @@ paths: required: true description: |- Disables disk drive `a` or `b`. It will no longer be accessible on the serial bus. - + Valid options are one of the following:
`a`, `b` responses: - '200': + "200": description: Successful operation. content: application/json: @@ -1446,8 +1602,8 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '400': + - $ref: "#/components/schemas/Errors" + "400": description: Bad Request content: application/json: @@ -1459,7 +1615,7 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" /drives/{drive}:load_rom: put: operationId: putLoadDriveRom @@ -1468,7 +1624,7 @@ paths: Loads a new disk drive ROM into the selected drive.
The `file` parameter points to a file that is already present on the file system of the Ultimate. The size of the ROM file needs to be 16K or 32K, depending on the drive type. - + Loading the ROM is a temporary action, setting the drive type or rebooting the machine will load the default ROM. tags: @@ -1482,7 +1638,7 @@ paths: description: |- Load a new drive ROM in drive `a` or `b`. The size of the ROM file needs to be 16K or 32K, depending on the drive type. - + Valid options are one of the following:
`a`, `b` - in: query @@ -1493,7 +1649,7 @@ paths: schema: type: string responses: - '200': + "200": description: Successful operation. content: application/json: @@ -1505,8 +1661,8 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '400': + - $ref: "#/components/schemas/Errors" + "400": description: Bad Request content: application/json: @@ -1518,7 +1674,7 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" post: operationId: postLoadRom summary: Load disk drive rom @@ -1526,7 +1682,7 @@ paths: With this command a new drive ROM can be loaded into the selected drive. The ROM file is passed as a binary file attachment to the POST request.
The size of the ROM file needs to be 16K or 32K, depending on the drive type. - + Loading the ROM is a temporary action, setting the drive type or rebooting the machine will load the default ROM. tags: - Floppy drives @@ -1539,7 +1695,7 @@ paths: description: |- Load a new drive ROM in drive `a` or `b`. The size of the ROM file needs to be 16K or 32K, depending on the drive type. - + Valid options are one of the following:
`a`, `b` requestBody: @@ -1547,7 +1703,7 @@ paths: application/octet-stream: schema: {} responses: - '200': + "200": description: Successful operation. content: application/json: @@ -1559,8 +1715,8 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '400': + - $ref: "#/components/schemas/Errors" + "400": description: Bad Request content: application/json: @@ -1572,14 +1728,14 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" /drives/{drive}:set_mode: put: operationId: postSetMode summary: Set or update disk image mode description: | Change the drive mode. - + Note that this command will also load the drive ROM. A temporary ROM that was loaded using the ‘load_rom’ command will be lost. tags: @@ -1594,17 +1750,17 @@ paths: Valid options are one of the following:
`a`, `b` - in: query - name: mod + name: mode schema: type: string + enum: + - "1541" + - "1571" + - "1581" required: true - description: The available values are `1541`, `1571` and `1581`. - requestBody: - content: - application/octet-stream: - schema: {} + description: The available values are `1541`, `1571` and `1581`. responses: - '200': + "200": description: Successful operation. content: application/json: @@ -1616,8 +1772,8 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '400': + - $ref: "#/components/schemas/Errors" + "400": description: Bad Request content: application/json: @@ -1629,7 +1785,7 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" /streams/{streamname}:start: put: operationId: putStartDataStream @@ -1640,7 +1796,7 @@ paths: U64 to know where to send the stream to. The default port number that the data stream is sent to is 11000 for the video stream, 11001 for the audio stream and 11002 for the debug stream. - + A custom port number can be added to the IP address, after a colon separator; e.g. 192.168.178.224:6789 . Note that turning on the video stream will automatically turn off the debug stream. @@ -1668,7 +1824,7 @@ paths: type: string default: video responses: - '200': + "200": description: Successful operation. content: application/json: @@ -1680,8 +1836,8 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '400': + - $ref: "#/components/schemas/Errors" + "400": description: Bad Request content: application/json: @@ -1702,25 +1858,19 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '404': + - $ref: "#/components/schemas/Errors" + "404": description: Not Found content: application/json: examples: "Network Host Resolve Error": - value: - { - "errors": [ "Network Host Resolve Error" ] - } + value: { "errors": ["Network Host Resolve Error"] } "Unrecognized stream name": - value: - { - "errors": [ "Unrecognized stream name 'vdeo'" ] - } + value: { "errors": ["Unrecognized stream name 'vdeo'"] } schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" /streams/{streamname}:stop: put: operationId: putStopDataStream @@ -1741,7 +1891,7 @@ paths: schema: type: string responses: - '200': + "200": description: Successful operation. content: application/json: @@ -1753,8 +1903,8 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '400': + - $ref: "#/components/schemas/Errors" + "400": description: Bad Request content: application/json: @@ -1788,7 +1938,7 @@ paths: tags: - Configuration responses: - '200': + "200": description: Successful operation. content: application/json: @@ -1840,15 +1990,8 @@ paths: "errors": [] } schema: - allOf: - - $ref: '#/components/schemas/Errors' - type: object - properties: - categories: - type: array - items: - type: string - '404': + $ref: "#/components/schemas/ConfigListResponse" + "404": description: Endpoint not found post: operationId: postConfig @@ -1869,7 +2012,7 @@ paths: properties: Drive: type: string - enum: [ "Enabled", "Disabled" ] + enum: ["Enabled", "Disabled"] "Drive Type": type: integer "Drive Bus ID": @@ -1879,7 +2022,7 @@ paths: properties: Drive: type: string - enum: [ "Enabled", "Disabled" ] + enum: ["Enabled", "Disabled"] example: "Drive A Settings": Drive: "Enabled" @@ -1889,7 +2032,7 @@ paths: Drive: "Disabled" responses: - '200': + "200": description: OK /configs/{category}: get: @@ -1897,13 +2040,13 @@ paths: summary: Retrieve config categories description: | This command obtains a list of all the configuration items in the category specified in the URL. Wildcards are allowed. Note that the depth of the specified path is 1. It specifies the category. - + For example: - + ```GET /v1/configs/drive%20a*``` - + returns: - + ``` { "Drive A Settings": { @@ -1930,9 +2073,9 @@ paths: name: category description: | Configuration categories. - + Valid category values are: - + * ```Audio Mixer``` * ```SID Sockets Configuration``` (U64 only) * ```UltiSID Configuration``` @@ -1951,14 +2094,14 @@ paths: * ```Tape Settings``` * ```Drive A Settings``` * ```Drive B Settings``` - + Wildcards are allowed. Use the wildcard * (asterisk) to retrieve the values for all categories at once.. required: true schema: type: string responses: - '200': + "200": description: Successful operation. content: application/json: @@ -1992,14 +2135,14 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" type: object properties: categories: type: array items: type: string - '404': + "404": description: Endpoint not found /configs/{category}/{item}: get: @@ -2028,7 +2171,7 @@ paths: schema: type: string responses: - '200': + "200": description: Successful operation. content: application/json: @@ -2079,21 +2222,21 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" type: object properties: categories: type: array items: type: string - '404': + "404": description: Endpoint not found put: operationId: putConfigCategoryItem summary: Change configuration description: | This command sets a specific configuration item to the value specified in the URL, using the value argument. It is required to specify the full path to the item, although wildcards are allowed.
- + Example: ```PUT /v1/configs/drive%20a*/*bus*?value=9``` will set the ‘Drive Bus ID’ of ‘Drive A Settings’ to 9. tags: - Configuration @@ -2101,7 +2244,7 @@ paths: - in: path description: | Category name.
- + Possible values are:
`Audio Mixer`
`SID Sockets Configuration` (U64 only)
@@ -2142,7 +2285,7 @@ paths: schema: type: string responses: - '200': + "200": description: Successful operation. content: application/json: @@ -2154,8 +2297,8 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '400': + - $ref: "#/components/schemas/Errors" + "400": description: Bad Request content: application/json: @@ -2167,19 +2310,19 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" /configs:load_from_flash: put: operationId: PutConfigFromFlash summary: Load configuration file from flash description: | With this command, the complete configuration is restored to what is currently written in non-volatile memory. In other words: the ‘saved’ values are loaded into the current configuration. - + **Please note:** This request will receive an "connection reset by peer" instead of an HTTP status code. tags: - Configuration responses: - '200': + "200": description: OK /configs:save_to_flash: put: @@ -2188,9 +2331,9 @@ paths: description: | With this command, the complete configuration is written to non-volatile memory. In other words: the current configuration settings are ‘saved’ and will be loaded once the machine boots. tags: - - Configuration + - Configuration responses: - '200': + "200": description: OK /configs:reset_to_default: put: @@ -2199,9 +2342,9 @@ paths: description: | This command resets the current settings to the factory default. This does not clear or reset the values stored in non-volatile memory. tags: - - Configuration + - Configuration responses: - '200': + "200": description: OK /files/{path}:info: get: @@ -2221,15 +2364,15 @@ paths: description: |- The path to the folder where the disk image will be created. responses: - '200': + "200": description: Successful operation. content: application/json: schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" examples: - 'File information - d64': + "File information - d64": value: |- { "files": { @@ -2240,7 +2383,7 @@ paths: }, "errors": [] } - 'File information - d71': + "File information - d71": value: |- { "files": { @@ -2251,7 +2394,7 @@ paths: }, "errors": [] } - 'File information - d81': + "File information - d81": value: |- { "files": { @@ -2262,7 +2405,7 @@ paths: }, "errors": [] } - 'Directory information': + "Directory information": value: |- { "files": { @@ -2273,26 +2416,26 @@ paths: }, "errors": [] } - '400': + "400": description: "Bad request" content: application/json: schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" examples: "Require parameter tracks": value: |- { "errors" : [ "Function create_dnp requires parameter tracks" ] } - '404': + "404": description: Not found content: application/json: schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" examples: FILE DOESN'T EXIST: value: |- @@ -2337,13 +2480,13 @@ paths: schema: type: string responses: - '200': + "200": description: OK content: application/json: schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" type: object properties: path: @@ -2377,13 +2520,13 @@ paths: "bytes_written": 196608, "errors": [] } - '500': + "500": description: "Error: Internal Server Error" content: application/json: schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" type: object properties: version: @@ -2426,15 +2569,15 @@ paths: type: string example: "-= scs+trc 2024 =-" responses: - '200': + "200": description: Successful operation. content: application/json: schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" examples: - 'Successful operation': + "Successful operation": value: |- { "path": "/Temp/diskimage.d71", @@ -2443,13 +2586,13 @@ paths: "bytes_written": 349696, "errors": [] } - '500': + "500": description: "Error: Internal Server Error" content: application/json: schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" type: object properties: version: @@ -2490,15 +2633,15 @@ paths: type: string example: -= scs+trc =- responses: - '200': + "200": description: Successful operation. content: application/json: schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" examples: - 'Successful operation': + "Successful operation": value: |- { "path": "/Temp/diskimage.d81", @@ -2506,13 +2649,13 @@ paths: "bytes_written": 819200, "errors": [] } - '500': + "500": description: "Error: Internal Server Error" content: application/json: schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" type: object properties: version: @@ -2564,23 +2707,23 @@ paths: tags: - Files responses: - '200': + "200": description: Successful operation. content: application/json: schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" type: object properties: path: type: string example: "/Temp/diskimage.dnp" tracks: - type: integer - minimum: 1 - maximum: 255 - example: 255 + type: integer + minimum: 1 + maximum: 255 + example: 255 diskname: type: string example: "scs+trc 2024" @@ -2596,26 +2739,26 @@ paths: "bytes_written": 16711680, "errors": [] } - '400': + "400": description: "Bad request" content: application/json: schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" examples: "Requires parameter tracks": value: |- { "errors" : [ "Function create_dnp requires parameter tracks" ] } - '500': + "500": description: "Error: Internal Server Error" content: application/json: schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" type: object properties: version: @@ -2636,7 +2779,7 @@ components: schemas: Errors: type: object - required: [ errors ] + required: [errors] properties: errors: type: array From 60a88f077b34165c405c889ae2f2d9ce8042ac96 Mon Sep 17 00:00:00 2001 From: Christian Gleissner Date: Fri, 5 Jun 2026 18:28:09 +0100 Subject: [PATCH 2/5] Remove formatting churn --- Ultimate_OpenAPI_specs.yaml | 22 +- u2plus-open-api-spec.yaml | 728 +++++++++++++++++++++++++----------- 2 files changed, 519 insertions(+), 231 deletions(-) diff --git a/Ultimate_OpenAPI_specs.yaml b/Ultimate_OpenAPI_specs.yaml index 32845f9..5d142f9 100644 --- a/Ultimate_OpenAPI_specs.yaml +++ b/Ultimate_OpenAPI_specs.yaml @@ -54,16 +54,16 @@ components: - f3 - f5 - cursor_up_down - - "0" - - "1" - - "2" - - "3" - - "4" - - "5" - - "6" - - "7" - - "8" - - "9" + - '0' + - '1' + - '2' + - '3' + - '4' + - '5' + - '6' + - '7' + - '8' + - '9' - a - b - c @@ -77,7 +77,7 @@ components: - k - l - m - - "n" + - n - o - p - q diff --git a/u2plus-open-api-spec.yaml b/u2plus-open-api-spec.yaml index e319c36..8d68dbb 100644 --- a/u2plus-open-api-spec.yaml +++ b/u2plus-open-api-spec.yaml @@ -24,7 +24,7 @@ paths: tags: - About responses: - "200": + '200': description: Successful operation. content: application/json: @@ -36,10 +36,10 @@ paths: "errors": [ ] } schema: - $ref: "#/components/schemas/VersionResponse" - "404": + $ref: '#/components/schemas/VersionResponse' + '404': description: Not Found - "504": + '504': description: Gateway Timeout /info: get: @@ -49,19 +49,19 @@ paths: tags: - About responses: - "200": + '200': description: Successful operation. content: application/json: schema: - $ref: "#/components/schemas/InfoResponse" - "404": + $ref: '#/components/schemas/InfoResponse' + '404': description: Not Found content: application/json: schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' /machine:reset: put: operationId: resetMachine @@ -70,14 +70,14 @@ paths: tags: - Machine operations responses: - "200": + '200': description: Successful operation. content: application/json: schema: allOf: - - $ref: "#/components/schemas/Errors" - "404": + - $ref: '#/components/schemas/Errors' + '404': description: Not Found /machine:reboot: put: @@ -87,14 +87,14 @@ paths: tags: - Machine operations responses: - "200": + '200': description: Successful operation. content: application/json: schema: allOf: - - $ref: "#/components/schemas/Errors" - "404": + - $ref: '#/components/schemas/Errors' + '404': description: Not Found /machine:pause: put: @@ -106,14 +106,14 @@ paths: tags: - Machine operations responses: - "200": + '200': description: Successful operation. content: application/json: schema: allOf: - - $ref: "#/components/schemas/Errors" - "404": + - $ref: '#/components/schemas/Errors' + '404': description: Not Found /machine:resume: put: @@ -123,17 +123,17 @@ paths: tags: - Machine operations responses: - "200": + '200': description: Successful operation. content: application/json: schema: allOf: - - $ref: "#/components/schemas/Errors" - "404": + - $ref: '#/components/schemas/Errors' + '404': description: Not Found content: - application/json: {} + application/json: { } /machine:poweroff: put: operationId: powerOffMachine @@ -144,14 +144,14 @@ paths: tags: - Machine operations responses: - "200": + '200': description: Successful operation. content: application/json: schema: allOf: - - $ref: "#/components/schemas/Errors" - "404": + - $ref: '#/components/schemas/Errors' + '404': description: Not Found /machine:menu_button: put: @@ -161,13 +161,13 @@ paths: tags: - Machine operations responses: - "200": + '200': description: Button event queued content: application/json: schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' /machine:menu_screen: get: operationId: getMenuScreen @@ -181,7 +181,7 @@ paths: tags: - Machine operations responses: - "200": + '200': description: Readable 40x25 menu screen returned headers: Content-Length: @@ -191,14 +191,14 @@ paths: content: application/octet-stream: schema: - $ref: "#/components/schemas/MenuScreenBytes" - "404": + $ref: '#/components/schemas/MenuScreenBytes' + '404': description: No readable menu screen is currently available content: application/json: schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' examples: unavailable: value: @@ -212,12 +212,12 @@ paths: tags: - Machine operations responses: - "200": + '200': description: Input state returned content: application/json: schema: - $ref: "#/components/schemas/InputStateResponse" + $ref: '#/components/schemas/InputStateResponse' examples: empty: value: @@ -229,13 +229,13 @@ paths: - port: 2 inputs: [] errors: [] - "501": + '501': description: Keyboard and joystick injection are not available on this hardware content: application/json: schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' post: operationId: injectInput summary: Inject keyboard and joystick input @@ -254,7 +254,7 @@ paths: content: application/json: schema: - $ref: "#/components/schemas/InputRequest" + $ref: '#/components/schemas/InputRequest' examples: shifted_key_and_joystick: value: @@ -271,26 +271,26 @@ paths: - a transition: tap responses: - "200": + '200': description: Events applied content: application/json: schema: - $ref: "#/components/schemas/InputStateResponse" - "400": + $ref: '#/components/schemas/InputStateResponse' + '400': description: Invalid body, content type, or event batch content: application/json: schema: allOf: - - $ref: "#/components/schemas/Errors" - "501": + - $ref: '#/components/schemas/Errors' + '501': description: Keyboard and joystick injection are not available on this hardware content: application/json: schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' /machine:readmem: get: operationId: readMemory @@ -323,11 +323,11 @@ paths: minimum: 0 example: 128 responses: - "200": + '200': description: Successful operation. content: application/octet-stream: {} - "400": + '400': description: Bad request content: application/json: @@ -349,8 +349,8 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "404": + - $ref: '#/components/schemas/Errors' + '404': description: Not Found /machine:writemem: put: @@ -387,7 +387,7 @@ paths: type: string example: "1024" responses: - "200": + '200': description: Successful operation. content: application/json: @@ -400,8 +400,8 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "400": + - $ref: '#/components/schemas/Errors' + '400': description: Bad request content: application/json: @@ -418,8 +418,8 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "404": + - $ref: '#/components/schemas/Errors' + '404': description: Not Found post: operationId: writeManyDataToMemoryPost @@ -445,7 +445,7 @@ paths: application/octet-stream: schema: {} responses: - "200": + '200': description: Successful operation. content: application/json: @@ -458,8 +458,8 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "400": + - $ref: '#/components/schemas/Errors' + '400': description: Bad request content: application/json: @@ -476,8 +476,8 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "404": + - $ref: '#/components/schemas/Errors' + '404': description: Not Found /machine:debugreg: get: @@ -489,7 +489,7 @@ paths: tags: - Machine operations responses: - "200": + '200': description: Successful operation. content: application/json: @@ -502,8 +502,8 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "404": + - $ref: '#/components/schemas/Errors' + '404': description: Not Found put: operationId: writeDebugRegister @@ -524,7 +524,7 @@ paths: type: string example: "3F" responses: - "200": + '200': description: Successful operation. content: application/json: @@ -537,8 +537,8 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "404": + - $ref: '#/components/schemas/Errors' + '404': description: Not Found /runners:sidplay: put: @@ -567,7 +567,7 @@ paths: schema: type: string responses: - "200": + '200': description: Successful operation. content: application/json: @@ -584,10 +584,10 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "404": + - $ref: '#/components/schemas/Errors' + '404': description: Not Found - "500": + '500': description: Internal server error content: application/json: @@ -619,7 +619,7 @@ paths: application/octet-stream: schema: {} responses: - "200": + '200': description: Successful operation. content: application/json: @@ -636,10 +636,10 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "404": + - $ref: '#/components/schemas/Errors' + '404': description: Not Found - "500": + '500': description: Internal server error content: application/json: @@ -649,7 +649,7 @@ paths: { "errors" : [ "Undefined subsystem command" ] } - "507": + '507': description: Unknown content: application/json: @@ -677,7 +677,7 @@ paths: schema: type: string responses: - "200": + '200': description: Successful operation. content: application/json: @@ -694,10 +694,10 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "404": + - $ref: '#/components/schemas/Errors' + '404': description: Not Found - "500": + '500': description: Internal server error content: application/json: @@ -707,7 +707,7 @@ paths: { "errors" : [ "Undefined subsystem command" ] } - "507": + '507': description: Unknown content: application/json: @@ -729,7 +729,7 @@ paths: application/octet-stream: schema: {} responses: - "200": + '200': description: Successful operation. content: application/json: @@ -747,10 +747,10 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "404": + - $ref: '#/components/schemas/Errors' + '404': description: Not Found - "500": + '500': description: Internal server error content: application/json: @@ -760,7 +760,7 @@ paths: { "errors" : [ "Undefined subsystem command" ] } - "507": + '507': description: Unknown content: application/json: @@ -789,7 +789,7 @@ paths: schema: type: string responses: - "200": + '200': description: Successful operation. content: application/json: @@ -806,10 +806,10 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "404": + - $ref: '#/components/schemas/Errors' + '404': description: Not Found - "500": + '500': description: Internal server error content: application/json: @@ -819,7 +819,7 @@ paths: { "errors" : [ "Undefined subsystem command" ] } - "507": + '507': description: Unknown content: application/json: @@ -842,7 +842,7 @@ paths: application/octet-stream: schema: {} responses: - "200": + '200': description: Successful operation. content: application/json: @@ -860,10 +860,10 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "404": + - $ref: '#/components/schemas/Errors' + '404': description: Not Found - "500": + '500': description: Internal server error content: application/json: @@ -873,7 +873,7 @@ paths: { "errors" : [ "Undefined subsystem command" ] } - "507": + '507': description: Unknown content: application/json: @@ -902,7 +902,7 @@ paths: schema: type: string responses: - "200": + '200': description: Successful operation. content: application/json: @@ -915,10 +915,10 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "404": + - $ref: '#/components/schemas/Errors' + '404': description: Not Found - "500": + '500': description: Internal server error content: application/json: @@ -928,7 +928,7 @@ paths: { "errors" : [ "Undefined subsystem command" ] } - "507": + '507': description: Unknown content: application/json: @@ -951,13 +951,13 @@ paths: application/octet-stream: schema: {} responses: - "200": + '200': description: Successful operation. content: application/json: schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' examples: OK: value: |- @@ -969,9 +969,9 @@ paths: { "errors" : [ "Function run_prg does not have parameter invalidParameterName", "Function run_prg requires parameter file" ] } - "404": + '404': description: Not Found - "500": + '500': description: Internal server error content: application/json: @@ -981,7 +981,7 @@ paths: { "errors" : [ "Undefined subsystem command" ]x } - "507": + '507': description: Unknown content: application/json: @@ -1010,7 +1010,7 @@ paths: schema: type: string responses: - "200": + '200': description: Successful operation. content: application/json: @@ -1027,10 +1027,10 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "404": + - $ref: '#/components/schemas/Errors' + '404': description: Not Found - "500": + '500': description: Internal server error content: application/json: @@ -1040,7 +1040,7 @@ paths: { "errors" : [ "Undefined subsystem command" ] } - "507": + '507': description: Unknown content: application/json: @@ -1063,7 +1063,7 @@ paths: application/octet-stream: schema: {} responses: - "200": + '200': description: Successful operation. content: application/json: @@ -1081,10 +1081,10 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "404": + - $ref: '#/components/schemas/Errors' + '404': description: Not Found - "500": + '500': description: Internal server error content: application/json: @@ -1094,7 +1094,7 @@ paths: { "errors" : [ "Undefined subsystem command" ] } - "507": + '507': description: Unknown content: application/json: @@ -1115,7 +1115,7 @@ paths: tags: - Floppy drives responses: - "200": + '200': description: Successful operation. content: application/json: @@ -1168,7 +1168,7 @@ paths: "errors": [] } schema: - $ref: "#/components/schemas/DriveListResponse" + $ref: '#/components/schemas/DriveListResponse' /drives/{drive}:mount: put: operationId: putMountDiskImage @@ -1225,7 +1225,7 @@ paths: schema: type: string responses: - "200": + '200': description: Successful operation. content: application/json: @@ -1246,8 +1246,8 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "400": + - $ref: '#/components/schemas/Errors' + '400': description: Bad Request content: application/json: @@ -1262,9 +1262,9 @@ paths: { "errors" : [ "Invalid Type 'd65'" ] } - "404": + '404': description: Not Found - "500": + '500': description: Internal server error content: application/json: @@ -1274,7 +1274,7 @@ paths: { "errors" : [ "Undefined subsystem command" ] } - "507": + '507': description: Unknown content: application/json: @@ -1334,7 +1334,7 @@ paths: application/octet-stream: schema: {} responses: - "200": + '200': description: Successful operation. content: application/json: @@ -1351,8 +1351,8 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "400": + - $ref: '#/components/schemas/Errors' + '400': description: Bad Request content: application/json: @@ -1362,9 +1362,9 @@ paths: { "errors": [ "Invalid Drive 'c'" ] } - "404": + '404': description: Not Found - "500": + '500': description: Internal server error content: application/json: @@ -1379,7 +1379,7 @@ paths: { 'errors': ['Read operation on file failed'] } - "507": + '507': description: Unknown content: application/json: @@ -1408,7 +1408,7 @@ paths: Valid options are one of the following:
`a`, `b` responses: - "200": + '200': description: Successful operation. content: application/json: @@ -1420,8 +1420,8 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "400": + - $ref: '#/components/schemas/Errors' + '400': description: Bad Request content: application/json: @@ -1433,7 +1433,7 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' /drives/{drive}:remove: put: operationId: putRemoveDisk @@ -1453,7 +1453,7 @@ paths: Valid options are one of the following:
`a`, `b` responses: - "200": + '200': description: Successful operation. content: application/json: @@ -1465,8 +1465,8 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "400": + - $ref: '#/components/schemas/Errors' + '400': description: Bad Request content: application/json: @@ -1478,7 +1478,7 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' /drives/{drive}:unlink: put: operationId: putUnlinkDisk @@ -1499,7 +1499,7 @@ paths: Valid options are one of the following:
`a`, `b` responses: - "200": + '200': description: Successful operation. content: application/json: @@ -1511,8 +1511,8 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "400": + - $ref: '#/components/schemas/Errors' + '400': description: Bad Request content: application/json: @@ -1524,7 +1524,7 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' /drives/{drive}:on: put: operationId: putUnEnableDrive @@ -1544,7 +1544,7 @@ paths: Valid options are one of the following:
`a`, `b` responses: - "200": + '200': description: Successful operation. content: application/json: @@ -1556,8 +1556,8 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "400": + - $ref: '#/components/schemas/Errors' + '400': description: Bad Request content: application/json: @@ -1569,7 +1569,7 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' /drives/{drive}:off: put: operationId: putDisableDrive @@ -1590,7 +1590,7 @@ paths: Valid options are one of the following:
`a`, `b` responses: - "200": + '200': description: Successful operation. content: application/json: @@ -1602,8 +1602,8 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "400": + - $ref: '#/components/schemas/Errors' + '400': description: Bad Request content: application/json: @@ -1615,7 +1615,7 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' /drives/{drive}:load_rom: put: operationId: putLoadDriveRom @@ -1649,7 +1649,7 @@ paths: schema: type: string responses: - "200": + '200': description: Successful operation. content: application/json: @@ -1661,8 +1661,8 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "400": + - $ref: '#/components/schemas/Errors' + '400': description: Bad Request content: application/json: @@ -1674,7 +1674,7 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' post: operationId: postLoadRom summary: Load disk drive rom @@ -1703,7 +1703,7 @@ paths: application/octet-stream: schema: {} responses: - "200": + '200': description: Successful operation. content: application/json: @@ -1715,8 +1715,8 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "400": + - $ref: '#/components/schemas/Errors' + '400': description: Bad Request content: application/json: @@ -1728,7 +1728,7 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' /drives/{drive}:set_mode: put: operationId: postSetMode @@ -1754,13 +1754,13 @@ paths: schema: type: string enum: - - "1541" - - "1571" - - "1581" + - '1541' + - '1571' + - '1581' required: true description: The available values are `1541`, `1571` and `1581`. responses: - "200": + '200': description: Successful operation. content: application/json: @@ -1772,8 +1772,8 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "400": + - $ref: '#/components/schemas/Errors' + '400': description: Bad Request content: application/json: @@ -1785,7 +1785,7 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' /streams/{streamname}:start: put: operationId: putStartDataStream @@ -1824,7 +1824,7 @@ paths: type: string default: video responses: - "200": + '200': description: Successful operation. content: application/json: @@ -1836,8 +1836,8 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "400": + - $ref: '#/components/schemas/Errors' + '400': description: Bad Request content: application/json: @@ -1858,19 +1858,25 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "404": + - $ref: '#/components/schemas/Errors' + '404': description: Not Found content: application/json: examples: "Network Host Resolve Error": - value: { "errors": ["Network Host Resolve Error"] } + value: + { + "errors": [ "Network Host Resolve Error" ] + } "Unrecognized stream name": - value: { "errors": ["Unrecognized stream name 'vdeo'"] } + value: + { + "errors": [ "Unrecognized stream name 'vdeo'" ] + } schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' /streams/{streamname}:stop: put: operationId: putStopDataStream @@ -1891,7 +1897,7 @@ paths: schema: type: string responses: - "200": + '200': description: Successful operation. content: application/json: @@ -1903,8 +1909,8 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "400": + - $ref: '#/components/schemas/Errors' + '400': description: Bad Request content: application/json: @@ -1938,7 +1944,7 @@ paths: tags: - Configuration responses: - "200": + '200': description: Successful operation. content: application/json: @@ -1990,8 +1996,8 @@ paths: "errors": [] } schema: - $ref: "#/components/schemas/ConfigListResponse" - "404": + $ref: '#/components/schemas/ConfigListResponse' + '404': description: Endpoint not found post: operationId: postConfig @@ -2012,7 +2018,7 @@ paths: properties: Drive: type: string - enum: ["Enabled", "Disabled"] + enum: [ "Enabled", "Disabled" ] "Drive Type": type: integer "Drive Bus ID": @@ -2022,7 +2028,7 @@ paths: properties: Drive: type: string - enum: ["Enabled", "Disabled"] + enum: [ "Enabled", "Disabled" ] example: "Drive A Settings": Drive: "Enabled" @@ -2032,7 +2038,7 @@ paths: Drive: "Disabled" responses: - "200": + '200': description: OK /configs/{category}: get: @@ -2101,7 +2107,7 @@ paths: type: string responses: - "200": + '200': description: Successful operation. content: application/json: @@ -2135,14 +2141,14 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' type: object properties: categories: type: array items: type: string - "404": + '404': description: Endpoint not found /configs/{category}/{item}: get: @@ -2171,7 +2177,7 @@ paths: schema: type: string responses: - "200": + '200': description: Successful operation. content: application/json: @@ -2222,14 +2228,14 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' type: object properties: categories: type: array items: type: string - "404": + '404': description: Endpoint not found put: operationId: putConfigCategoryItem @@ -2285,7 +2291,7 @@ paths: schema: type: string responses: - "200": + '200': description: Successful operation. content: application/json: @@ -2297,8 +2303,8 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "400": + - $ref: '#/components/schemas/Errors' + '400': description: Bad Request content: application/json: @@ -2310,7 +2316,7 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' /configs:load_from_flash: put: operationId: PutConfigFromFlash @@ -2322,7 +2328,7 @@ paths: tags: - Configuration responses: - "200": + '200': description: OK /configs:save_to_flash: put: @@ -2333,7 +2339,7 @@ paths: tags: - Configuration responses: - "200": + '200': description: OK /configs:reset_to_default: put: @@ -2344,7 +2350,7 @@ paths: tags: - Configuration responses: - "200": + '200': description: OK /files/{path}:info: get: @@ -2364,15 +2370,15 @@ paths: description: |- The path to the folder where the disk image will be created. responses: - "200": + '200': description: Successful operation. content: application/json: schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' examples: - "File information - d64": + 'File information - d64': value: |- { "files": { @@ -2383,7 +2389,7 @@ paths: }, "errors": [] } - "File information - d71": + 'File information - d71': value: |- { "files": { @@ -2394,7 +2400,7 @@ paths: }, "errors": [] } - "File information - d81": + 'File information - d81': value: |- { "files": { @@ -2405,7 +2411,7 @@ paths: }, "errors": [] } - "Directory information": + 'Directory information': value: |- { "files": { @@ -2416,26 +2422,26 @@ paths: }, "errors": [] } - "400": + '400': description: "Bad request" content: application/json: schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' examples: "Require parameter tracks": value: |- { "errors" : [ "Function create_dnp requires parameter tracks" ] } - "404": + '404': description: Not found content: application/json: schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' examples: FILE DOESN'T EXIST: value: |- @@ -2480,13 +2486,13 @@ paths: schema: type: string responses: - "200": + '200': description: OK content: application/json: schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' type: object properties: path: @@ -2520,13 +2526,13 @@ paths: "bytes_written": 196608, "errors": [] } - "500": + '500': description: "Error: Internal Server Error" content: application/json: schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' type: object properties: version: @@ -2569,15 +2575,15 @@ paths: type: string example: "-= scs+trc 2024 =-" responses: - "200": + '200': description: Successful operation. content: application/json: schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' examples: - "Successful operation": + 'Successful operation': value: |- { "path": "/Temp/diskimage.d71", @@ -2586,13 +2592,13 @@ paths: "bytes_written": 349696, "errors": [] } - "500": + '500': description: "Error: Internal Server Error" content: application/json: schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' type: object properties: version: @@ -2633,15 +2639,15 @@ paths: type: string example: -= scs+trc =- responses: - "200": + '200': description: Successful operation. content: application/json: schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' examples: - "Successful operation": + 'Successful operation': value: |- { "path": "/Temp/diskimage.d81", @@ -2649,13 +2655,13 @@ paths: "bytes_written": 819200, "errors": [] } - "500": + '500': description: "Error: Internal Server Error" content: application/json: schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' type: object properties: version: @@ -2707,13 +2713,13 @@ paths: tags: - Files responses: - "200": + '200': description: Successful operation. content: application/json: schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' type: object properties: path: @@ -2739,26 +2745,26 @@ paths: "bytes_written": 16711680, "errors": [] } - "400": + '400': description: "Bad request" content: application/json: schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' examples: "Requires parameter tracks": value: |- { "errors" : [ "Function create_dnp requires parameter tracks" ] } - "500": + '500': description: "Error: Internal Server Error" content: application/json: schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' type: object properties: version: @@ -2779,9 +2785,291 @@ components: schemas: Errors: type: object - required: [errors] + required: [ errors ] properties: errors: type: array items: type: string + VersionResponse: + allOf: + - $ref: '#/components/schemas/Errors' + - type: object + required: + - version + properties: + version: + type: string + InfoResponse: + allOf: + - $ref: '#/components/schemas/Errors' + - type: object + properties: + product: + type: string + firmware_version: + type: string + fpga_version: + type: string + core_version: + type: string + description: Present on Ultimate 64 devices. + hostname: + type: string + unique_id: + type: string + MenuScreenBytes: + type: string + format: binary + description: | + Exactly 2000 bytes. Bytes 0..999 are the 40x25 firmware UI character + matrix. Bytes 1000..1999 are the matching 40x25 colour-attribute + matrix. Both matrices are row-major: offset = row * 40 + column. + In each colour-attribute byte, bits 0..3 are the foreground colour + and bits 4..7 are the background colour. + minLength: 2000 + maxLength: 2000 + InputTransition: + type: string + enum: + - press + - release + - tap + KeyboardInputName: + type: string + enum: + - inst_del + - return + - cursor_left_right + - f7 + - f1 + - f3 + - f5 + - cursor_up_down + - '0' + - '1' + - '2' + - '3' + - '4' + - '5' + - '6' + - '7' + - '8' + - '9' + - a + - b + - c + - d + - e + - f + - g + - h + - i + - j + - k + - l + - m + - n + - o + - p + - q + - r + - s + - t + - u + - v + - w + - x + - y + - z + - left_shift + - right_shift + - plus + - minus + - period + - colon + - at + - comma + - pound + - star + - semicolon + - clr_home + - equals + - arrow_up + - slash + - arrow_left + - ctrl + - space + - commodore + - run_stop + - restore + description: | + REST input name from the C64 keyboard matrix. `restore` is special: + firmware accepts it only as the sole input in a keyboard event with + transition `tap`. + JoystickInputName: + type: string + enum: + - up + - down + - left + - right + - fire + - fire2 + - fire3 + KeyboardInputEvent: + type: object + additionalProperties: false + required: + - kind + - inputs + - transition + properties: + kind: + type: string + const: keyboard + inputs: + type: array + minItems: 1 + maxItems: 8 + uniqueItems: true + items: + $ref: '#/components/schemas/KeyboardInputName' + transition: + $ref: '#/components/schemas/InputTransition' + JoystickInputEvent: + type: object + additionalProperties: false + required: + - kind + - port + - inputs + - transition + properties: + kind: + type: string + const: joystick + port: + type: integer + enum: + - 1 + - 2 + inputs: + type: array + minItems: 1 + maxItems: 7 + uniqueItems: true + items: + $ref: '#/components/schemas/JoystickInputName' + transition: + $ref: '#/components/schemas/InputTransition' + ReleaseAllInputEvent: + type: object + additionalProperties: false + required: + - kind + properties: + kind: + type: string + const: release_all + InputEvent: + oneOf: + - $ref: '#/components/schemas/KeyboardInputEvent' + - $ref: '#/components/schemas/JoystickInputEvent' + - $ref: '#/components/schemas/ReleaseAllInputEvent' + InputRequest: + type: object + additionalProperties: false + required: + - events + properties: + events: + type: array + minItems: 1 + maxItems: 64 + items: + $ref: '#/components/schemas/InputEvent' + KeyboardInputState: + type: object + required: + - inputs + properties: + inputs: + type: array + items: + $ref: '#/components/schemas/KeyboardInputName' + JoystickInputState: + type: object + required: + - port + - inputs + properties: + port: + type: integer + enum: + - 1 + - 2 + inputs: + type: array + items: + $ref: '#/components/schemas/JoystickInputName' + InputStateResponse: + allOf: + - $ref: '#/components/schemas/Errors' + - type: object + required: + - keyboard + - joysticks + properties: + keyboard: + $ref: '#/components/schemas/KeyboardInputState' + joysticks: + type: array + minItems: 2 + maxItems: 2 + items: + $ref: '#/components/schemas/JoystickInputState' + DriveListResponse: + allOf: + - $ref: '#/components/schemas/Errors' + - type: object + properties: + drives: + type: array + items: + type: object + additionalProperties: + type: object + properties: + enabled: + type: boolean + bus_id: + type: integer + type: + type: string + rom: + type: string + image_file: + type: string + image_path: + type: string + last_error: + type: string + partitions: + type: array + items: + type: object + properties: + id: + type: integer + path: + type: string + ConfigListResponse: + allOf: + - $ref: '#/components/schemas/Errors' + - type: object + properties: + categories: + type: array + items: + type: string From 7e29c517ec9f9ae7f3e81251e49c903b46712807 Mon Sep 17 00:00:00 2001 From: Christian Gleissner Date: Fri, 5 Jun 2026 18:32:33 +0100 Subject: [PATCH 3/5] Ensure valid JSON in example --- u2plus-open-api-spec.yaml | 502 +++++++++++++++++++------------------- 1 file changed, 248 insertions(+), 254 deletions(-) diff --git a/u2plus-open-api-spec.yaml b/u2plus-open-api-spec.yaml index 8d68dbb..3b39810 100644 --- a/u2plus-open-api-spec.yaml +++ b/u2plus-open-api-spec.yaml @@ -24,7 +24,7 @@ paths: tags: - About responses: - '200': + "200": description: Successful operation. content: application/json: @@ -36,10 +36,10 @@ paths: "errors": [ ] } schema: - $ref: '#/components/schemas/VersionResponse' - '404': + $ref: "#/components/schemas/VersionResponse" + "404": description: Not Found - '504': + "504": description: Gateway Timeout /info: get: @@ -49,19 +49,19 @@ paths: tags: - About responses: - '200': + "200": description: Successful operation. content: application/json: schema: - $ref: '#/components/schemas/InfoResponse' - '404': + $ref: "#/components/schemas/InfoResponse" + "404": description: Not Found content: application/json: schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" /machine:reset: put: operationId: resetMachine @@ -70,14 +70,14 @@ paths: tags: - Machine operations responses: - '200': + "200": description: Successful operation. content: application/json: schema: allOf: - - $ref: '#/components/schemas/Errors' - '404': + - $ref: "#/components/schemas/Errors" + "404": description: Not Found /machine:reboot: put: @@ -87,14 +87,14 @@ paths: tags: - Machine operations responses: - '200': + "200": description: Successful operation. content: application/json: schema: allOf: - - $ref: '#/components/schemas/Errors' - '404': + - $ref: "#/components/schemas/Errors" + "404": description: Not Found /machine:pause: put: @@ -106,14 +106,14 @@ paths: tags: - Machine operations responses: - '200': + "200": description: Successful operation. content: application/json: schema: allOf: - - $ref: '#/components/schemas/Errors' - '404': + - $ref: "#/components/schemas/Errors" + "404": description: Not Found /machine:resume: put: @@ -123,17 +123,17 @@ paths: tags: - Machine operations responses: - '200': + "200": description: Successful operation. content: application/json: schema: allOf: - - $ref: '#/components/schemas/Errors' - '404': + - $ref: "#/components/schemas/Errors" + "404": description: Not Found content: - application/json: { } + application/json: {} /machine:poweroff: put: operationId: powerOffMachine @@ -144,14 +144,14 @@ paths: tags: - Machine operations responses: - '200': + "200": description: Successful operation. content: application/json: schema: allOf: - - $ref: '#/components/schemas/Errors' - '404': + - $ref: "#/components/schemas/Errors" + "404": description: Not Found /machine:menu_button: put: @@ -161,13 +161,13 @@ paths: tags: - Machine operations responses: - '200': + "200": description: Button event queued content: application/json: schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" /machine:menu_screen: get: operationId: getMenuScreen @@ -181,7 +181,7 @@ paths: tags: - Machine operations responses: - '200': + "200": description: Readable 40x25 menu screen returned headers: Content-Length: @@ -191,14 +191,14 @@ paths: content: application/octet-stream: schema: - $ref: '#/components/schemas/MenuScreenBytes' - '404': + $ref: "#/components/schemas/MenuScreenBytes" + "404": description: No readable menu screen is currently available content: application/json: schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" examples: unavailable: value: @@ -212,12 +212,12 @@ paths: tags: - Machine operations responses: - '200': + "200": description: Input state returned content: application/json: schema: - $ref: '#/components/schemas/InputStateResponse' + $ref: "#/components/schemas/InputStateResponse" examples: empty: value: @@ -229,13 +229,13 @@ paths: - port: 2 inputs: [] errors: [] - '501': + "501": description: Keyboard and joystick injection are not available on this hardware content: application/json: schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" post: operationId: injectInput summary: Inject keyboard and joystick input @@ -254,7 +254,7 @@ paths: content: application/json: schema: - $ref: '#/components/schemas/InputRequest' + $ref: "#/components/schemas/InputRequest" examples: shifted_key_and_joystick: value: @@ -271,26 +271,26 @@ paths: - a transition: tap responses: - '200': + "200": description: Events applied content: application/json: schema: - $ref: '#/components/schemas/InputStateResponse' - '400': + $ref: "#/components/schemas/InputStateResponse" + "400": description: Invalid body, content type, or event batch content: application/json: schema: allOf: - - $ref: '#/components/schemas/Errors' - '501': + - $ref: "#/components/schemas/Errors" + "501": description: Keyboard and joystick injection are not available on this hardware content: application/json: schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" /machine:readmem: get: operationId: readMemory @@ -323,11 +323,11 @@ paths: minimum: 0 example: 128 responses: - '200': + "200": description: Successful operation. content: application/octet-stream: {} - '400': + "400": description: Bad request content: application/json: @@ -349,8 +349,8 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '404': + - $ref: "#/components/schemas/Errors" + "404": description: Not Found /machine:writemem: put: @@ -387,7 +387,7 @@ paths: type: string example: "1024" responses: - '200': + "200": description: Successful operation. content: application/json: @@ -400,8 +400,8 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '400': + - $ref: "#/components/schemas/Errors" + "400": description: Bad request content: application/json: @@ -418,8 +418,8 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '404': + - $ref: "#/components/schemas/Errors" + "404": description: Not Found post: operationId: writeManyDataToMemoryPost @@ -445,7 +445,7 @@ paths: application/octet-stream: schema: {} responses: - '200': + "200": description: Successful operation. content: application/json: @@ -458,8 +458,8 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '400': + - $ref: "#/components/schemas/Errors" + "400": description: Bad request content: application/json: @@ -476,8 +476,8 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '404': + - $ref: "#/components/schemas/Errors" + "404": description: Not Found /machine:debugreg: get: @@ -489,7 +489,7 @@ paths: tags: - Machine operations responses: - '200': + "200": description: Successful operation. content: application/json: @@ -502,8 +502,8 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '404': + - $ref: "#/components/schemas/Errors" + "404": description: Not Found put: operationId: writeDebugRegister @@ -524,7 +524,7 @@ paths: type: string example: "3F" responses: - '200': + "200": description: Successful operation. content: application/json: @@ -537,8 +537,8 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '404': + - $ref: "#/components/schemas/Errors" + "404": description: Not Found /runners:sidplay: put: @@ -567,7 +567,7 @@ paths: schema: type: string responses: - '200': + "200": description: Successful operation. content: application/json: @@ -584,10 +584,10 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '404': + - $ref: "#/components/schemas/Errors" + "404": description: Not Found - '500': + "500": description: Internal server error content: application/json: @@ -619,7 +619,7 @@ paths: application/octet-stream: schema: {} responses: - '200': + "200": description: Successful operation. content: application/json: @@ -636,10 +636,10 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '404': + - $ref: "#/components/schemas/Errors" + "404": description: Not Found - '500': + "500": description: Internal server error content: application/json: @@ -649,7 +649,7 @@ paths: { "errors" : [ "Undefined subsystem command" ] } - '507': + "507": description: Unknown content: application/json: @@ -677,7 +677,7 @@ paths: schema: type: string responses: - '200': + "200": description: Successful operation. content: application/json: @@ -694,10 +694,10 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '404': + - $ref: "#/components/schemas/Errors" + "404": description: Not Found - '500': + "500": description: Internal server error content: application/json: @@ -707,7 +707,7 @@ paths: { "errors" : [ "Undefined subsystem command" ] } - '507': + "507": description: Unknown content: application/json: @@ -729,7 +729,7 @@ paths: application/octet-stream: schema: {} responses: - '200': + "200": description: Successful operation. content: application/json: @@ -747,10 +747,10 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '404': + - $ref: "#/components/schemas/Errors" + "404": description: Not Found - '500': + "500": description: Internal server error content: application/json: @@ -760,7 +760,7 @@ paths: { "errors" : [ "Undefined subsystem command" ] } - '507': + "507": description: Unknown content: application/json: @@ -789,7 +789,7 @@ paths: schema: type: string responses: - '200': + "200": description: Successful operation. content: application/json: @@ -806,10 +806,10 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '404': + - $ref: "#/components/schemas/Errors" + "404": description: Not Found - '500': + "500": description: Internal server error content: application/json: @@ -819,7 +819,7 @@ paths: { "errors" : [ "Undefined subsystem command" ] } - '507': + "507": description: Unknown content: application/json: @@ -842,7 +842,7 @@ paths: application/octet-stream: schema: {} responses: - '200': + "200": description: Successful operation. content: application/json: @@ -860,10 +860,10 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '404': + - $ref: "#/components/schemas/Errors" + "404": description: Not Found - '500': + "500": description: Internal server error content: application/json: @@ -873,7 +873,7 @@ paths: { "errors" : [ "Undefined subsystem command" ] } - '507': + "507": description: Unknown content: application/json: @@ -902,7 +902,7 @@ paths: schema: type: string responses: - '200': + "200": description: Successful operation. content: application/json: @@ -915,10 +915,10 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '404': + - $ref: "#/components/schemas/Errors" + "404": description: Not Found - '500': + "500": description: Internal server error content: application/json: @@ -928,7 +928,7 @@ paths: { "errors" : [ "Undefined subsystem command" ] } - '507': + "507": description: Unknown content: application/json: @@ -951,13 +951,13 @@ paths: application/octet-stream: schema: {} responses: - '200': + "200": description: Successful operation. content: application/json: schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" examples: OK: value: |- @@ -969,9 +969,9 @@ paths: { "errors" : [ "Function run_prg does not have parameter invalidParameterName", "Function run_prg requires parameter file" ] } - '404': + "404": description: Not Found - '500': + "500": description: Internal server error content: application/json: @@ -979,9 +979,9 @@ paths: Undefined subsystem command: value: |- { - "errors" : [ "Undefined subsystem command" ]x + "errors" : [ "Undefined subsystem command" ] } - '507': + "507": description: Unknown content: application/json: @@ -1010,7 +1010,7 @@ paths: schema: type: string responses: - '200': + "200": description: Successful operation. content: application/json: @@ -1027,10 +1027,10 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '404': + - $ref: "#/components/schemas/Errors" + "404": description: Not Found - '500': + "500": description: Internal server error content: application/json: @@ -1040,7 +1040,7 @@ paths: { "errors" : [ "Undefined subsystem command" ] } - '507': + "507": description: Unknown content: application/json: @@ -1063,7 +1063,7 @@ paths: application/octet-stream: schema: {} responses: - '200': + "200": description: Successful operation. content: application/json: @@ -1081,10 +1081,10 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '404': + - $ref: "#/components/schemas/Errors" + "404": description: Not Found - '500': + "500": description: Internal server error content: application/json: @@ -1094,7 +1094,7 @@ paths: { "errors" : [ "Undefined subsystem command" ] } - '507': + "507": description: Unknown content: application/json: @@ -1115,7 +1115,7 @@ paths: tags: - Floppy drives responses: - '200': + "200": description: Successful operation. content: application/json: @@ -1168,7 +1168,7 @@ paths: "errors": [] } schema: - $ref: '#/components/schemas/DriveListResponse' + $ref: "#/components/schemas/DriveListResponse" /drives/{drive}:mount: put: operationId: putMountDiskImage @@ -1225,7 +1225,7 @@ paths: schema: type: string responses: - '200': + "200": description: Successful operation. content: application/json: @@ -1246,8 +1246,8 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '400': + - $ref: "#/components/schemas/Errors" + "400": description: Bad Request content: application/json: @@ -1262,9 +1262,9 @@ paths: { "errors" : [ "Invalid Type 'd65'" ] } - '404': + "404": description: Not Found - '500': + "500": description: Internal server error content: application/json: @@ -1274,7 +1274,7 @@ paths: { "errors" : [ "Undefined subsystem command" ] } - '507': + "507": description: Unknown content: application/json: @@ -1334,7 +1334,7 @@ paths: application/octet-stream: schema: {} responses: - '200': + "200": description: Successful operation. content: application/json: @@ -1351,8 +1351,8 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '400': + - $ref: "#/components/schemas/Errors" + "400": description: Bad Request content: application/json: @@ -1362,9 +1362,9 @@ paths: { "errors": [ "Invalid Drive 'c'" ] } - '404': + "404": description: Not Found - '500': + "500": description: Internal server error content: application/json: @@ -1379,7 +1379,7 @@ paths: { 'errors': ['Read operation on file failed'] } - '507': + "507": description: Unknown content: application/json: @@ -1408,7 +1408,7 @@ paths: Valid options are one of the following:
`a`, `b` responses: - '200': + "200": description: Successful operation. content: application/json: @@ -1420,8 +1420,8 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '400': + - $ref: "#/components/schemas/Errors" + "400": description: Bad Request content: application/json: @@ -1433,7 +1433,7 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" /drives/{drive}:remove: put: operationId: putRemoveDisk @@ -1453,7 +1453,7 @@ paths: Valid options are one of the following:
`a`, `b` responses: - '200': + "200": description: Successful operation. content: application/json: @@ -1465,8 +1465,8 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '400': + - $ref: "#/components/schemas/Errors" + "400": description: Bad Request content: application/json: @@ -1478,7 +1478,7 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" /drives/{drive}:unlink: put: operationId: putUnlinkDisk @@ -1499,7 +1499,7 @@ paths: Valid options are one of the following:
`a`, `b` responses: - '200': + "200": description: Successful operation. content: application/json: @@ -1511,8 +1511,8 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '400': + - $ref: "#/components/schemas/Errors" + "400": description: Bad Request content: application/json: @@ -1524,7 +1524,7 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" /drives/{drive}:on: put: operationId: putUnEnableDrive @@ -1544,7 +1544,7 @@ paths: Valid options are one of the following:
`a`, `b` responses: - '200': + "200": description: Successful operation. content: application/json: @@ -1556,8 +1556,8 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '400': + - $ref: "#/components/schemas/Errors" + "400": description: Bad Request content: application/json: @@ -1569,7 +1569,7 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" /drives/{drive}:off: put: operationId: putDisableDrive @@ -1590,7 +1590,7 @@ paths: Valid options are one of the following:
`a`, `b` responses: - '200': + "200": description: Successful operation. content: application/json: @@ -1602,8 +1602,8 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '400': + - $ref: "#/components/schemas/Errors" + "400": description: Bad Request content: application/json: @@ -1615,7 +1615,7 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" /drives/{drive}:load_rom: put: operationId: putLoadDriveRom @@ -1649,7 +1649,7 @@ paths: schema: type: string responses: - '200': + "200": description: Successful operation. content: application/json: @@ -1661,8 +1661,8 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '400': + - $ref: "#/components/schemas/Errors" + "400": description: Bad Request content: application/json: @@ -1674,7 +1674,7 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" post: operationId: postLoadRom summary: Load disk drive rom @@ -1703,7 +1703,7 @@ paths: application/octet-stream: schema: {} responses: - '200': + "200": description: Successful operation. content: application/json: @@ -1715,8 +1715,8 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '400': + - $ref: "#/components/schemas/Errors" + "400": description: Bad Request content: application/json: @@ -1728,7 +1728,7 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" /drives/{drive}:set_mode: put: operationId: postSetMode @@ -1754,13 +1754,13 @@ paths: schema: type: string enum: - - '1541' - - '1571' - - '1581' + - "1541" + - "1571" + - "1581" required: true description: The available values are `1541`, `1571` and `1581`. responses: - '200': + "200": description: Successful operation. content: application/json: @@ -1772,8 +1772,8 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '400': + - $ref: "#/components/schemas/Errors" + "400": description: Bad Request content: application/json: @@ -1785,7 +1785,7 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" /streams/{streamname}:start: put: operationId: putStartDataStream @@ -1824,7 +1824,7 @@ paths: type: string default: video responses: - '200': + "200": description: Successful operation. content: application/json: @@ -1836,8 +1836,8 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '400': + - $ref: "#/components/schemas/Errors" + "400": description: Bad Request content: application/json: @@ -1858,25 +1858,19 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '404': + - $ref: "#/components/schemas/Errors" + "404": description: Not Found content: application/json: examples: "Network Host Resolve Error": - value: - { - "errors": [ "Network Host Resolve Error" ] - } + value: { "errors": ["Network Host Resolve Error"] } "Unrecognized stream name": - value: - { - "errors": [ "Unrecognized stream name 'vdeo'" ] - } + value: { "errors": ["Unrecognized stream name 'vdeo'"] } schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" /streams/{streamname}:stop: put: operationId: putStopDataStream @@ -1897,7 +1891,7 @@ paths: schema: type: string responses: - '200': + "200": description: Successful operation. content: application/json: @@ -1909,8 +1903,8 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '400': + - $ref: "#/components/schemas/Errors" + "400": description: Bad Request content: application/json: @@ -1944,7 +1938,7 @@ paths: tags: - Configuration responses: - '200': + "200": description: Successful operation. content: application/json: @@ -1996,8 +1990,8 @@ paths: "errors": [] } schema: - $ref: '#/components/schemas/ConfigListResponse' - '404': + $ref: "#/components/schemas/ConfigListResponse" + "404": description: Endpoint not found post: operationId: postConfig @@ -2018,7 +2012,7 @@ paths: properties: Drive: type: string - enum: [ "Enabled", "Disabled" ] + enum: ["Enabled", "Disabled"] "Drive Type": type: integer "Drive Bus ID": @@ -2028,7 +2022,7 @@ paths: properties: Drive: type: string - enum: [ "Enabled", "Disabled" ] + enum: ["Enabled", "Disabled"] example: "Drive A Settings": Drive: "Enabled" @@ -2038,7 +2032,7 @@ paths: Drive: "Disabled" responses: - '200': + "200": description: OK /configs/{category}: get: @@ -2107,7 +2101,7 @@ paths: type: string responses: - '200': + "200": description: Successful operation. content: application/json: @@ -2141,14 +2135,14 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" type: object properties: categories: type: array items: type: string - '404': + "404": description: Endpoint not found /configs/{category}/{item}: get: @@ -2177,7 +2171,7 @@ paths: schema: type: string responses: - '200': + "200": description: Successful operation. content: application/json: @@ -2228,14 +2222,14 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" type: object properties: categories: type: array items: type: string - '404': + "404": description: Endpoint not found put: operationId: putConfigCategoryItem @@ -2291,7 +2285,7 @@ paths: schema: type: string responses: - '200': + "200": description: Successful operation. content: application/json: @@ -2303,8 +2297,8 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' - '400': + - $ref: "#/components/schemas/Errors" + "400": description: Bad Request content: application/json: @@ -2316,7 +2310,7 @@ paths: } schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" /configs:load_from_flash: put: operationId: PutConfigFromFlash @@ -2328,7 +2322,7 @@ paths: tags: - Configuration responses: - '200': + "200": description: OK /configs:save_to_flash: put: @@ -2339,7 +2333,7 @@ paths: tags: - Configuration responses: - '200': + "200": description: OK /configs:reset_to_default: put: @@ -2350,7 +2344,7 @@ paths: tags: - Configuration responses: - '200': + "200": description: OK /files/{path}:info: get: @@ -2370,15 +2364,15 @@ paths: description: |- The path to the folder where the disk image will be created. responses: - '200': + "200": description: Successful operation. content: application/json: schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" examples: - 'File information - d64': + "File information - d64": value: |- { "files": { @@ -2389,7 +2383,7 @@ paths: }, "errors": [] } - 'File information - d71': + "File information - d71": value: |- { "files": { @@ -2400,7 +2394,7 @@ paths: }, "errors": [] } - 'File information - d81': + "File information - d81": value: |- { "files": { @@ -2411,7 +2405,7 @@ paths: }, "errors": [] } - 'Directory information': + "Directory information": value: |- { "files": { @@ -2422,26 +2416,26 @@ paths: }, "errors": [] } - '400': + "400": description: "Bad request" content: application/json: schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" examples: "Require parameter tracks": value: |- { "errors" : [ "Function create_dnp requires parameter tracks" ] } - '404': + "404": description: Not found content: application/json: schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" examples: FILE DOESN'T EXIST: value: |- @@ -2486,13 +2480,13 @@ paths: schema: type: string responses: - '200': + "200": description: OK content: application/json: schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" type: object properties: path: @@ -2526,13 +2520,13 @@ paths: "bytes_written": 196608, "errors": [] } - '500': + "500": description: "Error: Internal Server Error" content: application/json: schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" type: object properties: version: @@ -2575,15 +2569,15 @@ paths: type: string example: "-= scs+trc 2024 =-" responses: - '200': + "200": description: Successful operation. content: application/json: schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" examples: - 'Successful operation': + "Successful operation": value: |- { "path": "/Temp/diskimage.d71", @@ -2592,13 +2586,13 @@ paths: "bytes_written": 349696, "errors": [] } - '500': + "500": description: "Error: Internal Server Error" content: application/json: schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" type: object properties: version: @@ -2639,15 +2633,15 @@ paths: type: string example: -= scs+trc =- responses: - '200': + "200": description: Successful operation. content: application/json: schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" examples: - 'Successful operation': + "Successful operation": value: |- { "path": "/Temp/diskimage.d81", @@ -2655,13 +2649,13 @@ paths: "bytes_written": 819200, "errors": [] } - '500': + "500": description: "Error: Internal Server Error" content: application/json: schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" type: object properties: version: @@ -2713,13 +2707,13 @@ paths: tags: - Files responses: - '200': + "200": description: Successful operation. content: application/json: schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" type: object properties: path: @@ -2745,26 +2739,26 @@ paths: "bytes_written": 16711680, "errors": [] } - '400': + "400": description: "Bad request" content: application/json: schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" examples: "Requires parameter tracks": value: |- { "errors" : [ "Function create_dnp requires parameter tracks" ] } - '500': + "500": description: "Error: Internal Server Error" content: application/json: schema: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" type: object properties: version: @@ -2785,7 +2779,7 @@ components: schemas: Errors: type: object - required: [ errors ] + required: [errors] properties: errors: type: array @@ -2793,7 +2787,7 @@ components: type: string VersionResponse: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" - type: object required: - version @@ -2802,7 +2796,7 @@ components: type: string InfoResponse: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" - type: object properties: product: @@ -2846,16 +2840,16 @@ components: - f3 - f5 - cursor_up_down - - '0' - - '1' - - '2' - - '3' - - '4' - - '5' - - '6' - - '7' - - '8' - - '9' + - "0" + - "1" + - "2" + - "3" + - "4" + - "5" + - "6" + - "7" + - "8" + - "9" - a - b - c @@ -2934,9 +2928,9 @@ components: maxItems: 8 uniqueItems: true items: - $ref: '#/components/schemas/KeyboardInputName' + $ref: "#/components/schemas/KeyboardInputName" transition: - $ref: '#/components/schemas/InputTransition' + $ref: "#/components/schemas/InputTransition" JoystickInputEvent: type: object additionalProperties: false @@ -2960,9 +2954,9 @@ components: maxItems: 7 uniqueItems: true items: - $ref: '#/components/schemas/JoystickInputName' + $ref: "#/components/schemas/JoystickInputName" transition: - $ref: '#/components/schemas/InputTransition' + $ref: "#/components/schemas/InputTransition" ReleaseAllInputEvent: type: object additionalProperties: false @@ -2974,9 +2968,9 @@ components: const: release_all InputEvent: oneOf: - - $ref: '#/components/schemas/KeyboardInputEvent' - - $ref: '#/components/schemas/JoystickInputEvent' - - $ref: '#/components/schemas/ReleaseAllInputEvent' + - $ref: "#/components/schemas/KeyboardInputEvent" + - $ref: "#/components/schemas/JoystickInputEvent" + - $ref: "#/components/schemas/ReleaseAllInputEvent" InputRequest: type: object additionalProperties: false @@ -2988,7 +2982,7 @@ components: minItems: 1 maxItems: 64 items: - $ref: '#/components/schemas/InputEvent' + $ref: "#/components/schemas/InputEvent" KeyboardInputState: type: object required: @@ -2997,7 +2991,7 @@ components: inputs: type: array items: - $ref: '#/components/schemas/KeyboardInputName' + $ref: "#/components/schemas/KeyboardInputName" JoystickInputState: type: object required: @@ -3012,26 +3006,26 @@ components: inputs: type: array items: - $ref: '#/components/schemas/JoystickInputName' + $ref: "#/components/schemas/JoystickInputName" InputStateResponse: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" - type: object required: - keyboard - joysticks properties: keyboard: - $ref: '#/components/schemas/KeyboardInputState' + $ref: "#/components/schemas/KeyboardInputState" joysticks: type: array minItems: 2 maxItems: 2 items: - $ref: '#/components/schemas/JoystickInputState' + $ref: "#/components/schemas/JoystickInputState" DriveListResponse: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" - type: object properties: drives: @@ -3066,7 +3060,7 @@ components: type: string ConfigListResponse: allOf: - - $ref: '#/components/schemas/Errors' + - $ref: "#/components/schemas/Errors" - type: object properties: categories: From 3060a53f000fb6c151918e4acbfd357c62148a7b Mon Sep 17 00:00:00 2001 From: Christian Gleissner Date: Fri, 5 Jun 2026 18:59:48 +0100 Subject: [PATCH 4/5] Use enum instead of const. Remove input endpoint from U2 since not supportd for that device due to hardware limitations. --- Ultimate_OpenAPI_specs.yaml | 12 +- u2plus-open-api-spec.yaml | 292 +----------------------------------- 2 files changed, 8 insertions(+), 296 deletions(-) diff --git a/Ultimate_OpenAPI_specs.yaml b/Ultimate_OpenAPI_specs.yaml index 5d142f9..b5b13f8 100644 --- a/Ultimate_OpenAPI_specs.yaml +++ b/Ultimate_OpenAPI_specs.yaml @@ -492,7 +492,7 @@ paths: Content-Length: schema: type: integer - const: 2000 + enum: [2000] content: application/octet-stream: schema: @@ -514,7 +514,7 @@ paths: tags: - Machine Control summary: Get REST-injected input state - description: Returns the currently active keyboard and joystick inputs injected through the REST input endpoint. Ultimate 64-class input hardware is required; on Ultimate-II+ hardware this returns HTTP 501. + description: Returns the currently active keyboard and joystick inputs injected through the REST input endpoint. Ultimate 64-class hardware is required; this endpoint is not supported on Ultimate-II/Ultimate-II+ hardware and returns HTTP 501 there. operationId: machine_input_get responses: '200': @@ -524,7 +524,7 @@ paths: schema: $ref: '#/components/schemas/InputStateResponse' '501': - description: Keyboard and joystick injection are not available on this hardware + description: Keyboard and joystick injection are not supported on this hardware content: application/json: schema: @@ -540,8 +540,8 @@ paths: complete batch before applying any event; invalid batches return HTTP 400 and leave the current input state unchanged. When the firmware menu is active, keyboard events are translated to menu keystrokes. - Ultimate 64-class input hardware is required; on Ultimate-II+ hardware - this returns HTTP 501. + Ultimate 64-class hardware is required; this endpoint is not supported + on Ultimate-II/Ultimate-II+ hardware and returns HTTP 501 there. operationId: machine_input_post requestBody: required: true @@ -564,7 +564,7 @@ paths: allOf: - $ref: '#/components/schemas/Errors' '501': - description: Keyboard and joystick injection are not available on this hardware + description: Keyboard and joystick injection are not supported on this hardware content: application/json: schema: diff --git a/u2plus-open-api-spec.yaml b/u2plus-open-api-spec.yaml index 3b39810..e4b64d8 100644 --- a/u2plus-open-api-spec.yaml +++ b/u2plus-open-api-spec.yaml @@ -176,8 +176,7 @@ paths: Returns the active 40x25 firmware menu text-mode screen as two raw matrices. The first 1000 bytes are character bytes; the second 1000 bytes are colour-attribute bytes. This endpoint is intended to be used - with `/v1/machine:menu_button` and `/v1/machine:input` to drive and - inspect the firmware menu over REST. + with `/v1/machine:menu_button` to inspect the firmware menu over REST. tags: - Machine operations responses: @@ -187,7 +186,7 @@ paths: Content-Length: schema: type: integer - const: 2000 + enum: [2000] content: application/octet-stream: schema: @@ -204,93 +203,6 @@ paths: value: errors: - Menu screen unavailable. - /machine:input: - get: - operationId: getInputState - summary: Get REST-injected input state - description: Returns the currently active keyboard and joystick inputs injected through the REST input endpoint. Ultimate 64-class input hardware is required; on Ultimate-II+ hardware this returns HTTP 501. - tags: - - Machine operations - responses: - "200": - description: Input state returned - content: - application/json: - schema: - $ref: "#/components/schemas/InputStateResponse" - examples: - empty: - value: - keyboard: - inputs: [] - joysticks: - - port: 1 - inputs: [] - - port: 2 - inputs: [] - errors: [] - "501": - description: Keyboard and joystick injection are not available on this hardware - content: - application/json: - schema: - allOf: - - $ref: "#/components/schemas/Errors" - post: - operationId: injectInput - summary: Inject keyboard and joystick input - description: | - Applies a validated batch of keyboard, joystick, and release-all events, - then returns the resulting input state. The firmware validates the - complete batch before applying any event; invalid batches return HTTP - 400 and leave the current input state unchanged. When the firmware menu - is active, keyboard events are translated to menu keystrokes. - Ultimate 64-class input hardware is required; on Ultimate-II+ hardware - this returns HTTP 501. - tags: - - Machine operations - requestBody: - required: true - content: - application/json: - schema: - $ref: "#/components/schemas/InputRequest" - examples: - shifted_key_and_joystick: - value: - events: - - kind: joystick - port: 2 - inputs: - - up - - fire - transition: press - - kind: keyboard - inputs: - - left_shift - - a - transition: tap - responses: - "200": - description: Events applied - content: - application/json: - schema: - $ref: "#/components/schemas/InputStateResponse" - "400": - description: Invalid body, content type, or event batch - content: - application/json: - schema: - allOf: - - $ref: "#/components/schemas/Errors" - "501": - description: Keyboard and joystick injection are not available on this hardware - content: - application/json: - schema: - allOf: - - $ref: "#/components/schemas/Errors" /machine:readmem: get: operationId: readMemory @@ -2823,206 +2735,6 @@ components: and bits 4..7 are the background colour. minLength: 2000 maxLength: 2000 - InputTransition: - type: string - enum: - - press - - release - - tap - KeyboardInputName: - type: string - enum: - - inst_del - - return - - cursor_left_right - - f7 - - f1 - - f3 - - f5 - - cursor_up_down - - "0" - - "1" - - "2" - - "3" - - "4" - - "5" - - "6" - - "7" - - "8" - - "9" - - a - - b - - c - - d - - e - - f - - g - - h - - i - - j - - k - - l - - m - - n - - o - - p - - q - - r - - s - - t - - u - - v - - w - - x - - y - - z - - left_shift - - right_shift - - plus - - minus - - period - - colon - - at - - comma - - pound - - star - - semicolon - - clr_home - - equals - - arrow_up - - slash - - arrow_left - - ctrl - - space - - commodore - - run_stop - - restore - description: | - REST input name from the C64 keyboard matrix. `restore` is special: - firmware accepts it only as the sole input in a keyboard event with - transition `tap`. - JoystickInputName: - type: string - enum: - - up - - down - - left - - right - - fire - - fire2 - - fire3 - KeyboardInputEvent: - type: object - additionalProperties: false - required: - - kind - - inputs - - transition - properties: - kind: - type: string - const: keyboard - inputs: - type: array - minItems: 1 - maxItems: 8 - uniqueItems: true - items: - $ref: "#/components/schemas/KeyboardInputName" - transition: - $ref: "#/components/schemas/InputTransition" - JoystickInputEvent: - type: object - additionalProperties: false - required: - - kind - - port - - inputs - - transition - properties: - kind: - type: string - const: joystick - port: - type: integer - enum: - - 1 - - 2 - inputs: - type: array - minItems: 1 - maxItems: 7 - uniqueItems: true - items: - $ref: "#/components/schemas/JoystickInputName" - transition: - $ref: "#/components/schemas/InputTransition" - ReleaseAllInputEvent: - type: object - additionalProperties: false - required: - - kind - properties: - kind: - type: string - const: release_all - InputEvent: - oneOf: - - $ref: "#/components/schemas/KeyboardInputEvent" - - $ref: "#/components/schemas/JoystickInputEvent" - - $ref: "#/components/schemas/ReleaseAllInputEvent" - InputRequest: - type: object - additionalProperties: false - required: - - events - properties: - events: - type: array - minItems: 1 - maxItems: 64 - items: - $ref: "#/components/schemas/InputEvent" - KeyboardInputState: - type: object - required: - - inputs - properties: - inputs: - type: array - items: - $ref: "#/components/schemas/KeyboardInputName" - JoystickInputState: - type: object - required: - - port - - inputs - properties: - port: - type: integer - enum: - - 1 - - 2 - inputs: - type: array - items: - $ref: "#/components/schemas/JoystickInputName" - InputStateResponse: - allOf: - - $ref: "#/components/schemas/Errors" - - type: object - required: - - keyboard - - joysticks - properties: - keyboard: - $ref: "#/components/schemas/KeyboardInputState" - joysticks: - type: array - minItems: 2 - maxItems: 2 - items: - $ref: "#/components/schemas/JoystickInputState" DriveListResponse: allOf: - $ref: "#/components/schemas/Errors" From 85be3b87fe8eeded38c80de4ace58c181c038fcd Mon Sep 17 00:00:00 2001 From: Christian Gleissner Date: Fri, 5 Jun 2026 19:09:31 +0100 Subject: [PATCH 5/5] Remove formatting churn --- Ultimate_OpenAPI_specs.yaml | 20 +- u2plus-open-api-spec.yaml | 480 ++++++++++++++++++------------------ 2 files changed, 253 insertions(+), 247 deletions(-) diff --git a/Ultimate_OpenAPI_specs.yaml b/Ultimate_OpenAPI_specs.yaml index b5b13f8..d391e63 100644 --- a/Ultimate_OpenAPI_specs.yaml +++ b/Ultimate_OpenAPI_specs.yaml @@ -54,16 +54,16 @@ components: - f3 - f5 - cursor_up_down - - '0' - - '1' - - '2' - - '3' - - '4' - - '5' - - '6' - - '7' - - '8' - - '9' + - "0" + - "1" + - "2" + - "3" + - "4" + - "5" + - "6" + - "7" + - "8" + - "9" - a - b - c diff --git a/u2plus-open-api-spec.yaml b/u2plus-open-api-spec.yaml index e4b64d8..45d7acb 100644 --- a/u2plus-open-api-spec.yaml +++ b/u2plus-open-api-spec.yaml @@ -24,7 +24,7 @@ paths: tags: - About responses: - "200": + '200': description: Successful operation. content: application/json: @@ -36,10 +36,10 @@ paths: "errors": [ ] } schema: - $ref: "#/components/schemas/VersionResponse" - "404": + $ref: '#/components/schemas/VersionResponse' + '404': description: Not Found - "504": + '504': description: Gateway Timeout /info: get: @@ -49,19 +49,19 @@ paths: tags: - About responses: - "200": + '200': description: Successful operation. content: application/json: schema: - $ref: "#/components/schemas/InfoResponse" - "404": + $ref: '#/components/schemas/InfoResponse' + '404': description: Not Found content: application/json: schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' /machine:reset: put: operationId: resetMachine @@ -70,14 +70,14 @@ paths: tags: - Machine operations responses: - "200": + '200': description: Successful operation. content: application/json: schema: allOf: - - $ref: "#/components/schemas/Errors" - "404": + - $ref: '#/components/schemas/Errors' + '404': description: Not Found /machine:reboot: put: @@ -87,14 +87,14 @@ paths: tags: - Machine operations responses: - "200": + '200': description: Successful operation. content: application/json: schema: allOf: - - $ref: "#/components/schemas/Errors" - "404": + - $ref: '#/components/schemas/Errors' + '404': description: Not Found /machine:pause: put: @@ -106,14 +106,14 @@ paths: tags: - Machine operations responses: - "200": + '200': description: Successful operation. content: application/json: schema: allOf: - - $ref: "#/components/schemas/Errors" - "404": + - $ref: '#/components/schemas/Errors' + '404': description: Not Found /machine:resume: put: @@ -123,14 +123,14 @@ paths: tags: - Machine operations responses: - "200": + '200': description: Successful operation. content: application/json: schema: allOf: - - $ref: "#/components/schemas/Errors" - "404": + - $ref: '#/components/schemas/Errors' + '404': description: Not Found content: application/json: {} @@ -144,14 +144,14 @@ paths: tags: - Machine operations responses: - "200": + '200': description: Successful operation. content: application/json: schema: allOf: - - $ref: "#/components/schemas/Errors" - "404": + - $ref: '#/components/schemas/Errors' + '404': description: Not Found /machine:menu_button: put: @@ -161,13 +161,13 @@ paths: tags: - Machine operations responses: - "200": + '200': description: Button event queued content: application/json: schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' /machine:menu_screen: get: operationId: getMenuScreen @@ -180,7 +180,7 @@ paths: tags: - Machine operations responses: - "200": + '200': description: Readable 40x25 menu screen returned headers: Content-Length: @@ -190,14 +190,14 @@ paths: content: application/octet-stream: schema: - $ref: "#/components/schemas/MenuScreenBytes" - "404": + $ref: '#/components/schemas/MenuScreenBytes' + '404': description: No readable menu screen is currently available content: application/json: schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' examples: unavailable: value: @@ -235,11 +235,11 @@ paths: minimum: 0 example: 128 responses: - "200": + '200': description: Successful operation. content: application/octet-stream: {} - "400": + '400': description: Bad request content: application/json: @@ -261,8 +261,8 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "404": + - $ref: '#/components/schemas/Errors' + '404': description: Not Found /machine:writemem: put: @@ -272,7 +272,7 @@ paths: With this command, data can be written to C64 memory. To be more exact: this command writes data through DMA, so the memory map that is currently selected is used. Writing to the I/O registers of the 6510 is not possible. - + Data bytes are written in consecutive memory locations. The address argument specifies the memory location in hexadecimal format. The data argument contains a string of bytes in hexadecimal format. The maximum number of bytes written with this method is 128. @@ -299,7 +299,7 @@ paths: type: string example: "1024" responses: - "200": + '200': description: Successful operation. content: application/json: @@ -312,8 +312,8 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "400": + - $ref: '#/components/schemas/Errors' + '400': description: Bad request content: application/json: @@ -330,8 +330,8 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "404": + - $ref: '#/components/schemas/Errors' + '404': description: Not Found post: operationId: writeManyDataToMemoryPost @@ -339,7 +339,7 @@ paths: description: |- With this command, data can be written to C64 memory. The data, passed as a binary attachment, will be written to memory starting from the location indicated by the address argument, which shall be formatted in hexadecimal. - + The data should not wrap around $FFFF. tags: - Machine operations @@ -357,7 +357,7 @@ paths: application/octet-stream: schema: {} responses: - "200": + '200': description: Successful operation. content: application/json: @@ -370,8 +370,8 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "400": + - $ref: '#/components/schemas/Errors' + '400': description: Bad request content: application/json: @@ -388,8 +388,8 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "404": + - $ref: '#/components/schemas/Errors' + '404': description: Not Found /machine:debugreg: get: @@ -401,7 +401,7 @@ paths: tags: - Machine operations responses: - "200": + '200': description: Successful operation. content: application/json: @@ -414,8 +414,8 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "404": + - $ref: '#/components/schemas/Errors' + '404': description: Not Found put: operationId: writeDebugRegister @@ -436,7 +436,7 @@ paths: type: string example: "3F" responses: - "200": + '200': description: Successful operation. content: application/json: @@ -449,8 +449,8 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "404": + - $ref: '#/components/schemas/Errors' + '404': description: Not Found /runners:sidplay: put: @@ -479,7 +479,7 @@ paths: schema: type: string responses: - "200": + '200': description: Successful operation. content: application/json: @@ -496,10 +496,10 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "404": + - $ref: '#/components/schemas/Errors' + '404': description: Not Found - "500": + '500': description: Internal server error content: application/json: @@ -531,7 +531,7 @@ paths: application/octet-stream: schema: {} responses: - "200": + '200': description: Successful operation. content: application/json: @@ -548,10 +548,10 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "404": + - $ref: '#/components/schemas/Errors' + '404': description: Not Found - "500": + '500': description: Internal server error content: application/json: @@ -561,7 +561,7 @@ paths: { "errors" : [ "Undefined subsystem command" ] } - "507": + '507': description: Unknown content: application/json: @@ -589,7 +589,7 @@ paths: schema: type: string responses: - "200": + '200': description: Successful operation. content: application/json: @@ -606,10 +606,10 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "404": + - $ref: '#/components/schemas/Errors' + '404': description: Not Found - "500": + '500': description: Internal server error content: application/json: @@ -619,7 +619,7 @@ paths: { "errors" : [ "Undefined subsystem command" ] } - "507": + '507': description: Unknown content: application/json: @@ -641,7 +641,7 @@ paths: application/octet-stream: schema: {} responses: - "200": + '200': description: Successful operation. content: application/json: @@ -659,10 +659,10 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "404": + - $ref: '#/components/schemas/Errors' + '404': description: Not Found - "500": + '500': description: Internal server error content: application/json: @@ -672,7 +672,7 @@ paths: { "errors" : [ "Undefined subsystem command" ] } - "507": + '507': description: Unknown content: application/json: @@ -701,7 +701,7 @@ paths: schema: type: string responses: - "200": + '200': description: Successful operation. content: application/json: @@ -718,10 +718,10 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "404": + - $ref: '#/components/schemas/Errors' + '404': description: Not Found - "500": + '500': description: Internal server error content: application/json: @@ -731,7 +731,7 @@ paths: { "errors" : [ "Undefined subsystem command" ] } - "507": + '507': description: Unknown content: application/json: @@ -754,7 +754,7 @@ paths: application/octet-stream: schema: {} responses: - "200": + '200': description: Successful operation. content: application/json: @@ -772,10 +772,10 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "404": + - $ref: '#/components/schemas/Errors' + '404': description: Not Found - "500": + '500': description: Internal server error content: application/json: @@ -785,7 +785,7 @@ paths: { "errors" : [ "Undefined subsystem command" ] } - "507": + '507': description: Unknown content: application/json: @@ -814,7 +814,7 @@ paths: schema: type: string responses: - "200": + '200': description: Successful operation. content: application/json: @@ -827,10 +827,10 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "404": + - $ref: '#/components/schemas/Errors' + '404': description: Not Found - "500": + '500': description: Internal server error content: application/json: @@ -840,7 +840,7 @@ paths: { "errors" : [ "Undefined subsystem command" ] } - "507": + '507': description: Unknown content: application/json: @@ -863,13 +863,13 @@ paths: application/octet-stream: schema: {} responses: - "200": + '200': description: Successful operation. content: application/json: schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' examples: OK: value: |- @@ -881,9 +881,9 @@ paths: { "errors" : [ "Function run_prg does not have parameter invalidParameterName", "Function run_prg requires parameter file" ] } - "404": + '404': description: Not Found - "500": + '500': description: Internal server error content: application/json: @@ -893,7 +893,7 @@ paths: { "errors" : [ "Undefined subsystem command" ] } - "507": + '507': description: Unknown content: application/json: @@ -922,7 +922,7 @@ paths: schema: type: string responses: - "200": + '200': description: Successful operation. content: application/json: @@ -939,10 +939,10 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "404": + - $ref: '#/components/schemas/Errors' + '404': description: Not Found - "500": + '500': description: Internal server error content: application/json: @@ -952,7 +952,7 @@ paths: { "errors" : [ "Undefined subsystem command" ] } - "507": + '507': description: Unknown content: application/json: @@ -975,7 +975,7 @@ paths: application/octet-stream: schema: {} responses: - "200": + '200': description: Successful operation. content: application/json: @@ -993,10 +993,10 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "404": + - $ref: '#/components/schemas/Errors' + '404': description: Not Found - "500": + '500': description: Internal server error content: application/json: @@ -1006,7 +1006,7 @@ paths: { "errors" : [ "Undefined subsystem command" ] } - "507": + '507': description: Unknown content: application/json: @@ -1027,7 +1027,7 @@ paths: tags: - Floppy drives responses: - "200": + '200': description: Successful operation. content: application/json: @@ -1080,7 +1080,7 @@ paths: "errors": [] } schema: - $ref: "#/components/schemas/DriveListResponse" + $ref: '#/components/schemas/DriveListResponse' /drives/{drive}:mount: put: operationId: putMountDiskImage @@ -1119,7 +1119,7 @@ paths: The type or format of the disk image.
Valid options are one of the following:
`d64`, `g64`, `d71`, `g71` or `d81` - + When this parameter is omitted, then the API will look at the file extension. name: type required: false @@ -1137,7 +1137,7 @@ paths: schema: type: string responses: - "200": + '200': description: Successful operation. content: application/json: @@ -1158,8 +1158,8 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "400": + - $ref: '#/components/schemas/Errors' + '400': description: Bad Request content: application/json: @@ -1174,9 +1174,9 @@ paths: { "errors" : [ "Invalid Type 'd65'" ] } - "404": + '404': description: Not Found - "500": + '500': description: Internal server error content: application/json: @@ -1186,7 +1186,7 @@ paths: { "errors" : [ "Undefined subsystem command" ] } - "507": + '507': description: Unknown content: application/json: @@ -1226,7 +1226,7 @@ paths: The type or format of the disk image.
Valid options are one of the following:
`d64`, `g64`, `d71`, `g71` or `d81` - + When this parameter is omitted, then the API will look at the file extension. name: type required: false @@ -1246,7 +1246,7 @@ paths: application/octet-stream: schema: {} responses: - "200": + '200': description: Successful operation. content: application/json: @@ -1263,8 +1263,8 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "400": + - $ref: '#/components/schemas/Errors' + '400': description: Bad Request content: application/json: @@ -1274,9 +1274,9 @@ paths: { "errors": [ "Invalid Drive 'c'" ] } - "404": + '404': description: Not Found - "500": + '500': description: Internal server error content: application/json: @@ -1291,7 +1291,7 @@ paths: { 'errors': ['Read operation on file failed'] } - "507": + '507': description: Unknown content: application/json: @@ -1320,7 +1320,7 @@ paths: Valid options are one of the following:
`a`, `b` responses: - "200": + '200': description: Successful operation. content: application/json: @@ -1332,8 +1332,8 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "400": + - $ref: '#/components/schemas/Errors' + '400': description: Bad Request content: application/json: @@ -1345,7 +1345,7 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' /drives/{drive}:remove: put: operationId: putRemoveDisk @@ -1365,7 +1365,7 @@ paths: Valid options are one of the following:
`a`, `b` responses: - "200": + '200': description: Successful operation. content: application/json: @@ -1377,8 +1377,8 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "400": + - $ref: '#/components/schemas/Errors' + '400': description: Bad Request content: application/json: @@ -1390,7 +1390,7 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' /drives/{drive}:unlink: put: operationId: putUnlinkDisk @@ -1411,7 +1411,7 @@ paths: Valid options are one of the following:
`a`, `b` responses: - "200": + '200': description: Successful operation. content: application/json: @@ -1423,8 +1423,8 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "400": + - $ref: '#/components/schemas/Errors' + '400': description: Bad Request content: application/json: @@ -1436,7 +1436,7 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' /drives/{drive}:on: put: operationId: putUnEnableDrive @@ -1456,7 +1456,7 @@ paths: Valid options are one of the following:
`a`, `b` responses: - "200": + '200': description: Successful operation. content: application/json: @@ -1468,8 +1468,8 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "400": + - $ref: '#/components/schemas/Errors' + '400': description: Bad Request content: application/json: @@ -1481,7 +1481,7 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' /drives/{drive}:off: put: operationId: putDisableDrive @@ -1498,11 +1498,11 @@ paths: required: true description: |- Disables disk drive `a` or `b`. It will no longer be accessible on the serial bus. - + Valid options are one of the following:
`a`, `b` responses: - "200": + '200': description: Successful operation. content: application/json: @@ -1514,8 +1514,8 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "400": + - $ref: '#/components/schemas/Errors' + '400': description: Bad Request content: application/json: @@ -1527,7 +1527,7 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' /drives/{drive}:load_rom: put: operationId: putLoadDriveRom @@ -1536,7 +1536,7 @@ paths: Loads a new disk drive ROM into the selected drive.
The `file` parameter points to a file that is already present on the file system of the Ultimate. The size of the ROM file needs to be 16K or 32K, depending on the drive type. - + Loading the ROM is a temporary action, setting the drive type or rebooting the machine will load the default ROM. tags: @@ -1550,7 +1550,7 @@ paths: description: |- Load a new drive ROM in drive `a` or `b`. The size of the ROM file needs to be 16K or 32K, depending on the drive type. - + Valid options are one of the following:
`a`, `b` - in: query @@ -1561,7 +1561,7 @@ paths: schema: type: string responses: - "200": + '200': description: Successful operation. content: application/json: @@ -1573,8 +1573,8 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "400": + - $ref: '#/components/schemas/Errors' + '400': description: Bad Request content: application/json: @@ -1586,7 +1586,7 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' post: operationId: postLoadRom summary: Load disk drive rom @@ -1594,7 +1594,7 @@ paths: With this command a new drive ROM can be loaded into the selected drive. The ROM file is passed as a binary file attachment to the POST request.
The size of the ROM file needs to be 16K or 32K, depending on the drive type. - + Loading the ROM is a temporary action, setting the drive type or rebooting the machine will load the default ROM. tags: - Floppy drives @@ -1607,7 +1607,7 @@ paths: description: |- Load a new drive ROM in drive `a` or `b`. The size of the ROM file needs to be 16K or 32K, depending on the drive type. - + Valid options are one of the following:
`a`, `b` requestBody: @@ -1615,7 +1615,7 @@ paths: application/octet-stream: schema: {} responses: - "200": + '200': description: Successful operation. content: application/json: @@ -1627,8 +1627,8 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "400": + - $ref: '#/components/schemas/Errors' + '400': description: Bad Request content: application/json: @@ -1640,14 +1640,14 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' /drives/{drive}:set_mode: put: operationId: postSetMode summary: Set or update disk image mode description: | Change the drive mode. - + Note that this command will also load the drive ROM. A temporary ROM that was loaded using the ‘load_rom’ command will be lost. tags: @@ -1670,9 +1670,9 @@ paths: - "1571" - "1581" required: true - description: The available values are `1541`, `1571` and `1581`. + description: The available values are `1541`, `1571` and `1581`. responses: - "200": + '200': description: Successful operation. content: application/json: @@ -1684,8 +1684,8 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "400": + - $ref: '#/components/schemas/Errors' + '400': description: Bad Request content: application/json: @@ -1697,7 +1697,7 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' /streams/{streamname}:start: put: operationId: putStartDataStream @@ -1708,7 +1708,7 @@ paths: U64 to know where to send the stream to. The default port number that the data stream is sent to is 11000 for the video stream, 11001 for the audio stream and 11002 for the debug stream. - + A custom port number can be added to the IP address, after a colon separator; e.g. 192.168.178.224:6789 . Note that turning on the video stream will automatically turn off the debug stream. @@ -1736,7 +1736,7 @@ paths: type: string default: video responses: - "200": + '200': description: Successful operation. content: application/json: @@ -1748,8 +1748,8 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "400": + - $ref: '#/components/schemas/Errors' + '400': description: Bad Request content: application/json: @@ -1770,19 +1770,25 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "404": + - $ref: '#/components/schemas/Errors' + '404': description: Not Found content: application/json: examples: "Network Host Resolve Error": - value: { "errors": ["Network Host Resolve Error"] } + value: + { + "errors": [ "Network Host Resolve Error" ] + } "Unrecognized stream name": - value: { "errors": ["Unrecognized stream name 'vdeo'"] } + value: + { + "errors": [ "Unrecognized stream name 'vdeo'" ] + } schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' /streams/{streamname}:stop: put: operationId: putStopDataStream @@ -1803,7 +1809,7 @@ paths: schema: type: string responses: - "200": + '200': description: Successful operation. content: application/json: @@ -1815,8 +1821,8 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "400": + - $ref: '#/components/schemas/Errors' + '400': description: Bad Request content: application/json: @@ -1850,7 +1856,7 @@ paths: tags: - Configuration responses: - "200": + '200': description: Successful operation. content: application/json: @@ -1902,8 +1908,8 @@ paths: "errors": [] } schema: - $ref: "#/components/schemas/ConfigListResponse" - "404": + $ref: '#/components/schemas/ConfigListResponse' + '404': description: Endpoint not found post: operationId: postConfig @@ -1924,7 +1930,7 @@ paths: properties: Drive: type: string - enum: ["Enabled", "Disabled"] + enum: [ "Enabled", "Disabled" ] "Drive Type": type: integer "Drive Bus ID": @@ -1934,7 +1940,7 @@ paths: properties: Drive: type: string - enum: ["Enabled", "Disabled"] + enum: [ "Enabled", "Disabled" ] example: "Drive A Settings": Drive: "Enabled" @@ -1944,7 +1950,7 @@ paths: Drive: "Disabled" responses: - "200": + '200': description: OK /configs/{category}: get: @@ -1952,13 +1958,13 @@ paths: summary: Retrieve config categories description: | This command obtains a list of all the configuration items in the category specified in the URL. Wildcards are allowed. Note that the depth of the specified path is 1. It specifies the category. - + For example: - + ```GET /v1/configs/drive%20a*``` - + returns: - + ``` { "Drive A Settings": { @@ -1985,9 +1991,9 @@ paths: name: category description: | Configuration categories. - + Valid category values are: - + * ```Audio Mixer``` * ```SID Sockets Configuration``` (U64 only) * ```UltiSID Configuration``` @@ -2006,14 +2012,14 @@ paths: * ```Tape Settings``` * ```Drive A Settings``` * ```Drive B Settings``` - + Wildcards are allowed. Use the wildcard * (asterisk) to retrieve the values for all categories at once.. required: true schema: type: string responses: - "200": + '200': description: Successful operation. content: application/json: @@ -2047,14 +2053,14 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' type: object properties: categories: type: array items: type: string - "404": + '404': description: Endpoint not found /configs/{category}/{item}: get: @@ -2083,7 +2089,7 @@ paths: schema: type: string responses: - "200": + '200': description: Successful operation. content: application/json: @@ -2134,21 +2140,21 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' type: object properties: categories: type: array items: type: string - "404": + '404': description: Endpoint not found put: operationId: putConfigCategoryItem summary: Change configuration description: | This command sets a specific configuration item to the value specified in the URL, using the value argument. It is required to specify the full path to the item, although wildcards are allowed.
- + Example: ```PUT /v1/configs/drive%20a*/*bus*?value=9``` will set the ‘Drive Bus ID’ of ‘Drive A Settings’ to 9. tags: - Configuration @@ -2156,7 +2162,7 @@ paths: - in: path description: | Category name.
- + Possible values are:
`Audio Mixer`
`SID Sockets Configuration` (U64 only)
@@ -2197,7 +2203,7 @@ paths: schema: type: string responses: - "200": + '200': description: Successful operation. content: application/json: @@ -2209,8 +2215,8 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" - "400": + - $ref: '#/components/schemas/Errors' + '400': description: Bad Request content: application/json: @@ -2222,19 +2228,19 @@ paths: } schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' /configs:load_from_flash: put: operationId: PutConfigFromFlash summary: Load configuration file from flash description: | With this command, the complete configuration is restored to what is currently written in non-volatile memory. In other words: the ‘saved’ values are loaded into the current configuration. - + **Please note:** This request will receive an "connection reset by peer" instead of an HTTP status code. tags: - Configuration responses: - "200": + '200': description: OK /configs:save_to_flash: put: @@ -2243,9 +2249,9 @@ paths: description: | With this command, the complete configuration is written to non-volatile memory. In other words: the current configuration settings are ‘saved’ and will be loaded once the machine boots. tags: - - Configuration + - Configuration responses: - "200": + '200': description: OK /configs:reset_to_default: put: @@ -2254,9 +2260,9 @@ paths: description: | This command resets the current settings to the factory default. This does not clear or reset the values stored in non-volatile memory. tags: - - Configuration + - Configuration responses: - "200": + '200': description: OK /files/{path}:info: get: @@ -2276,15 +2282,15 @@ paths: description: |- The path to the folder where the disk image will be created. responses: - "200": + '200': description: Successful operation. content: application/json: schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' examples: - "File information - d64": + 'File information - d64': value: |- { "files": { @@ -2295,7 +2301,7 @@ paths: }, "errors": [] } - "File information - d71": + 'File information - d71': value: |- { "files": { @@ -2306,7 +2312,7 @@ paths: }, "errors": [] } - "File information - d81": + 'File information - d81': value: |- { "files": { @@ -2317,7 +2323,7 @@ paths: }, "errors": [] } - "Directory information": + 'Directory information': value: |- { "files": { @@ -2328,26 +2334,26 @@ paths: }, "errors": [] } - "400": + '400': description: "Bad request" content: application/json: schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' examples: "Require parameter tracks": value: |- { "errors" : [ "Function create_dnp requires parameter tracks" ] } - "404": + '404': description: Not found content: application/json: schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' examples: FILE DOESN'T EXIST: value: |- @@ -2392,13 +2398,13 @@ paths: schema: type: string responses: - "200": + '200': description: OK content: application/json: schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' type: object properties: path: @@ -2432,13 +2438,13 @@ paths: "bytes_written": 196608, "errors": [] } - "500": + '500': description: "Error: Internal Server Error" content: application/json: schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' type: object properties: version: @@ -2481,15 +2487,15 @@ paths: type: string example: "-= scs+trc 2024 =-" responses: - "200": + '200': description: Successful operation. content: application/json: schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' examples: - "Successful operation": + 'Successful operation': value: |- { "path": "/Temp/diskimage.d71", @@ -2498,13 +2504,13 @@ paths: "bytes_written": 349696, "errors": [] } - "500": + '500': description: "Error: Internal Server Error" content: application/json: schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' type: object properties: version: @@ -2545,15 +2551,15 @@ paths: type: string example: -= scs+trc =- responses: - "200": + '200': description: Successful operation. content: application/json: schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' examples: - "Successful operation": + 'Successful operation': value: |- { "path": "/Temp/diskimage.d81", @@ -2561,13 +2567,13 @@ paths: "bytes_written": 819200, "errors": [] } - "500": + '500': description: "Error: Internal Server Error" content: application/json: schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' type: object properties: version: @@ -2619,23 +2625,23 @@ paths: tags: - Files responses: - "200": + '200': description: Successful operation. content: application/json: schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' type: object properties: path: type: string example: "/Temp/diskimage.dnp" tracks: - type: integer - minimum: 1 - maximum: 255 - example: 255 + type: integer + minimum: 1 + maximum: 255 + example: 255 diskname: type: string example: "scs+trc 2024" @@ -2651,26 +2657,26 @@ paths: "bytes_written": 16711680, "errors": [] } - "400": + '400': description: "Bad request" content: application/json: schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' examples: "Requires parameter tracks": value: |- { "errors" : [ "Function create_dnp requires parameter tracks" ] } - "500": + '500': description: "Error: Internal Server Error" content: application/json: schema: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' type: object properties: version: @@ -2691,7 +2697,7 @@ components: schemas: Errors: type: object - required: [errors] + required: [ errors ] properties: errors: type: array @@ -2699,7 +2705,7 @@ components: type: string VersionResponse: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' - type: object required: - version @@ -2708,7 +2714,7 @@ components: type: string InfoResponse: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' - type: object properties: product: @@ -2737,7 +2743,7 @@ components: maxLength: 2000 DriveListResponse: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' - type: object properties: drives: @@ -2772,7 +2778,7 @@ components: type: string ConfigListResponse: allOf: - - $ref: "#/components/schemas/Errors" + - $ref: '#/components/schemas/Errors' - type: object properties: categories: