https://github.com/totem-gdn/totem-web-explorer-backend
https://github.com/totem-gdn/totem-web-explorer-backend
Last synced: 4 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/totem-gdn/totem-web-explorer-backend
- Owner: Totem-gdn
- License: mit
- Created: 2022-09-13T15:04:19.000Z (almost 3 years ago)
- Default Branch: main
- Last Pushed: 2024-04-28T22:37:00.000Z (about 1 year ago)
- Last Synced: 2024-12-29T14:41:44.573Z (6 months ago)
- Language: TypeScript
- Size: 525 KB
- Stars: 0
- Watchers: 4
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# totem-web-explorer-backend
# API Documentation available here: http://{hostname}/api
- hostname - URL of your running instance of Totem Web Explorer
# Requirements:
- Node.JS version 16 or higher;
- Redis version 3.2 or higher;
- MongoDB version 4.2.8 of higher
- AWS# Installing:
1. Install node modules
```sh
npm install
```2. Copy .env.example to .env
```sh
cp .env.example .env
```3. Fill .env file:
```sh
PORT= #port number which will be used
REDIS_STORAGE_URI= #url to Redis in format: redis://hostname:port/0
MONGODB_URI= #url to MongoDB in format: mongodb://hostname:port
MONGODB_DATABASE= #MongoDB database name. All tables will be created automatically
AWS_ACCESS_KEY_ID= #Key from AWS. Guide: https://docs.aws.amazon.com/powershell/latest/userguide/pstools-appendix-sign-up.html
AWS_SECRET_ACCESS_KEY= #Key from AWS. Guide: https://docs.aws.amazon.com/powershell/latest/userguide/pstools-appendix-sign-up.html
AWS_REGION= #AWS Region where created buckets from AWS console
AWS_S3_ENDPOINT= #AWS S3 Endpoint. Guide: https://docs.aws.amazon.com/AmazonS3/latest/userguide/WebsiteEndpoints.html
AWS_S3_BUCKET= #AWS S3 Bucket. Guide: https://docs.aws.amazon.com/AmazonS3/latest/userguide/WebsiteEndpoints.html
PROVIDER_RPC= #JSON RPC Polygon URL. Actual URLs here: https://wiki.polygon.technology/docs/develop/metamask/config-polygon-on-metamask/
ASSETS_AVATAR_CONTRACT= #Address of Totem Asset NFT smart contract
ASSETS_ITEM_CONTRACT= #Address of Totem Asset NFT smart contract
ASSETS_GEM_CONTRACT= #Address of Totem Asset NFT smart contract
```4. Start the server
For production
```sh
npm run build && npm run start:prod
```For development
```sh
npm run start:dev
```