Add guild routes, setup tables, validators, and update environment example
All checks were successful
Code quality checks / biome (push) Successful in 7s

Added routes for guild creation, deletion, joining, leaving, and invites
Set up Cassandra tables for guilds, invites, and members
Added validators for guild input
Updated .env.example with required config values
This commit is contained in:
creations 2025-05-03 13:56:57 -04:00
parent 9d8b3eb969
commit 320e2cc121
Signed by: creations
GPG key ID: 8F553AA4320FC711
14 changed files with 708 additions and 24 deletions

View file

@ -0,0 +1,20 @@
import { cassandra } from "@lib/cassandra";
async function createTable() {
const client = cassandra.getClient();
await client.execute(`
CREATE TABLE IF NOT EXISTS guild_invites (
invite_code TEXT PRIMARY KEY,
guild_id TEXT,
created_by TEXT,
created_at TIMESTAMP,
expires_at TIMESTAMP,
max_uses INT,
uses INT,
is_revoked BOOLEAN
);
`);
}
export { createTable };