Add Swagger docs at /docs and /openapi.json with split OpenAPI spec
Made-with: Cursor
This commit is contained in:
48
backend/openapi/path-items/deposit-redeem-cashu.yaml
Normal file
48
backend/openapi/path-items/deposit-redeem-cashu.yaml
Normal 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"
|
||||
Reference in New Issue
Block a user