From 0595d438aaa163dd33ed00748026698a411a0861 Mon Sep 17 00:00:00 2001 From: Adithya Vardhan Date: Thu, 31 Jul 2025 18:56:27 +0530 Subject: [PATCH] NIP-47: add state to transactions (#1933) --- 47.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/47.md b/47.md index 298b3992..1bbbcb3a 100644 --- a/47.md +++ b/47.md @@ -335,6 +335,7 @@ Response: "result_type": "make_invoice", "result": { "type": "incoming", // "incoming" for invoices, "outgoing" for payments + "state": "pending", "invoice": "string", // encoded invoice, optional "description": "string", // invoice's description, optional "description_hash": "string", // invoice's description hash, optional @@ -368,6 +369,7 @@ Response: "result_type": "lookup_invoice", "result": { "type": "incoming", // "incoming" for invoices, "outgoing" for payments + "state": "pending", // can be "pending", "settled", "expired" (for invoices) or "failed" (for payments) "invoice": "string", // encoded invoice, optional "description": "string", // invoice's description, optional "description_hash": "string", // invoice's description hash, optional @@ -416,6 +418,7 @@ Response: "transactions": [ { "type": "incoming", // "incoming" for invoices, "outgoing" for payments + "state": "pending", // can be "pending", "settled", "expired" (for invoices) or "failed" (for payments) "invoice": "string", // encoded invoice, optional "description": "string", // invoice's description, optional "description_hash": "string", // invoice's description hash, optional @@ -492,6 +495,7 @@ Notification: "notification_type": "payment_received", "notification": { "type": "incoming", + "state": "settled", "invoice": "string", // encoded invoice "description": "string", // invoice's description, optional "description_hash": "string", // invoice's description hash, optional @@ -517,6 +521,7 @@ Notification: "notification_type": "payment_sent", "notification": { "type": "outgoing", + "state": "settled", "invoice": "string", // encoded invoice "description": "string", // invoice's description, optional "description_hash": "string", // invoice's description hash, optional