Add Swagger docs at /docs and /openapi.json with split OpenAPI spec

Made-with: Cursor
This commit is contained in:
Michaël
2026-02-28 21:14:27 -03:00
parent bdb4892014
commit 0a6d86c8e8
21 changed files with 679 additions and 0 deletions

View File

@@ -0,0 +1,48 @@
post:
tags: [Public]
summary: Redeem Cashu token
requestBody:
required: true
content:
application/json:
schema:
type: object
required: [token]
properties:
token:
type: string
description: Cashu token (cashuA... or cashuB...)
responses:
"200":
description: Redeem result
content:
application/json:
schema:
type: object
properties:
success:
type: boolean
paid:
type: boolean
amount:
type: integer
invoiceAmount:
type: integer
netAmount:
type: integer
to:
type: string
message:
type: string
"400":
description: Invalid token or address
content:
application/json:
schema:
$ref: "../components/schemas/common.yaml#/ApiError"
"502":
description: Redeem failed
content:
application/json:
schema:
$ref: "../components/schemas/common.yaml#/ApiError"