Skip to content
ArionPay

Discord bot

Sell Discord roles and digital items for crypto

A ready-made Discord bot for your server. Members buy a role or a digital item on the secure ArionPay page, the money is paid straight to your own wallet, and the bot gives the role and sends the item by direct message.

Example

What it does

ArionPay for Discord

The ArionPay Discord shop bot is one Node.js file with no Discord library, run on your own server with a public https address. Members use /shop or /buy, press a button and pay on the ArionPay page; everything they see is private to them.
Read moreWhen ArionPay confirms the payment, the bot gives the role, sends the item by direct message and, if you want, posts the sale in a channel for you and your moderators. Open orders are also re-checked every 300 seconds by default, so a missed payment update still gets delivered.
  • /shop and /buy commands, with replies only the member sees.
  • Each item gives a role, sends a text, or both.
  • An optional sale notice in a channel for you and your moderators.
  • If a member does not accept DMs, the item is shown in their private pay message during the first 15 minutes.
  • Each order is delivered once, and a doubled button press never makes a second invoice.
  • Discord’s request signatures and ArionPay’s webhook signatures are both checked.
  • A test invoice never delivers in live mode, and a live one never in test mode.

Requirements and licence

Works with
Node.js 18 or newer · a server with a public https address
Tested
A real ArionPay server and a stand-in Discord API
Cost
The plugin is free. ArionPay charges 0.5% per payment, with no monthly fee.
Source
Open source (MIT) on GitHub.

Setup

Set it up in 5 steps

  1. Step 1

    Create the Discord app

    In the Discord Developer Portal, make a New Application. Copy the Application ID and Public Key, then reset and copy the bot token.

  2. Step 2

    Invite the bot

    In OAuth2 > URL Generator, tick bot and applications.commands with the Manage Roles permission, and invite it to your server. Drag the bot’s role above the roles it sells.

  3. Step 3

    Install and configure

    On a server with a public https address, clone the repository, run npm install and fill in .env with the Discord ids, token and your ArionPay keys and webhook signing secret.

  4. Step 4

    Add your products

    In products.json, give each item a role_id, a deliver text, or both. Set DISCORD_GUILD_ID to your server id.

  5. Step 5

    Connect and test

    Run npm start, then set the Interactions Endpoint URL to https://your-address/discord/interactions. Type /shop and buy something in test mode, then set ARIONPAY_TEST_MODE=false.

After the setup

How a sale works

  • Pressing an item creates an ArionPay invoice and shows a private Pay button.
  • When the payment is seen on the network, the member gets a DM saying it is waiting for confirmations.
  • When ArionPay confirms the full payment, the bot gives the role and sends "Payment received, thank you!" with the item by DM.
  • A payment that is not exact goes to Payment Radar, where you decide. If you accept it, the bot delivers.
  • When the time to pay runs out, the member gets a DM. A late payment is still detected.
  • Roles are given for good. Remove a role by hand when access should end, or sell a new item each period.

16 coins and tokens on 9 networks

All coins
  • BTCBitcoin
  • ETHEthereum
  • USDTEthereum
  • USDCEthereum
  • BNBBNB Smart Chain
  • USDTBNB Smart Chain
  • USDCBNB Smart Chain
  • POLPolygon
  • USDTPolygon
  • USDCPolygon
  • TRXTRON
  • USDTTRON
  • LTCLitecoin
  • DOGEDogecoin
  • BCHBitcoin Cash
  • DASHDash

Questions about ArionPay for Discord

Short answers before you install it.

No. Crypto cannot charge again automatically, so roles are given for good. Remove a role by hand when access should end, or sell a new item each period.