We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Missed one crucial step. Function should include separate invoicing for zaps. Something like:
# construct zap request if needed if lnurl_data.get("allowsNostr") and lnurl_data.get("nostrPubkey"): event_details = { "kind": 9734, "content": description or "CyberHerd Treats", "tags": [ ["p", lnurl_data["nostrPubkey"]] ], "pubkey": "669ebbcccf409ee0467a33660ae88fd17e5379e646e41d7c236ff4963f3c36b6", "created_at": round(datetime.now().timestamp()), } signed_zap_event = await sign_event(event_details, nos_sec) zap_event_encoded = quote(json.dumps(signed_zap_event)) zap_url = f"{lnurl_data['callback']}?amount={amount}&nostr={zap_event_encoded}" zap_response = await client.get(zap_url, headers=headers) zap_response.raise_for_status() invoice = zap_response.json().get('payment_request', None) if invoice: logger.info(f"Received invoice: {invoice}") return await pay_invoice(client, invoice) # pay_invoice should handle the payment and return a structured response else: logger.error("No invoice received from zap request") return {"success": False, "message": "No invoice received from zap request"}
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Missed one crucial step. Function should include separate invoicing for zaps. Something like:
The text was updated successfully, but these errors were encountered: