This is the Backend of the PlatinPay project.
- Endpoints for various actions
- GET /store/by-id/
[store_name] - GET /store/
[store_id]/details - GET /store/
[store_id]/products - POST /store/create
- POST /store/
[store_id]/product/create - POST /store/
[store_id]/product/delete - POST /user/checkout
- POST /genkeypair
- GET /store/by-id/
- Secure communications with Minecraft and Discord backend (Signing request body with ed25519 and timestamp validation)
- Local sqlite database
NOTE: Everything is subject to change, this is only a proof-of-concept and definitely not finalized, there are still a lot more features on the roadmap and the backend will also be ported to either Go or Rust
Make sure bun is installed and up-to-date
curl -fsSL https://bun.sh/install | bashor
bun upgrade- Clone the repository
git clone https://github.com/PlatinPay/platinpay-backendcdinto the cloned git repo
cd platinpay-backend- Install packages
bun i- Populate the database
bun run populate- Generate a new keypair
bun run genkeyThe command above should give you a public_key and a private_key
Save the public key as you will need it later for PlatinPay-Discord and PlatinPay-Minecraft
- Start the server
bun run startThe backend will run on port 3001 by default, to change that, edit the file index.ts
(If you updated the port, make sure to also update it on the frontend)
https://github.com/PlatinPay/platinpay-frontend
- Update your PlatinPay-Discord and PlatinPay-Minecraft public key to the one you just generated
Refer to the docs on how to set your public key for Minecraft and Discord
https://github.com/PlatinPay/platinpay-discord
https://github.com/PlatinPay/platinpay-minecraft
This project is licensed under the GNU AGPL-3.0 License. See the LICENSE file for details.
DISCLAIMER: This project is currently not ready for production usage. It is a work-in-progress.
