2021-06-16 03:07:17 +02:00
|
|
|
{
|
|
|
|
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
|
|
"type": "object",
|
|
|
|
"additionalProperties": false,
|
|
|
|
"required": [ "offers" ],
|
|
|
|
"properties": {
|
|
|
|
"offers": {
|
|
|
|
"type": "array",
|
|
|
|
"items": {
|
|
|
|
"type": "object",
|
|
|
|
"additionalProperties": false,
|
2021-07-02 02:11:34 +02:00
|
|
|
"required": [ "offer_id", "active", "single_use", "bolt12", "bolt12_unsigned", "used" ],
|
2021-06-16 03:07:17 +02:00
|
|
|
"properties": {
|
|
|
|
"offer_id": {
|
|
|
|
"type": "hex",
|
|
|
|
"description": "the id of this offer (merkle hash of non-signature fields)",
|
|
|
|
"maxLength": 64,
|
|
|
|
"minLength": 64
|
|
|
|
},
|
|
|
|
"active": {
|
|
|
|
"type": "boolean",
|
|
|
|
"description": "whether this can still be used"
|
|
|
|
},
|
|
|
|
"single_use": {
|
|
|
|
"type": "boolean",
|
|
|
|
"description": "whether this expires as soon as it's paid"
|
|
|
|
},
|
|
|
|
"bolt12": {
|
|
|
|
"type": "string",
|
|
|
|
"description": "the bolt12 encoding of the offer"
|
|
|
|
},
|
2021-07-02 02:11:34 +02:00
|
|
|
"bolt12_unsigned": {
|
|
|
|
"type": "string",
|
|
|
|
"description": "the bolt12 encoding of the offer, without signature"
|
|
|
|
},
|
2021-06-16 03:07:17 +02:00
|
|
|
"used": {
|
|
|
|
"type": "boolean",
|
|
|
|
"description": "True if an associated invoice has been paid"
|
|
|
|
},
|
|
|
|
"label": {
|
|
|
|
"type": "string",
|
|
|
|
"description": "the (optional) user-specified label"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|