Xsolla Bot in Discord setup walkthrough

Overview

Discord is one of the primary spaces where gaming communities spend time between sessions, coordinating, sharing updates, and staying connected. The Xsolla Bot in Discord brings your storefront directly into your server so players can browse items, claim rewards, and complete purchases through a slash command without leaving Discord.

This guide walks through a complete self-service setup: creating a bot application in the Discord developer portal, connecting it to your Xsolla Publisher Account, configuring your store and rewards, and testing the player-facing experience end to end.

By the end of this guide, you will have a working Xsolla Bot in your Discord server. Players will be able to open a storefront with the /shop command, log in with their in-game player ID, and complete purchases through the Xsolla payment UI.

The guide uses a sample project called J-Clash for reference, but the steps apply to any project with an active items catalog.

Prerequisites

On the Xsolla side, you need to have the following:

Note
The J-Clash demo project used in this walkthrough has a variety of item types, different price points, and a few free items included. Having a representative catalog during setup makes it much easier to verify that rewards, item display, and purchase flows are all working correctly before going live.

On the Discord side, you need to have access to the Discord developers portal to create the bot application (optional).

Available purchase flows

The Xsolla Bot in Discord supports two purchase flows. Understanding the difference will help you decide which one fits your project:

  • Direct purchase. When a player selects an item, the Xsolla payment UI launches immediately with the item ready for checkout. There are no intermediate steps or redirects. This is the default flow and the one covered in this guide.
  • Web Shop flow. When a player selects an item, your Web Shop opens with the user login and item pre-filled, then the Xsolla payment UI launches. This flow requires a Web Shop already set up and a Web Shop URL configured in the bot settings. Refer to these instructions for detailed information.

Setup steps

Step 1. Create Discord bot application

Note
This step is optional.
  1. Go to the Discord developers portal and click New Application.
  2. Give the bot a name that reflects your game or brand. For this demo, we are using NewBot.
  3. Once the application is created, open the Bot section. This is a good point to upload an icon and a banner, as both will be visible to players when the bot is active inside Discord.
  1. Get your bot token that links your Discord application to the Xsolla configuration:
    1. In the Bot section, click Reset Token. This is the only way Discord lets you view the token.
    2. Copy the token immediately and store it somewhere safe. You will need it in Step 2.
Notice

A bot token can only be viewed once. If you lose it, return to this page and generate a new one, then update it in Publisher Account. Never share or expose your bot token publicly.

Note
Do not invite the bot to your Discord server before you complete the Publisher Account configuration first. Inviting the bot is covered in Step 3.

Step 2. Configure bot in Publisher Account

  1. In your project in Publisher Account, go to the Storefront > Xsolla Bot in Discord section.
  2. Click Create. There is no waiting period, the configuration UI is available immediately.
  3. Name your bot and, optionally, add a logo.
  4. Click Create.
  1. Open the Shop section to configure the following:
    • Login rewards — items awarded when a player logs in for the first time.
    • Daily rewards — items awarded on a daily basis.
    • Shop items — items available for purchase.
Note
Login rewards and daily rewards items must be free. The bot doesn’t allow paid items in reward categories, which prevents accidental giveaways of paid content.
Notice

The Daily rewards and Shop items sections require a section title. These fields can’t be left empty.

  1. Go to the Settings tab to complete the bot configuration:

    1. Set up Player ID help. The bot uses each player’s in-game player ID as the login method. Since every game surfaces that ID differently, upload an image that shows players how to find it in your specific game. Players can access this image from inside Discord any time they open the bot.
    2. API key is generated automatically by default. No action needed.
    3. Specify the bot token. Paste the token you copied from the Discord developer portal in Step 1. This connects your Discord bot application to Xsolla Bot.
    4. Specify user authentication webhook. The endpoint on your backend that identifies and authenticates players using their in-game player ID. You configure and host this webhook yourself.
  2. If you’re using the direct purchase flow, leave the Web Shop URL field blank. This field is only required if you’re using the Web Shop flow.

Step 3. Invite bot to your Discord server

To add the bot to your Discord server:

  1. In the Xsolla Bot in Discord section, at the top of the page, click Invite.
  1. Review and approve the requested permissions.

The bot is now connected to your server.

Step 4. Test /shop command

With the bot live in your server, open Discord and run /shop. This is the primary player-facing command, and running it is the clearest way to confirm the integration is working correctly.

The store UI loads in the following order:

  1. The Player ID help section you configured. Before a player can claim rewards or make a purchase, they need to log in. As soon as they interact with any option, they’re prompted to enter their player ID. Once that succeeds, the UI updates immediately to reflect their logged-in state.
  2. Any login or daily rewards you set up.
  3. The Shop section, with the name and items you configured.

Before a player can claim rewards or make a purchase, they need to log in. As soon as they interact with any option, they will be prompted to enter their player ID. Once that succeeds, the interface updates immediately to reflect their logged-in state. With the direct purchase flow, selecting an item launches the payment UI immediately with the item ready for checkout.

Next steps

That is a complete self-service setup of the Xsolla Bot in Discord. From the Discord developer portal through to a working storefront inside your server, the whole process takes just a few minutes.

A few directions to take it further from here:

  • Expand your rewards: Configure Login rewards and Daily rewards in the Shop section to add engagement hooks directly from Discord.
  • Customize your store: Update item selection, section titles, and Player ID help imagery in Publisher Account at any time — no need to re-invite the bot.
  • Web Shop + Pay Station: If your setup requires players to pass through a Web Shop before checkout, this flow is available. Reach out to the Xsolla team to get that configured for your project.
Was this article helpful?
Thank you!
Is there anything we can improve? Message
We’re sorry to hear that
Please explain why this article wasn’t helpful to you. Message
Thank you for your feedback!
We’ll review your message and use it to help us improve your experience.
Last updated: July 14, 2026

Found a typo or other text error? Select the text and press Ctrl+Enter.

Report a problem
We always review our content. Your feedback helps us improve it.
Provide an email so we can follow up
Thank you for your feedback!
We couldn't send your feedback
Try again later or contact us at doc_feedback@xsolla.com.