2020-05-29 02:00:13 +02:00
|
|
|
{
|
|
|
|
"components": {
|
|
|
|
"schemas": {
|
|
|
|
"ConnectToNodeRequest": {
|
2020-06-08 23:40:58 +09:00
|
|
|
"type": "object",
|
|
|
|
"additionalProperties": false,
|
|
|
|
"properties": {
|
|
|
|
"nodeURI": {
|
|
|
|
"type": "string",
|
|
|
|
"nullable": true,
|
|
|
|
"description": "Node URI in the form `pubkey@endpoint[:port]`"
|
2020-05-29 02:00:13 +02:00
|
|
|
}
|
2020-06-08 23:40:58 +09:00
|
|
|
}
|
2020-05-29 02:00:13 +02:00
|
|
|
},
|
|
|
|
"CreateLightningInvoiceRequest": {
|
|
|
|
"type": "object",
|
|
|
|
"properties": {
|
|
|
|
"amount": {
|
2020-06-08 23:40:58 +09:00
|
|
|
"type": "string",
|
|
|
|
"description": "Amount wrapped in a string, represented in a millistatoshi string. (1000 millisatoshi = 1 satoshi)",
|
|
|
|
"nullable": false
|
2020-05-29 02:00:13 +02:00
|
|
|
},
|
|
|
|
"description": {
|
|
|
|
"type": "string",
|
2020-06-08 23:40:58 +09:00
|
|
|
"nullable": true,
|
|
|
|
"description": "Description of the invoice in the BOLT11"
|
2020-05-29 02:00:13 +02:00
|
|
|
},
|
2022-03-17 10:15:27 +01:00
|
|
|
"descriptionHash": {
|
|
|
|
"type": "string",
|
|
|
|
"format": "hex",
|
|
|
|
"nullable": true,
|
|
|
|
"description": "Description hash of the invoice in the BOLT11"
|
|
|
|
},
|
2020-05-29 02:00:13 +02:00
|
|
|
"expiry": {
|
2021-03-30 04:18:00 +02:00
|
|
|
"description": "Expiration time in seconds",
|
|
|
|
"allOf": [ {"$ref": "#/components/schemas/TimeSpanSeconds"}]
|
2020-05-29 02:00:13 +02:00
|
|
|
},
|
2020-05-29 09:03:07 +09:00
|
|
|
"privateRouteHints": {
|
|
|
|
"type": "boolean",
|
2020-06-08 23:40:58 +09:00
|
|
|
"nullable": true,
|
|
|
|
"default": false,
|
|
|
|
"description": "True if the invoice should include private route hints"
|
2020-05-29 02:00:13 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"LightningChannelData": {
|
|
|
|
"type": "object",
|
|
|
|
"additionalProperties": false,
|
|
|
|
"properties": {
|
|
|
|
"remoteNode": {
|
|
|
|
"type": "string",
|
2020-06-08 23:40:58 +09:00
|
|
|
"nullable": false,
|
|
|
|
"description": "The public key of the node (Node ID)"
|
2020-05-29 02:00:13 +02:00
|
|
|
},
|
|
|
|
"isPublic": {
|
2020-06-08 23:40:58 +09:00
|
|
|
"type": "boolean",
|
|
|
|
"description": "Whether the node is public"
|
2020-05-29 02:00:13 +02:00
|
|
|
},
|
|
|
|
"isActive": {
|
2020-06-08 23:40:58 +09:00
|
|
|
"type": "boolean",
|
|
|
|
"description": "Whether the node is online"
|
2020-05-29 02:00:13 +02:00
|
|
|
},
|
|
|
|
"capacity": {
|
2020-06-08 23:40:58 +09:00
|
|
|
"type": "string",
|
|
|
|
"description": "The capacity of the channel in millisatoshi",
|
|
|
|
"nullable": false
|
2020-05-29 02:00:13 +02:00
|
|
|
},
|
|
|
|
"localBalance": {
|
2020-06-08 23:40:58 +09:00
|
|
|
"type": "string",
|
|
|
|
"description": "The local balance of the channel in millisatoshi",
|
|
|
|
"nullable": false
|
2020-05-29 02:00:13 +02:00
|
|
|
},
|
|
|
|
"channelPoint": {
|
|
|
|
"type": "string",
|
|
|
|
"nullable": true
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
2022-02-17 10:01:39 +01:00
|
|
|
"LightningPaymentData": {
|
|
|
|
"type": "object",
|
|
|
|
"additionalProperties": false,
|
|
|
|
"properties": {
|
2022-04-12 11:01:58 +02:00
|
|
|
"id": {
|
|
|
|
"type": "string",
|
|
|
|
"description": "The payment's ID"
|
|
|
|
},
|
|
|
|
"status": {
|
|
|
|
"$ref": "#/components/schemas/LightningPaymentStatus"
|
|
|
|
},
|
|
|
|
"BOLT11": {
|
|
|
|
"type": "string",
|
|
|
|
"description": "The BOLT11 representation of the payment",
|
|
|
|
"nullable": false
|
|
|
|
},
|
|
|
|
"paymentHash": {
|
|
|
|
"type": "string",
|
|
|
|
"description": "The payment hash",
|
|
|
|
"nullable": false
|
|
|
|
},
|
|
|
|
"preimage": {
|
|
|
|
"type": "string",
|
|
|
|
"description": "The payment preimage (available when status is complete)"
|
|
|
|
},
|
|
|
|
"createdAt": {
|
|
|
|
"description": "The unix timestamp when the payment got created",
|
|
|
|
"nullable": true,
|
|
|
|
"allOf": [ {"$ref": "#/components/schemas/UnixTimestamp"}]
|
|
|
|
},
|
2022-02-17 10:01:39 +01:00
|
|
|
"totalAmount": {
|
|
|
|
"type": "string",
|
|
|
|
"description": "The total amount (including fees) in millisatoshi"
|
|
|
|
},
|
|
|
|
"feeAmount": {
|
|
|
|
"type": "string",
|
|
|
|
"description": "The total fees in millisatoshi"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
2020-05-29 02:00:13 +02:00
|
|
|
"LightningInvoiceData": {
|
|
|
|
"type": "object",
|
|
|
|
"additionalProperties": false,
|
|
|
|
"properties": {
|
|
|
|
"id": {
|
|
|
|
"type": "string",
|
2020-06-08 23:40:58 +09:00
|
|
|
"description": "The invoice's ID"
|
2020-05-29 02:00:13 +02:00
|
|
|
},
|
|
|
|
"status": {
|
|
|
|
"$ref": "#/components/schemas/LightningInvoiceStatus"
|
|
|
|
},
|
2020-06-08 23:40:58 +09:00
|
|
|
"BOLT11": {
|
2020-05-29 02:00:13 +02:00
|
|
|
"type": "string",
|
2020-06-08 23:40:58 +09:00
|
|
|
"description": "The BOLT11 representation of the invoice",
|
|
|
|
"nullable": false
|
2020-05-29 02:00:13 +02:00
|
|
|
},
|
|
|
|
"paidAt": {
|
2020-06-08 23:40:58 +09:00
|
|
|
"description": "The unix timestamp when the invoice got paid",
|
2021-03-30 04:18:00 +02:00
|
|
|
"nullable": true,
|
|
|
|
"allOf": [ {"$ref": "#/components/schemas/UnixTimestamp"}]
|
2020-05-29 02:00:13 +02:00
|
|
|
},
|
|
|
|
"expiresAt": {
|
2021-03-30 04:18:00 +02:00
|
|
|
"description": "The unix timestamp when the invoice expires",
|
|
|
|
"allOf": [ {"$ref": "#/components/schemas/UnixTimestamp"}]
|
2020-05-29 02:00:13 +02:00
|
|
|
},
|
|
|
|
"amount": {
|
2020-06-08 23:40:58 +09:00
|
|
|
"type": "string",
|
|
|
|
"description": "The amount of the invoice in millisatoshi"
|
2020-05-29 02:00:13 +02:00
|
|
|
},
|
|
|
|
"amountReceived": {
|
2020-06-08 23:40:58 +09:00
|
|
|
"type": "string",
|
|
|
|
"description": "The amount received in millisatoshi"
|
2020-05-29 02:00:13 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"LightningInvoiceStatus": {
|
|
|
|
"type": "string",
|
|
|
|
"description": "",
|
|
|
|
"x-enumNames": [
|
|
|
|
"Unpaid",
|
|
|
|
"Paid",
|
|
|
|
"Expired"
|
|
|
|
],
|
|
|
|
"enum": [
|
|
|
|
"Unpaid",
|
|
|
|
"Paid",
|
|
|
|
"Expired"
|
|
|
|
]
|
|
|
|
},
|
2022-04-12 11:01:58 +02:00
|
|
|
"LightningPaymentStatus": {
|
|
|
|
"type": "string",
|
|
|
|
"description": "",
|
|
|
|
"x-enumNames": [
|
|
|
|
"Unknown",
|
|
|
|
"Pending",
|
|
|
|
"Complete",
|
|
|
|
"Failed"
|
|
|
|
],
|
|
|
|
"enum": [
|
|
|
|
"Unknown",
|
|
|
|
"Pending",
|
|
|
|
"Complete",
|
|
|
|
"Failed"
|
|
|
|
]
|
|
|
|
},
|
2020-05-29 02:00:13 +02:00
|
|
|
"LightningNodeInformationData": {
|
|
|
|
"type": "object",
|
|
|
|
"properties": {
|
2020-06-08 23:40:58 +09:00
|
|
|
"nodeURIs": {
|
2020-05-29 02:00:13 +02:00
|
|
|
"type": "array",
|
2020-06-08 23:40:58 +09:00
|
|
|
"description": "Node URIs to connect to this node in the form `pubkey@endpoint[:port]`",
|
2020-05-29 02:00:13 +02:00
|
|
|
"items": {
|
|
|
|
"type": "string"
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"blockHeight": {
|
|
|
|
"type": "integer",
|
2020-06-08 23:40:58 +09:00
|
|
|
"description": "The block height of the lightning node"
|
2022-09-28 02:34:34 +02:00
|
|
|
},
|
|
|
|
"alias": {
|
|
|
|
"type": "string",
|
|
|
|
"nullable": true,
|
|
|
|
"description": "The alias of the lightning node"
|
|
|
|
},
|
|
|
|
"color": {
|
|
|
|
"type": "string",
|
|
|
|
"nullable": true,
|
|
|
|
"description": "The color attribute of the lightning node"
|
|
|
|
},
|
|
|
|
"version": {
|
|
|
|
"type": "string",
|
|
|
|
"nullable": true,
|
|
|
|
"description": "The version name of the lightning node"
|
|
|
|
},
|
|
|
|
"peersCount": {
|
|
|
|
"type": "integer",
|
|
|
|
"nullable": true,
|
|
|
|
"description": "The number of peers"
|
|
|
|
},
|
|
|
|
"activeChannelsCount": {
|
|
|
|
"type": "integer",
|
|
|
|
"nullable": true,
|
|
|
|
"description": "The number of active channels"
|
|
|
|
},
|
|
|
|
"inactiveChannelsCount": {
|
|
|
|
"type": "integer",
|
|
|
|
"nullable": true,
|
|
|
|
"description": "The number of inactive channels"
|
|
|
|
},
|
|
|
|
"pendingChannelsCount": {
|
|
|
|
"type": "integer",
|
|
|
|
"nullable": true,
|
|
|
|
"description": "The number of pending channels"
|
2020-05-29 02:00:13 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
2022-06-23 06:42:28 +02:00
|
|
|
"LightningNodeBalanceData": {
|
|
|
|
"type": "object",
|
|
|
|
"properties": {
|
|
|
|
"onchain": {
|
|
|
|
"type": "object",
|
|
|
|
"description": "On-chain balance of the Lightning node",
|
|
|
|
"nullable": true,
|
|
|
|
"$ref": "#/components/schemas/OnchainBalanceData"
|
|
|
|
},
|
|
|
|
"offchain": {
|
|
|
|
"type": "object",
|
|
|
|
"description": "Off-chain balance of the Lightning node",
|
|
|
|
"nullable": true,
|
|
|
|
"$ref": "#/components/schemas/OffchainBalanceData"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"OnchainBalanceData": {
|
|
|
|
"type": "object",
|
|
|
|
"properties": {
|
|
|
|
"confirmed": {
|
|
|
|
"type": "string",
|
2022-07-08 10:55:26 +09:00
|
|
|
"description": "The confirmed amount in satoshi",
|
2022-06-23 06:42:28 +02:00
|
|
|
"nullable": true
|
|
|
|
},
|
|
|
|
"unconfirmed": {
|
|
|
|
"type": "string",
|
2022-07-08 10:55:26 +09:00
|
|
|
"description": "The unconfirmed amount in satoshi",
|
2022-06-23 06:42:28 +02:00
|
|
|
"nullable": true
|
|
|
|
},
|
|
|
|
"reserved": {
|
|
|
|
"type": "string",
|
2022-07-08 10:55:26 +09:00
|
|
|
"description": "The reserved amount in satoshi",
|
2022-06-23 06:42:28 +02:00
|
|
|
"nullable": true
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"OffchainBalanceData": {
|
|
|
|
"type": "object",
|
|
|
|
"properties": {
|
|
|
|
"opening": {
|
|
|
|
"type": "string",
|
|
|
|
"description": "The amount of current channel openings in millisatoshi",
|
|
|
|
"nullable": true
|
|
|
|
},
|
|
|
|
"local": {
|
|
|
|
"type": "string",
|
|
|
|
"description": "The amount that is available on the local end of active channels in millisatoshi",
|
|
|
|
"nullable": true
|
|
|
|
},
|
|
|
|
"remote": {
|
|
|
|
"type": "string",
|
|
|
|
"description": "The amount that is available on the remote end of active channels in millisatoshi",
|
|
|
|
"nullable": true
|
|
|
|
},
|
|
|
|
"closing": {
|
|
|
|
"type": "string",
|
|
|
|
"description": "The amount of current channel closings in millisatoshi",
|
|
|
|
"nullable": true
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
2020-05-29 02:00:13 +02:00
|
|
|
"PayLightningInvoiceRequest": {
|
|
|
|
"type": "object",
|
|
|
|
"properties": {
|
2020-06-08 23:40:58 +09:00
|
|
|
"BOLT11": {
|
2020-05-29 02:00:13 +02:00
|
|
|
"type": "string",
|
2020-06-08 23:40:58 +09:00
|
|
|
"description": "The BOLT11 of the invoice to pay"
|
2022-02-17 10:01:39 +01:00
|
|
|
},
|
2022-05-18 07:57:36 +02:00
|
|
|
"amount": {
|
|
|
|
"type": "string",
|
|
|
|
"description": "Optional explicit payment amount in millisatoshi (if specified, it overrides the BOLT11 amount)",
|
|
|
|
"nullable": true
|
|
|
|
},
|
2022-02-17 10:01:39 +01:00
|
|
|
"maxFeePercent": {
|
|
|
|
"type": "string",
|
|
|
|
"format": "float",
|
|
|
|
"nullable": true,
|
|
|
|
"description": "The fee limit expressed as a percentage of the payment amount",
|
|
|
|
"example": "6.15"
|
|
|
|
},
|
|
|
|
"maxFeeFlat": {
|
|
|
|
"type": "string",
|
|
|
|
"nullable": true,
|
|
|
|
"description": "The fee limit expressed as a fixed amount in satoshi",
|
|
|
|
"example": "21"
|
2020-05-29 02:00:13 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"OpenLightningChannelRequest": {
|
|
|
|
"type": "object",
|
|
|
|
"additionalProperties": false,
|
|
|
|
"properties": {
|
2020-06-08 23:40:58 +09:00
|
|
|
"nodeURI": {
|
|
|
|
"type": "string",
|
|
|
|
"description": "Node URI in the form `pubkey@endpoint[:port]`"
|
2020-05-29 02:00:13 +02:00
|
|
|
},
|
|
|
|
"channelAmount": {
|
2020-06-08 23:40:58 +09:00
|
|
|
"type": "string",
|
|
|
|
"description": "The amount to fund (in satoshi)"
|
2020-05-29 02:00:13 +02:00
|
|
|
},
|
|
|
|
"feeRate": {
|
|
|
|
"type": "number",
|
2020-06-08 23:40:58 +09:00
|
|
|
"description": "The amount to fund (in satoshi per byte)"
|
2020-05-29 02:00:13 +02:00
|
|
|
}
|
2020-06-08 23:40:58 +09:00
|
|
|
}
|
2020-05-29 02:00:13 +02:00
|
|
|
}
|
|
|
|
}
|
2020-05-29 10:04:28 +02:00
|
|
|
}
|
2020-05-29 02:00:13 +02:00
|
|
|
}
|