Prism/Setup Guide

Setup Guide

Install Prism, run the setup wizard and get your shop online.

Prism is set up in the browser. You start it once, open the site and a setup wizard asks for everything it needs.

Before You Start

You need:

  • A host that runs Node.js 20 or newer, or Bun.
  • An empty PostgreSQL, MySQL or MariaDB database. Prism creates its own tables.
  • A Discord application from the Discord Developer Portal.
  • Your Prism license key from the Zero Development Discord.

Hosting

OptionBest for
Game panel (Pterodactyl)The easiest choice. The panel keeps Prism running and gives you a console and file manager.
Linux VPS or dedicated serverFull control. Use a process manager such as PM2 or systemd.
Your own computerTesting and development.

Install

  1. Create a server with a Node.js 20 or newer egg.
  2. Upload the Prism files.
  3. Set the startup command to node index.js.
  4. Start the server.

On the first start Prism creates config.json, builds the web app and serves it on port 3000. The first build takes a few minutes. The console shows:

Prism is not configured yet. Open the web address to run the setup wizard.

Prism installs the driver for your database the first time it connects, so there is nothing else to install.

Discord Application

The Discord account on your license becomes the shop owner, so Discord sign-in is required. Google, Apple, GitHub and email sign-in are optional and can be added later.

  1. Create an application in the Discord Developer Portal.
  2. Go to OAuth2 and add your site address followed by /api/auth/callback/discord under Redirects:
    • On your own computer: http://localhost:3000/api/auth/callback/discord
    • On a domain: https://shop.example.com/api/auth/callback/discord
  3. Copy the Client ID and Client Secret for the wizard.

Setup Wizard

Open http://localhost:3000, or your server's address on port 3000.

StepWhat you enter
WelcomeThe language.
DatabaseType, host, port, user, password and database name. Click Test Connection.
LicenseYour license key. Click Check License. The Discord account on the license becomes the owner.
BrandingSite name, accent colour, Web URL and API URL. Leave the URLs empty on your own computer.
Sign-in ProvidersDiscord client ID and secret, plus any optional providers. The wizard shows the redirect to add. Click Test Credentials.
LaunchClick Launch Prism.

Prism then saves your settings, connects to the database, activates the license, loads its modules and checks for updates. The wizard shows each stage with the live console. When it finishes, click Go to Sign In and sign in with Discord. There is no restart.

Hosting on a Domain

Point a reverse proxy at each port. Pick yours:

Caddy gets and renews HTTPS certificates on its own. Add this to your Caddyfile and reload Caddy.

/etc/caddy/Caddyfile
shop.example.com {
    reverse_proxy 127.0.0.1:3000
}

api.shop.example.com {
    reverse_proxy 127.0.0.1:3001
}
Terminal
sudo systemctl reload caddy

The site on port 3000 already forwards /api/v1/ to the API, so customers and the store only need the first domain. Give the API its own domain if your products or scripts call it directly.

Set Web URL and API URL in the wizard, or later under Settings > Server URLs. Changing them later asks you to restart Prism.

The Web URL, the address in your browser and the redirects in each provider's console must all match, or sign-in fails.

Next