Uses the Create Charge endpoint.
Before you start #
On the Plugin settings page, make sure you’ve entered your API Key and Endpoint – see the Setup page for information.
Collect Data #
You will need to collect:
- Description (text)
- Amount (as a decimal number – we recommend collecting/storing this as a “currency” field)
- Currency (3-letter code – the equivalent non-crypto currency you are charging in)
- Order ID (sale/payment reference) (text)
- Customer Name (text)
- Customer Email (text)
- Notification Email (text)
- Callback URL
- Success URL
- Auto Settle (T/F)
- TTL (minutes)
Create a Workflow #
Create a Workflow, and add the “OpenNode – Receive Payment” action from the “Plugins” tab of the Actions list.
Each parameter in the action settings matches a parameter in the OpenNode documentation.
Description #
Charge’s description
Amount #
Charge’s price in the fiat currency you specify, in decimal format.
Example: 12.35
We recommend passing this from a “currency” field, then entering it as dynamic data “formatted as:” “number”, to 2 decimal places, with a period for the decimal and no symbol for the thousands.
Currency #
Three-letter ISO4217 currency code for the fiat currency you are charging in.
Example: AUD
Order ID #
A product (or sale) id or description. We recommend using an order/product id. This field’s primary purpose is to help the transaction be identifiable for reporting and accounting purposes.
Example: ABC4321
Customer Name #
This field can only contain alphanumeric characters, as well as the full stop, comma, apostrophe, ampersand, space and hyphen characters.
Example: Mr. Example Person
Customer Email #
Customer email for your records.
Example: person@example.com
Notification Email #
Customer’s email for OpenNode to send receipt to.
Example: person@example.com
Callback URL #
URL to receive webhooks.
Example: https://www.example.com/notify.php
Success URL #
URL to redirect customer after payment.
Auto Settle #
Automatically convert to merchant’s currency (needs Bank account enabled)
TTL #
Charge’s TTL (time to live) in minutes. Minimum 10, Maximum: 1440 (24H)
Parse Response #
The response will contain:
id #
Charge ID
description #
The same format as passed in your original request.
created_at #
UNIX datetime the request was processed.
status #
Status as at the time of response (usually “unpaid” as at this time)
amount #
Value in BTC
The format of this field is not what you might expect.
0.00003038 BTC
will be returned as:
3038
callback_url #
The same format as passed in your original request.
success_url #
The same format as passed in your original request.
hosted_checkout_url #
If you want to display an OpenNode-generated checkout page with QR codes and wallet addresses, pass this URL to a Thing or Element.
order_id #
The same format as passed in your original request.
currency #
The same format as passed in your original request.
source_fiat_value #
The same amount as passed in your original request.
fiat_value #
The amount actually used by the server. This rarely differs, unless you use too many decimals and the system needs to round.
auto_settle #
The same format as passed in your original request.
notif_email #
The same format as passed in your original request.
address #
The on-chain address for this request, that your end-user can pay to.
metadata name #
The same format as passed in your original request.
metadata email #
The same format as passed in your original request.
chain_invoice address #
The on-chain address for this request, that your end-user can pay to.
uri #
The URI beginning with bitcoin: for this request, that your end-user can pay to if device-compatible.
ttl #
The same format as passed in your original request.
lightning_invoice expires_at #
UNIX datetime that the TTL will expire.
lightning_invoice payreq #
The lightning payment request address that your end-user can pay to.
Next Actions #
Passing the variables you need to a Thing and/or to an Element, would be the logical next step.