From 86744ebcedadca6c54619c3c73ac8267b24efbc3 Mon Sep 17 00:00:00 2001 From: benarc Date: Wed, 17 Mar 2021 16:56:23 +0000 Subject: [PATCH] Bug --- lnbits/extensions/withdraw/crud.py | 2 +- .../templates/withdraw/_api_docs.html | 27 +++++++++++++++++++ 2 files changed, 28 insertions(+), 1 deletion(-) diff --git a/lnbits/extensions/withdraw/crud.py b/lnbits/extensions/withdraw/crud.py index 64d4373e2..cc7fe3878 100644 --- a/lnbits/extensions/withdraw/crud.py +++ b/lnbits/extensions/withdraw/crud.py @@ -3,7 +3,7 @@ from typing import List, Optional, Union from lnbits.helpers import urlsafe_short_hash from . import db -from .models import WithdrawLink +from .models import WithdrawLink, HashCheck async def create_withdraw_link( diff --git a/lnbits/extensions/withdraw/templates/withdraw/_api_docs.html b/lnbits/extensions/withdraw/templates/withdraw/_api_docs.html index 18a0a5420..75ed9e02e 100644 --- a/lnbits/extensions/withdraw/templates/withdraw/_api_docs.html +++ b/lnbits/extensions/withdraw/templates/withdraw/_api_docs.html @@ -150,3 +150,30 @@ + + + + GET + /withdraw/api/v1/links/<the_hash>/<lnurl_id> +
Headers
+ {"X-Api-Key": <invoice_key>}
+
Body (application/json)
+
+ Returns 201 CREATED (application/json) +
+ {"status": <bool>} +
Curl example
+ curl -X GET {{ request.url_root }}api/v1/links/<the_hash>/<lnurl_id> -H + "X-Api-Key: {{ g.user.wallets[0].inkey }}" + +
+
+