Gem
π² Rust high performance, fault tolerance, low latency, both monolithic and miscroservices stateful backend APIs including actor based HTTP+WebSocket and gRPC servers, API components and realtime pubsub push notification engines with Tokio, Actix, Tonic and Redis
Install / Use
/learn @wildonion/GemREADME
is a crypto based social network platform leveraging the Polygon blockchain empowering lovers to build and take participate in social events (see hoopoe) with their NFT artworks
π Features
Note that the idea behind the chatroom launchpad has been moved to the hoopoe platform with different implementations.
-
actor based component APIs, a reliable design pattern facilitating the communication between each API endpoint without sending HTTP requests, only by utilising actor message sending pattern supports only local communicating process.
-
actor based pubsub push notification strategies to notify different parts of the app clearly the user, on every db updates using redis pubsub pattern (more).
-
SSE technology to inform clients by receiving automatic updates from the server via an HTTP connection.
-
hoopoe a platform for social events
-
an event managing and reservation system with reveal-participant-role functionality
-
X (twitter) task verification system based on pre-defined tasks by admins.
-
broadcasting X tasks registered by admins into discord channel.
-
crypto id, an EVM based wallet with secp256k1 algorithm to store users' onchain digital assets and sign in-app API calls.
-
the most secure logic for authentication process with JWT per device and secp256k1 per each user for API signing.
-
buying, receiving and selling in-app $TOKEN using Stripe payment gateway and minting NFT gift cards with an smart treasury tracking service.
-
creating multiple private galleries to create, mint and transfer NFTs in various art work collections by inviting friends.
-
participating in chatroom launchpad events (%60 COMPLETED - See WIPs) to mint AI generated NFTs, based on summarization of participants' chats in each event.
π₯ͺ Panel Architecture
<p align="center"> <img src="https://github.com/wildonion/gem/blob/master/infra/arch.jpg"> </p>π Infra Route and API Endpoints
# ---------------------------------------------------------------------------------------------------
# conse panel dev username/password : devdevy/d3v@%$^$3hjsD
# conse panel admin username/password : adminy/4dmin@%$^$3hjsD
# postgres adminer username/password/server : postgres/geDteDd0Ltg2135FJYQ6rjNYHYkGQa70/postgres
# ---------------------------------------------------------------------------------------------------
ποΈ HOSTED ON ==> Digitalocean
π₯ WEBSOCKET PUSH NOTIFICATION ROUTE ==> wss://event.panel.conse.app/subscribe/
π₯ WEBSOCKET HHTP PUSH NOTIFICATION ROUTE ==> https://event.panel.conse.app/subscribe/
π MAIN SITE ==> https://conse.app/
π¨π»ββοΈ ADMIN PANEL ==> https://panel.conse.app/
π€οΈ ADMIN/DEV API ROUTE WITH POSTGRES DB STORAGE ==> https://api.panel.conse.app/
π£ ADMIN/DEV API ROUTE WITH MONGO DB STORAGE ==> https://api.panel.conse.app/mongo
πΊοΈ RENDEZVOUS API ROUTE ==> https://api.rendezvous.conse.app/
π’οΈ ADMINER PANEL ==> https://adminer.conse.app
ποΈ JENKINS PANEL ==> https://jenkins.conse.app
β΅ PORTAINER PANEL ==> https://portainer.conse.app
π GRAFANA PANEL ==> https://grafana.conse.app
π¦ STRIPE WEBHOOK ENDPOINT ==> https://api.panel.stripewh.conse.app
π€ X BOT ==> https://api.xbot.conse.app
ποΈ PANEL AND XCORD ERROR LOGS ==> https://api.panel.conse.app/logs
ποΈ PANEL ASSETS FOLDER ==> https://api.panel.conse.app/assets
π§ββοΈ KYC gRPC SERVER ==> grpcs://rpc.conse.app/kyc.KycService/Verify
# Push Notification WS Routes
wss://event.panel.conse.app/subscribe/64b827fad916781c6d68948a/reveal-role-64b82757d916781c6d689488
wss://event.panel.conse.app/subscribe/64b827fad916781c6d68948a/mmr-64b82757d916781c6d689488
# Chatroom Launchpad WS Route
wss://event.panel.conse.app/subscribe/chatroomlp/1/03fe4d2c2eb9ab44971e01d9cd928b4707a9d014381d75ec19f946b78a28164cc6/8ef4637573c6ef6170c817ad22fc4e45de4eae1b86fbe26f19986d49e9c4e24a3fe7d5f6fef58b2ae6a160ca058c41c401401ecc509f8afffe30035e0ad7451f1c/b051b639719983d5062cb8bdb5f57afffb4a634c8c8a6b9e957f583ee1087ea1/?r1pubkey=0x554543320000002d6682f8f7030f89be91e75b5604e14c026d7ec893c4be6de1d221a9e329a59b8dee2fad3b16&r1signature=0x20260426e5000000470000007b22726563697069656e745f636964223a223078353534353433333230303030303032643636383266386637303330663839626539316537356235363034653134633032366437656338393363346265366465316432323161396533323961353962386465653266616433623136222c2266726f6d5f636964223a223078353534353433333230303030303032643636383266386637303330663839626539316537356235363034653134633032366437656338393363346265366465316432323161396533323961353962386465653266616433623136222c22616d6f756e74223a357d3045022100d49e8716ef150129b612c65ef8e798e8fac73577fc8df1d4664674488b89f86d02203f62c3c5776ed393a4d0a761714d9f1e52185c5b24c4a3afe03b7903aa5186af
ποΈ Directory and Structure Explained
core: hyper, tonic gRPC, actix web HTTP and actix WS servers.chatdb: spacetimedb wasm methods used in chatroom launchpad section in conse panel.stripewh: stripe webhook listener for checkout events.xbot: X bot for twitter tasks verification.xcord: discord bot to broadcast new twitter task defined by admin into a discord channel.mailreq: mail sender crate.multipartreq: multipart extractor crate.phonereq: OTP code sender crate.s3req: shared state storage crate.walletreq: wallexerr crate.gastracker: gastracker crate.grpc: KYC grpc server.panel: user, dev and admin dashboard panel health, public and secured APIs with actix web and actix WS server.rendezvous: rendezvous service upsert event and deck, reserve event, reveal role and other in-game APIs.controllers: in-game async controllers related to hyper server.routers: in-game API routers related to hyper server.schemas: in-game mongodb schemas related to hyper server.
infra: all infrastructure and devops configs.jobs: gem crontab jobslogs: gem log files generated by conse panel and other parts of the app.migrations: diesel postgres sql filesscripts: deployment scriptstest: gem test codes like admin and dev password generator script
π Docs, ERDs, Schemas and Collections
-
Read More About GEM Specifications
-
Read More About Crypto ID
-
Read More About Push Notification Strategy
-
Read More About Rust Ownership and Borrowing Rules
π οΈ Development Setup
you can download runtime crashing error logs throught the address
https://api.panel.conse.app/logsalso after setting up theportainer, each container logs can be downloaded inside the panel, also makre sure that you've installed the following packages on MacOS M1:
brew tap cossacklabs/tap
brew install openjdk
brew install pkg-config
brew install openssl
brew install diesel
brew link --force openssl
brew install libpq && brew link --force libpq
brew install protobuf
brew install graphviz
brew tap cossacklabs/tap && brew install libthemis
cargo install spacetimedb-cli
sudo npm i wasm-opt -g
cargo clean
then run:
# π₯ build proto files
cargo build
# π Run Conse Hyper Server
cargo run --bin rendezvous #---> cargo build --bin rendezvous --release
# ππ½ββοΈ Run Conse Actix Panel Server
cargo run --bin panel #---> cargo build --bin panel --release
# ππ½ββοΈ Run Conse KYC gRPC Server
cargo run --bin grpc #---> cargo build --bin grpc --release
# ππΏ Run Conse Test Codes
cargo run --bin contest
π Production Setup
Ensure that:
-
all the vars inside
.env.prodare filled with their appropriate values. -
any self-signed SSL certificates used by gRPC server are valid and issued by a recognized certificate authority, if you are using a self-signed certificate, it may not be trusted by default by clients.
-
you've created an NFT product contract for NFT gift card section, later you have to update the
up.sqlfile insideusers_collectionsmigration folder with appropriate contract info (address, tx hash and ...), use the following curl to build a new product contract:curl --request POST \ --url https://api.nftport.xyz/v0/contracts \ --header 'Authorization: <API_KEY>' \ --header 'accept: application/json' \ --header 'content-type: application/json' \
Related Skills
feishu-drive
345.4k|
things-mac
345.4kManage Things 3 via the `things` CLI on macOS (add/update projects+todos via URL scheme; read/search/list from the local Things database)
clawhub
345.4kUse the ClawHub CLI to search, install, update, and publish agent skills from clawhub.com
codebase-memory-mcp
1.1kHigh-performance code intelligence MCP server. Indexes codebases into a persistent knowledge graph β average repo in milliseconds. 66 languages, sub-ms queries, 99% fewer tokens. Single static binary, zero dependencies.
