Document URLs

This commit is contained in:
Râu Cao 2024-03-31 12:09:18 +03:00
parent 3ba333e802
commit 3f90a011c4
Signed by: raucao
GPG Key ID: 37036C356E56CC51

View File

@ -6,6 +6,7 @@ class LnurlpayController < ApplicationController
MAX_SATS = 1_000_000 MAX_SATS = 1_000_000
MAX_COMMENT_CHARS = 100 MAX_COMMENT_CHARS = 100
# GET /.well-known/lnurlp/:username
def index def index
render json: { render json: {
status: "OK", status: "OK",
@ -18,6 +19,7 @@ class LnurlpayController < ApplicationController
} }
end end
# GET /.well-known/keysend/:username
def keysend def keysend
http_status :not_found and return unless Setting.lndhub_keysend_enabled? http_status :not_found and return unless Setting.lndhub_keysend_enabled?
@ -32,6 +34,7 @@ class LnurlpayController < ApplicationController
} }
end end
# GET /lnurlpay/:username/invoice
def invoice def invoice
amount = params[:amount].to_i / 1000 # msats amount = params[:amount].to_i / 1000 # msats
comment = params[:comment] || "" comment = params[:comment] || ""