From 1a2c30629ec95b27c29cf99e98c7cd311def7d0f Mon Sep 17 00:00:00 2001 From: Vlad Stan Date: Mon, 23 Mar 2026 15:13:16 +0200 Subject: [PATCH 1/9] feat: basic lnurlp payments --- integration/002_lnurl_live.jmx | 521 +++++++++++++++++++++++++++++++++ 1 file changed, 521 insertions(+) create mode 100644 integration/002_lnurl_live.jmx diff --git a/integration/002_lnurl_live.jmx b/integration/002_lnurl_live.jmx new file mode 100644 index 00000000..9e0f2dfa --- /dev/null +++ b/integration/002_lnurl_live.jmx @@ -0,0 +1,521 @@ + + + + + false + false + + + + + + + + + + + host + ${__property(host,,guiltyeland1.lnbits.com)} + = + + + scheme + ${__property(scheme,,https)} + = + + + port + ${__property(port,,)} + = + + + thinkTime + 300 + = + + + paymentCountPerLnurlp + 5 + = + + + mirrorPort + ${__property(mirrorPort,,8500)} + = + + + configPath + ${__BeanShell(import org.apache.jmeter.services.FileServer; FileServer.getFileServer().getBaseDir();)} + = + + + + + + + + + ${host} + ${port} + ${scheme} + + + 6 + + + + + + 1 + 1 + false + stopthread + + false + 1 + + false + + + + + + + false + false + + + + true + ${paymentCountPerLnurlp} + + + + 1 + ${paymentCountPerLnurlp} + 1 + lnurlpPaymentCounter + + true + + + + true + false + + + + true + + + + false + { + "res": { + "tag": "payRequest", + "callback": "https://guiltyeland1.lnbits.com/lnurlp/api/v1/lnurl/cb/3hqfs7", + "minSendable": 10000, + "maxSendable": 100000, + "metadata": "[[\"text/plain\", \"test many payments\"]]" + }, + "lnurl": "LNURL1DP68GURN8GHJ7EM4D9K8G7T9D3SKUEP39EKXUCNFW3EJUCM0D5HKCMN4WFK8QTENDPCKVUEHX9JDQL", + "unit": "sat", + "amount": 20000, + "comment": "", + "internalMemo": null +} + = + + + + demo.lnbits.com + + https + utf-8 + /api/v1/payments/lnurl + POST + true + false + true + false + true + + HttpClient4 + + + + + + + + Accept + application/json, text/plain, */* + + + X-Api-Key + 96fd9f927311455c902c790c343143bb + + + Content-Type + application/json;charset=utf-8 + + + + + + + 200 + + + Assertion.response_code + false + 8 + + + + extra.success_action + + false + false + false + false + + + + paymenHash + payment_hash + 0 + no-paymenthash + + + + + 100 + for the webhook to be called + + + + + + false + + saveConfig + + + true + true + true + + true + true + true + true + false + true + true + false + false + false + true + false + false + false + true + 0 + true + true + true + true + true + true + + + + + + + false + + saveConfig + + + true + true + true + + true + true + true + true + false + true + true + false + false + false + true + false + false + false + true + 0 + true + true + true + true + true + true + + + + + + + false + + saveConfig + + + true + true + true + + true + true + true + true + false + true + true + false + false + false + true + false + false + false + true + 0 + true + true + true + true + true + true + + + + + + + false + + saveConfig + + + true + true + true + + true + true + true + true + false + true + true + false + false + false + true + false + false + false + true + 0 + true + true + true + true + true + true + + + + 100 + true + (wallet){1} + + + + false + + saveConfig + + + true + true + true + + true + true + true + true + false + true + true + false + false + false + true + false + false + false + true + 0 + true + true + true + true + true + true + + + + + + + false + + saveConfig + + + true + true + true + + true + true + true + true + false + true + true + false + false + false + true + false + false + false + true + 0 + true + true + true + true + true + true + + + + + + + + 8500 + 0 + 25 + + + + 8888 + + windowsupdate\.microsoft\.com.* + (?i).*\.(bmp|css|js|gif|ico|jpe?g|png|swf|eot|otf|ttf|mp4|woff|woff2) + .*msg\.yahoo\.com.* + www\.download\.windowsupdate\.com.* + toolbarqueries\.google\..* + http?://self-repair\.mozilla\.org.* + tiles.*\.mozilla\.com.* + .*detectportal\.firefox\.com.* + us\.update\.toolbar\.yahoo\.com.* + .*\.google\.com.*/safebrowsing/.* + api\.bing\.com.* + toolbar\.google\.com.* + .*yimg\.com.* + toolbar\.msn\.com.* + (?i).*\.(bmp|css|js|gif|ico|jpe?g|png|swf|eot|otf|ttf|mp4|woff|woff2)[\?;].* + toolbar\.avg\.com/.* + www\.google-analytics\.com.* + pgq\.yahoo\.com.* + safebrowsing.*\.google\.com.* + sqm\.microsoft\.com.* + g\.msn.* + clients.*\.google.* + .*toolbar\.yahoo\.com.* + geo\.yahoo\.com.* + + + true + 4 + false + + false + true + true + false + true + + + false + + 0 + + true + UTF-8 + + + + false + + saveConfig + + + true + true + true + + true + true + true + true + true + true + true + true + true + true + false + true + true + true + true + 0 + true + true + true + true + true + true + true + true + + + recording.xml + + + + + + From 13fb5cfc7c722f81e8580628c06306099b99124f Mon Sep 17 00:00:00 2001 From: Vlad Stan Date: Mon, 23 Mar 2026 15:34:37 +0200 Subject: [PATCH 2/9] feat: pay back and forth --- integration/002_lnurl_live.jmx | 292 +++++++++++++++++++++------------ 1 file changed, 185 insertions(+), 107 deletions(-) diff --git a/integration/002_lnurl_live.jmx b/integration/002_lnurl_live.jmx index 9e0f2dfa..92e2a11b 100644 --- a/integration/002_lnurl_live.jmx +++ b/integration/002_lnurl_live.jmx @@ -35,12 +35,7 @@ paymentCountPerLnurlp - 5 - = - - - mirrorPort - ${__property(mirrorPort,,8500)} + 3 = @@ -99,7 +94,7 @@ true - + true false @@ -113,7 +108,98 @@ { "res": { "tag": "payRequest", - "callback": "https://guiltyeland1.lnbits.com/lnurlp/api/v1/lnurl/cb/3hqfs7", + "callback": "https://guiltyeland1.lnbits.com/lnurlp/api/v1/lnurl/cb/KJPijT", + "minSendable": 10000, + "maxSendable": 100000, + "metadata": "[[\"text/plain\", \"test many payments\"]]" + }, + "lnurl": "LNURL1DP68GURN8GHJ7EM4D9K8G7T9D3SKUEP39EKXUCNFW3EJUCM0D5HKCMN4WFK8QTENDPCKVUEHX9JDQL", + "unit": "sat", + "amount": 10000, + "comment": "", + "internalMemo": null +} + = + + + + demo.lnbits.com + + https + utf-8 + /api/v1/payments/lnurl + POST + true + false + true + false + true + + HttpClient4 + + + + + + + + Accept + application/json, text/plain, */* + + + X-Api-Key + 96fd9f927311455c902c790c343143bb + + + Content-Type + application/json;charset=utf-8 + + + + + + + 200 + + + Assertion.response_code + false + 8 + + + + extra.success_action + + false + false + false + false + + + + paymenHash + payment_hash + 0 + no-paymenthash + + + + + + true + false + + + + true + + + + false + { + "res": { + "tag": "payRequest", + "callback": "https://guiltyeland1.lnbits.com/lnurlp/api/v1/lnurl/cb/KJPijT", "minSendable": 10000, "maxSendable": 100000, "metadata": "[[\"text/plain\", \"test many payments\"]]" @@ -189,11 +275,97 @@ - - 100 - for the webhook to be called - - + + + true + false + + + + true + + + + false + { + "res": { + "tag": "payRequest", + "callback": "https://demo.lnbits.com/lnurlp/api/v1/lnurl/cb/et5tSf", + "minSendable": 10000, + "maxSendable": 100000, + "metadata": "[[\"text/plain\", \"SaaS instances pay me\"]]" + }, + "lnurl": "LNURL1DP68GURN8GHJ7ER9D4HJUMRWVF5HGUEWVDHK6TMVDE6HYMRS9AJHGDT52DNQ97CEPF", + "unit": "sat", + "amount": 10000, + "comment": "", + "internalMemo": null +} + = + + + + guiltyeland1.lnbits.com + + https + utf-8 + /api/v1/payments/lnurl + POST + true + false + true + false + true + + HttpClient4 + + + + + + + + Accept + application/json, text/plain, */* + + + X-Api-Key + 12084246eef14de2ac5b216ec49759ad + + + Content-Type + application/json;charset=utf-8 + + + + + + + 200 + + + Assertion.response_code + false + 8 + + + + extra.success_action + + false + false + false + false + + + + paymenHash + payment_hash + 0 + no-paymenthash + + + @@ -422,100 +594,6 @@ - - 8500 - 0 - 25 - - - - 8888 - - windowsupdate\.microsoft\.com.* - (?i).*\.(bmp|css|js|gif|ico|jpe?g|png|swf|eot|otf|ttf|mp4|woff|woff2) - .*msg\.yahoo\.com.* - www\.download\.windowsupdate\.com.* - toolbarqueries\.google\..* - http?://self-repair\.mozilla\.org.* - tiles.*\.mozilla\.com.* - .*detectportal\.firefox\.com.* - us\.update\.toolbar\.yahoo\.com.* - .*\.google\.com.*/safebrowsing/.* - api\.bing\.com.* - toolbar\.google\.com.* - .*yimg\.com.* - toolbar\.msn\.com.* - (?i).*\.(bmp|css|js|gif|ico|jpe?g|png|swf|eot|otf|ttf|mp4|woff|woff2)[\?;].* - toolbar\.avg\.com/.* - www\.google-analytics\.com.* - pgq\.yahoo\.com.* - safebrowsing.*\.google\.com.* - sqm\.microsoft\.com.* - g\.msn.* - clients.*\.google.* - .*toolbar\.yahoo\.com.* - geo\.yahoo\.com.* - - - true - 4 - false - - false - true - true - false - true - - - false - - 0 - - true - UTF-8 - - - - false - - saveConfig - - - true - true - true - - true - true - true - true - true - true - true - true - true - true - false - true - true - true - true - 0 - true - true - true - true - true - true - true - true - - - recording.xml - - - From dbb2325de3a6bb4b85498f274118749ec07a8f17 Mon Sep 17 00:00:00 2001 From: Vlad Stan Date: Mon, 23 Mar 2026 16:12:34 +0200 Subject: [PATCH 3/9] feat:check webhook --- integration/002_lnurl_live.jmx | 172 +++++++++++++++++++++++++++++++-- 1 file changed, 165 insertions(+), 7 deletions(-) diff --git a/integration/002_lnurl_live.jmx b/integration/002_lnurl_live.jmx index 92e2a11b..3be784b2 100644 --- a/integration/002_lnurl_live.jmx +++ b/integration/002_lnurl_live.jmx @@ -28,14 +28,9 @@ ${__property(port,,)} = - - thinkTime - 300 - = - paymentCountPerLnurlp - 3 + 1 = @@ -185,13 +180,99 @@ + + true + false + + + + 5000 + for the webhook to be called + + + + + true + false + + + + 20000 + for the webhook to be called + + + + + + + guiltyeland1.lnbits.com + + https + UTF-8 + /api/v1/payments/${paymenHash} + GET + true + false + true + false + + + + + + + + + X-Api-Key + 12084246eef14de2ac5b216ec49759ad + + + + + + + 200 + + + Assertion.response_code + false + 8 + + + + $.details.extra.wh_success + true + true + false + false + false + + + + $.details.extra.wh_message + OK + true + false + false + false + + + + javascript + + ${configPath}/scripts/lnurl_check_webhook_response.js + true + + + + + true false - true @@ -214,6 +295,7 @@ + true demo.lnbits.com https @@ -276,6 +358,82 @@ + + true + false + + + + 20000 + for the webhook to be called + + + + + + + guiltyeland1.lnbits.com + + https + UTF-8 + /api/v1/payments/${paymenHash} + GET + true + false + true + false + + + + + + + + + X-Api-Key + 12084246eef14de2ac5b216ec49759ad + + + + + + + 200 + + + Assertion.response_code + false + 8 + + + + $.details.extra.wh_success + true + true + false + false + false + + + + $.details.extra.wh_message + OK + true + false + false + false + + + + javascript + + ${configPath}/scripts/lnurl_check_webhook_response.js + true + + + + + true false From 948318b91437e99521e78a3dd237d216e7dc9ea0 Mon Sep 17 00:00:00 2001 From: Vlad Stan Date: Mon, 23 Mar 2026 16:22:46 +0200 Subject: [PATCH 4/9] feat: may threads --- integration/002_lnurl_live.jmx | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/integration/002_lnurl_live.jmx b/integration/002_lnurl_live.jmx index 3be784b2..9884e66a 100644 --- a/integration/002_lnurl_live.jmx +++ b/integration/002_lnurl_live.jmx @@ -30,7 +30,7 @@ paymentCountPerLnurlp - 1 + 5 = @@ -56,10 +56,10 @@ - 1 - 1 + 20 + 100 false - stopthread + continue false 1 @@ -191,7 +191,7 @@ - + true false @@ -358,7 +358,7 @@ - + true false From 40e00cc38d0287ff7ab867fd8feb4d05579793bb Mon Sep 17 00:00:00 2001 From: Vlad Stan Date: Mon, 23 Mar 2026 16:29:37 +0200 Subject: [PATCH 5/9] fix: parametrize --- integration/002_lnurl_live.jmx | 21 +++++++++++++-------- 1 file changed, 13 insertions(+), 8 deletions(-) diff --git a/integration/002_lnurl_live.jmx b/integration/002_lnurl_live.jmx index 9884e66a..6d712373 100644 --- a/integration/002_lnurl_live.jmx +++ b/integration/002_lnurl_live.jmx @@ -38,6 +38,11 @@ ${__BeanShell(import org.apache.jmeter.services.FileServer; FileServer.getFileServer().getBaseDir();)} = + + lnurlLinkId + KJPijT + = + @@ -56,8 +61,8 @@ - 20 - 100 + 1 + 1 false continue @@ -103,7 +108,7 @@ { "res": { "tag": "payRequest", - "callback": "https://guiltyeland1.lnbits.com/lnurlp/api/v1/lnurl/cb/KJPijT", + "callback": "${scheme}://${host}/lnurlp/api/v1/lnurl/cb/${lnurlLinkId}", "minSendable": 10000, "maxSendable": 100000, "metadata": "[[\"text/plain\", \"test many payments\"]]" @@ -205,7 +210,7 @@ - guiltyeland1.lnbits.com + ${host} https UTF-8 @@ -273,6 +278,7 @@ + true @@ -280,7 +286,7 @@ { "res": { "tag": "payRequest", - "callback": "https://guiltyeland1.lnbits.com/lnurlp/api/v1/lnurl/cb/KJPijT", + "callback": "${scheme}://${host}/lnurlp/api/v1/lnurl/cb/${lnurlLinkId}", "minSendable": 10000, "maxSendable": 100000, "metadata": "[[\"text/plain\", \"test many payments\"]]" @@ -295,7 +301,6 @@ - true demo.lnbits.com https @@ -372,7 +377,7 @@ - guiltyeland1.lnbits.com + ${host} https UTF-8 @@ -463,7 +468,7 @@ - guiltyeland1.lnbits.com + ${host} https utf-8 From 5d82174a2c14fd8bbae322b09951b08c812532ea Mon Sep 17 00:00:00 2001 From: Vlad Stan Date: Mon, 23 Mar 2026 16:40:47 +0200 Subject: [PATCH 6/9] feat: more params --- integration/002_lnurl_live.jmx | 24 +++++++++++++++++------- 1 file changed, 17 insertions(+), 7 deletions(-) diff --git a/integration/002_lnurl_live.jmx b/integration/002_lnurl_live.jmx index 6d712373..7a333a1e 100644 --- a/integration/002_lnurl_live.jmx +++ b/integration/002_lnurl_live.jmx @@ -15,12 +15,12 @@ host - ${__property(host,,guiltyeland1.lnbits.com)} + ${__property(host,,localhost)} = scheme - ${__property(scheme,,https)} + ${__property(scheme,,http)} = @@ -43,6 +43,16 @@ KJPijT = + + demoApiKey + 96fd9f927311455c902c790c343143bb + = + + + saasApiKey + 12084246eef14de2ac5b216ec49759ad + = + @@ -148,7 +158,7 @@ X-Api-Key - 96fd9f927311455c902c790c343143bb + ${demoApiKey} Content-Type @@ -229,7 +239,7 @@ X-Api-Key - 12084246eef14de2ac5b216ec49759ad + ${saasApiKey} @@ -326,7 +336,7 @@ X-Api-Key - 96fd9f927311455c902c790c343143bb + ${demoApiKey} Content-Type @@ -396,7 +406,7 @@ X-Api-Key - 12084246eef14de2ac5b216ec49759ad + ${saasApiKey} @@ -493,7 +503,7 @@ X-Api-Key - 12084246eef14de2ac5b216ec49759ad + ${saasApiKey} Content-Type From a91b6dc3d4dc7b8a5cc506d76d8d3e9ca3b0566a Mon Sep 17 00:00:00 2001 From: Vlad Stan Date: Tue, 24 Mar 2026 09:32:02 +0200 Subject: [PATCH 7/9] refactor: rename --- ...02_lnurl_live.jmx => 002_saas_invoice.jmx} | 4 +- integration/002_saas_lnurl.jmx | 772 ++++++++++++++++++ 2 files changed, 774 insertions(+), 2 deletions(-) rename integration/{002_lnurl_live.jmx => 002_saas_invoice.jmx} (99%) create mode 100644 integration/002_saas_lnurl.jmx diff --git a/integration/002_lnurl_live.jmx b/integration/002_saas_invoice.jmx similarity index 99% rename from integration/002_lnurl_live.jmx rename to integration/002_saas_invoice.jmx index 7a333a1e..12340f27 100644 --- a/integration/002_lnurl_live.jmx +++ b/integration/002_saas_invoice.jmx @@ -15,12 +15,12 @@ host - ${__property(host,,localhost)} + ${__property(host,,guiltyeland1.lnbits.com)} = scheme - ${__property(scheme,,http)} + ${__property(scheme,,https)} = diff --git a/integration/002_saas_lnurl.jmx b/integration/002_saas_lnurl.jmx new file mode 100644 index 00000000..12340f27 --- /dev/null +++ b/integration/002_saas_lnurl.jmx @@ -0,0 +1,772 @@ + + + + + false + false + + + + + + + + + + + host + ${__property(host,,guiltyeland1.lnbits.com)} + = + + + scheme + ${__property(scheme,,https)} + = + + + port + ${__property(port,,)} + = + + + paymentCountPerLnurlp + 5 + = + + + configPath + ${__BeanShell(import org.apache.jmeter.services.FileServer; FileServer.getFileServer().getBaseDir();)} + = + + + lnurlLinkId + KJPijT + = + + + demoApiKey + 96fd9f927311455c902c790c343143bb + = + + + saasApiKey + 12084246eef14de2ac5b216ec49759ad + = + + + + + + + + + ${host} + ${port} + ${scheme} + + + 6 + + + + + + 1 + 1 + false + continue + + false + 1 + + false + + + + + + + false + false + + + + true + ${paymentCountPerLnurlp} + + + + 1 + ${paymentCountPerLnurlp} + 1 + lnurlpPaymentCounter + + true + + + + true + false + + + + true + + + + false + { + "res": { + "tag": "payRequest", + "callback": "${scheme}://${host}/lnurlp/api/v1/lnurl/cb/${lnurlLinkId}", + "minSendable": 10000, + "maxSendable": 100000, + "metadata": "[[\"text/plain\", \"test many payments\"]]" + }, + "lnurl": "LNURL1DP68GURN8GHJ7EM4D9K8G7T9D3SKUEP39EKXUCNFW3EJUCM0D5HKCMN4WFK8QTENDPCKVUEHX9JDQL", + "unit": "sat", + "amount": 10000, + "comment": "", + "internalMemo": null +} + = + + + + demo.lnbits.com + + https + utf-8 + /api/v1/payments/lnurl + POST + true + false + true + false + true + + HttpClient4 + + + + + + + + Accept + application/json, text/plain, */* + + + X-Api-Key + ${demoApiKey} + + + Content-Type + application/json;charset=utf-8 + + + + + + + 200 + + + Assertion.response_code + false + 8 + + + + extra.success_action + + false + false + false + false + + + + paymenHash + payment_hash + 0 + no-paymenthash + + + + + + true + false + + + + 5000 + for the webhook to be called + + + + + true + false + + + + 20000 + for the webhook to be called + + + + + + + ${host} + + https + UTF-8 + /api/v1/payments/${paymenHash} + GET + true + false + true + false + + + + + + + + + X-Api-Key + ${saasApiKey} + + + + + + + 200 + + + Assertion.response_code + false + 8 + + + + $.details.extra.wh_success + true + true + false + false + false + + + + $.details.extra.wh_message + OK + true + false + false + false + + + + javascript + + ${configPath}/scripts/lnurl_check_webhook_response.js + true + + + + + + + true + false + + + + true + + + + false + { + "res": { + "tag": "payRequest", + "callback": "${scheme}://${host}/lnurlp/api/v1/lnurl/cb/${lnurlLinkId}", + "minSendable": 10000, + "maxSendable": 100000, + "metadata": "[[\"text/plain\", \"test many payments\"]]" + }, + "lnurl": "LNURL1DP68GURN8GHJ7EM4D9K8G7T9D3SKUEP39EKXUCNFW3EJUCM0D5HKCMN4WFK8QTENDPCKVUEHX9JDQL", + "unit": "sat", + "amount": 20000, + "comment": "", + "internalMemo": null +} + = + + + + demo.lnbits.com + + https + utf-8 + /api/v1/payments/lnurl + POST + true + false + true + false + true + + HttpClient4 + + + + + + + + Accept + application/json, text/plain, */* + + + X-Api-Key + ${demoApiKey} + + + Content-Type + application/json;charset=utf-8 + + + + + + + 200 + + + Assertion.response_code + false + 8 + + + + extra.success_action + + false + false + false + false + + + + paymenHash + payment_hash + 0 + no-paymenthash + + + + + + true + false + + + + 20000 + for the webhook to be called + + + + + + + ${host} + + https + UTF-8 + /api/v1/payments/${paymenHash} + GET + true + false + true + false + + + + + + + + + X-Api-Key + ${saasApiKey} + + + + + + + 200 + + + Assertion.response_code + false + 8 + + + + $.details.extra.wh_success + true + true + false + false + false + + + + $.details.extra.wh_message + OK + true + false + false + false + + + + javascript + + ${configPath}/scripts/lnurl_check_webhook_response.js + true + + + + + + + true + false + + + + true + + + + false + { + "res": { + "tag": "payRequest", + "callback": "https://demo.lnbits.com/lnurlp/api/v1/lnurl/cb/et5tSf", + "minSendable": 10000, + "maxSendable": 100000, + "metadata": "[[\"text/plain\", \"SaaS instances pay me\"]]" + }, + "lnurl": "LNURL1DP68GURN8GHJ7ER9D4HJUMRWVF5HGUEWVDHK6TMVDE6HYMRS9AJHGDT52DNQ97CEPF", + "unit": "sat", + "amount": 10000, + "comment": "", + "internalMemo": null +} + = + + + + ${host} + + https + utf-8 + /api/v1/payments/lnurl + POST + true + false + true + false + true + + HttpClient4 + + + + + + + + Accept + application/json, text/plain, */* + + + X-Api-Key + ${saasApiKey} + + + Content-Type + application/json;charset=utf-8 + + + + + + + 200 + + + Assertion.response_code + false + 8 + + + + extra.success_action + + false + false + false + false + + + + paymenHash + payment_hash + 0 + no-paymenthash + + + + + + + false + + saveConfig + + + true + true + true + + true + true + true + true + false + true + true + false + false + false + true + false + false + false + true + 0 + true + true + true + true + true + true + + + + + + + false + + saveConfig + + + true + true + true + + true + true + true + true + false + true + true + false + false + false + true + false + false + false + true + 0 + true + true + true + true + true + true + + + + + + + false + + saveConfig + + + true + true + true + + true + true + true + true + false + true + true + false + false + false + true + false + false + false + true + 0 + true + true + true + true + true + true + + + + + + + false + + saveConfig + + + true + true + true + + true + true + true + true + false + true + true + false + false + false + true + false + false + false + true + 0 + true + true + true + true + true + true + + + + 100 + true + (wallet){1} + + + + false + + saveConfig + + + true + true + true + + true + true + true + true + false + true + true + false + false + false + true + false + false + false + true + 0 + true + true + true + true + true + true + + + + + + + false + + saveConfig + + + true + true + true + + true + true + true + true + false + true + true + false + false + false + true + false + false + false + true + 0 + true + true + true + true + true + true + + + + + + + + + From 8b51f01efe712b97185363003a2651475fa8d885 Mon Sep 17 00:00:00 2001 From: Vlad Stan Date: Tue, 24 Mar 2026 09:47:53 +0200 Subject: [PATCH 8/9] feat: request invoices --- integration/002_saas_invoice.jmx | 251 +++++++++++++++++++++++++++---- 1 file changed, 225 insertions(+), 26 deletions(-) diff --git a/integration/002_saas_invoice.jmx b/integration/002_saas_invoice.jmx index 12340f27..29ca4a4a 100644 --- a/integration/002_saas_invoice.jmx +++ b/integration/002_saas_invoice.jmx @@ -104,30 +104,91 @@ true - + true false - + true false { - "res": { - "tag": "payRequest", - "callback": "${scheme}://${host}/lnurlp/api/v1/lnurl/cb/${lnurlLinkId}", - "minSendable": 10000, - "maxSendable": 100000, - "metadata": "[[\"text/plain\", \"test many payments\"]]" - }, - "lnurl": "LNURL1DP68GURN8GHJ7EM4D9K8G7T9D3SKUEP39EKXUCNFW3EJUCM0D5HKCMN4WFK8QTENDPCKVUEHX9JDQL", + "out": false, + "amount": 10, + "memo": "pay saas", "unit": "sat", - "amount": 10000, - "comment": "", - "internalMemo": null + "lnurl_withdraw": null, + "fiat_provider": "", + "payment_hash": null +} + = + + + + ${host} + + https + utf-8 + /api/v1/payments + POST + true + false + true + false + true + + HttpClient4 + + + + + + + + Accept + application/json, text/plain, */* + + + X-Api-Key + ${saasApiKey} + + + Content-Type + application/json;charset=utf-8 + + + + + + + 201 + + + Assertion.response_code + false + 8 + + + + bolt11 + bolt11 + 0 + no-bolt11 + + + + + true + + + + false + { + "out": true, + "bolt11": "${bolt11}" } = @@ -137,7 +198,7 @@ https utf-8 - /api/v1/payments/lnurl + /api/v1/payments POST true false @@ -167,9 +228,9 @@ - + - 200 + 201 Assertion.response_code @@ -177,23 +238,161 @@ 8 - - extra.success_action - - false + + status + "success" + true false false false - - paymenHash - payment_hash + + + + true + false + + + + true + + + + false + { + "out": false, + "amount": 20, + "memo": "pay saas", + "unit": "sat", + "lnurl_withdraw": null, + "fiat_provider": "", + "payment_hash": null +} + = + + + + demo.lnbits.com + + https + utf-8 + /api/v1/payments + POST + true + false + true + false + true + + HttpClient4 + + + + + + + + Accept + application/json, text/plain, */* + + + X-Api-Key + ${demoApiKey} + + + Content-Type + application/json;charset=utf-8 + + + + + + + 201 + + + Assertion.response_code + false + 8 + + + + bolt11 + bolt11 0 - no-paymenthash + no-bolt11 + + true + + + + false + { + "out": true, + "bolt11": "${bolt11}" +} + = + + + + ${host} + + https + utf-8 + /api/v1/payments + POST + true + false + true + false + true + + HttpClient4 + + + + + + + + Accept + application/json, text/plain, */* + + + X-Api-Key + ${saasApiKey} + + + Content-Type + application/json;charset=utf-8 + + + + + + + 201 + + + Assertion.response_code + false + 8 + + + + status + "success" + true + false + false + false + + + true @@ -282,7 +481,7 @@ - + true false @@ -449,7 +648,7 @@ - + true false From 05ab62278d6e59fdd5d8dbe081f92c5a4d5c0910 Mon Sep 17 00:00:00 2001 From: Vlad Stan Date: Tue, 31 Mar 2026 10:08:10 +0300 Subject: [PATCH 9/9] feat: test saas --- integration/002_saas_invoice.jmx | 867 +++++++++---------------------- 1 file changed, 255 insertions(+), 612 deletions(-) diff --git a/integration/002_saas_invoice.jmx b/integration/002_saas_invoice.jmx index 29ca4a4a..1a244b50 100644 --- a/integration/002_saas_invoice.jmx +++ b/integration/002_saas_invoice.jmx @@ -15,7 +15,7 @@ host - ${__property(host,,guiltyeland1.lnbits.com)} + ${__property(host,,grumpyshads3.lnbits.com)} = @@ -30,7 +30,7 @@ paymentCountPerLnurlp - 5 + 3 = @@ -50,7 +50,7 @@ saasApiKey - 12084246eef14de2ac5b216ec49759ad + 9e536d5f16274d82a56d2f4a19f31958 = @@ -71,8 +71,8 @@ - 1 - 1 + 20 + 100 false continue @@ -104,18 +104,13 @@ true - - true - false - - - - true - - - - false - { + + true + + + + false + { "out": false, "amount": 10, "memo": "pay saas", @@ -124,143 +119,137 @@ "fiat_provider": "", "payment_hash": null } - = - - - - ${host} - - https - utf-8 - /api/v1/payments - POST - true - false - true - false - true - - HttpClient4 - - - - - - - - Accept - application/json, text/plain, */* - - - X-Api-Key - ${saasApiKey} - - - Content-Type - application/json;charset=utf-8 - - - - - - - 201 - - - Assertion.response_code - false - 8 - - - - bolt11 - bolt11 - 0 - no-bolt11 - - - - - true - - - - false - { + = + + + + ${host} + + https + utf-8 + /api/v1/payments + POST + true + false + true + false + true + + HttpClient4 + + + + + + + + Accept + application/json, text/plain, */* + + + X-Api-Key + ${saasApiKey} + + + Content-Type + application/json;charset=utf-8 + + + + + + + 201 + + + Assertion.response_code + false + 8 + + + + bolt11 + bolt11 + 0 + no-bolt11 + + + + + true + + + + false + { "out": true, "bolt11": "${bolt11}" } - = - - - - demo.lnbits.com - - https - utf-8 - /api/v1/payments - POST - true - false - true - false - true - - HttpClient4 - - - - - - - - Accept - application/json, text/plain, */* - - - X-Api-Key - ${demoApiKey} - - - Content-Type - application/json;charset=utf-8 - - - - - - - 201 - - - Assertion.response_code - false - 8 - - - - status - "success" - true - false - false - false - - - - - - true - false - + = + + + + demo.lnbits.com + + https + utf-8 + /api/v1/payments + POST + true + false + true + false + true + + HttpClient4 + + + - - true - - - - false - { + + + + Accept + application/json, text/plain, */* + + + X-Api-Key + ${demoApiKey} + + + Content-Type + application/json;charset=utf-8 + + + + + + + 201 + + + Assertion.response_code + false + 8 + + + + status + "success" + true + false + false + false + + + + + true + + + + false + { "out": false, "amount": 20, "memo": "pay saas", @@ -269,475 +258,129 @@ "fiat_provider": "", "payment_hash": null } - = - - - - demo.lnbits.com - - https - utf-8 - /api/v1/payments - POST - true - false - true - false - true - - HttpClient4 - - - - - - - - Accept - application/json, text/plain, */* - - - X-Api-Key - ${demoApiKey} - - - Content-Type - application/json;charset=utf-8 - - - - - - - 201 - - - Assertion.response_code - false - 8 - - - - bolt11 - bolt11 - 0 - no-bolt11 - - - - - true - - - - false - { - "out": true, - "bolt11": "${bolt11}" -} - = - - - - ${host} - - https - utf-8 - /api/v1/payments - POST - true - false - true - false - true - - HttpClient4 - - - - - - - - Accept - application/json, text/plain, */* - - - X-Api-Key - ${saasApiKey} - - - Content-Type - application/json;charset=utf-8 - - - - - - - 201 - - - Assertion.response_code - false - 8 - - - - status - "success" - true - false - false - false - - - - - - true - false - + = + + + + demo.lnbits.com + + https + utf-8 + /api/v1/payments + POST + true + false + true + false + true + + HttpClient4 + + + - - 5000 - for the webhook to be called - + + + + Accept + application/json, text/plain, */* + + + X-Api-Key + ${demoApiKey} + + + Content-Type + application/json;charset=utf-8 + + + - - - true - false - - - - 20000 - for the webhook to be called - + + + 201 + + + Assertion.response_code + false + 8 + + + + bolt11 + bolt11 + 0 + no-bolt11 + - - - - - ${host} - - https - UTF-8 - /api/v1/payments/${paymenHash} - GET - true - false - true - false - - - - - - - - - X-Api-Key - ${saasApiKey} - - - - - - - 200 - - - Assertion.response_code - false - 8 - - - - $.details.extra.wh_success - true - true - false - false - false - - - - $.details.extra.wh_message - OK - true - false - false - false - - - - javascript - - ${configPath}/scripts/lnurl_check_webhook_response.js - true - - - - - - true - false - - - - true - - - - false - { - "res": { - "tag": "payRequest", - "callback": "${scheme}://${host}/lnurlp/api/v1/lnurl/cb/${lnurlLinkId}", - "minSendable": 10000, - "maxSendable": 100000, - "metadata": "[[\"text/plain\", \"test many payments\"]]" - }, - "lnurl": "LNURL1DP68GURN8GHJ7EM4D9K8G7T9D3SKUEP39EKXUCNFW3EJUCM0D5HKCMN4WFK8QTENDPCKVUEHX9JDQL", - "unit": "sat", - "amount": 20000, - "comment": "", - "internalMemo": null + + true + + + + false + { + "out": true, + "bolt11": "${bolt11}" } - = - - - - demo.lnbits.com - - https - utf-8 - /api/v1/payments/lnurl - POST - true - false - true - false - true - - HttpClient4 - - - - - - - - Accept - application/json, text/plain, */* - - - X-Api-Key - ${demoApiKey} - - - Content-Type - application/json;charset=utf-8 - - - - - - - 200 - - - Assertion.response_code - false - 8 - - - - extra.success_action - - false - false - false - false - - - - paymenHash - payment_hash - 0 - no-paymenthash - - - - - - true - false - + = + + + + ${host} + + https + utf-8 + /api/v1/payments + POST + true + false + true + false + true + + HttpClient4 + + + - - 20000 - for the webhook to be called - + + + + Accept + application/json, text/plain, */* + + + X-Api-Key + ${saasApiKey} + + + Content-Type + application/json;charset=utf-8 + + + + + + + 201 + + + Assertion.response_code + false + 8 + + + + status + "success" + true + false + false + false + - - - - - ${host} - - https - UTF-8 - /api/v1/payments/${paymenHash} - GET - true - false - true - false - - - - - - - - - X-Api-Key - ${saasApiKey} - - - - - - - 200 - - - Assertion.response_code - false - 8 - - - - $.details.extra.wh_success - true - true - false - false - false - - - - $.details.extra.wh_message - OK - true - false - false - false - - - - javascript - - ${configPath}/scripts/lnurl_check_webhook_response.js - true - - - - - - - true - false - - - - true - - - - false - { - "res": { - "tag": "payRequest", - "callback": "https://demo.lnbits.com/lnurlp/api/v1/lnurl/cb/et5tSf", - "minSendable": 10000, - "maxSendable": 100000, - "metadata": "[[\"text/plain\", \"SaaS instances pay me\"]]" - }, - "lnurl": "LNURL1DP68GURN8GHJ7ER9D4HJUMRWVF5HGUEWVDHK6TMVDE6HYMRS9AJHGDT52DNQ97CEPF", - "unit": "sat", - "amount": 10000, - "comment": "", - "internalMemo": null -} - = - - - - ${host} - - https - utf-8 - /api/v1/payments/lnurl - POST - true - false - true - false - true - - HttpClient4 - - - - - - - - Accept - application/json, text/plain, */* - - - X-Api-Key - ${saasApiKey} - - - Content-Type - application/json;charset=utf-8 - - - - - - - 200 - - - Assertion.response_code - false - 8 - - - - extra.success_action - - false - false - false - false - - - - paymenHash - payment_hash - 0 - no-paymenthash - - -