import process from "node:process";
import { defu } from "defu";
import { Client, GatewayIntentBits, REST } from "discord.js";

export const processEnv = defu({
	TOKEN: process.env.TOKEN,
	DATABASE_URL: process.env.DATABASE_URL,
	SENTRY_DSN: process.env.SENTRY_DSN,
}, {
	TOKEN: "",
	DATABASE_URL: "mongodb://localhost:27017/premid",
	SENTRY_DSN: "",
	GUILD_ID: "493130730549805057",
	BETA_ROLE: "591284574823120909",
	ALPHA_ROLE: "694481247564595211",
});

export const client = new Client({
	intents: [GatewayIntentBits.Guilds, GatewayIntentBits.GuildMembers, GatewayIntentBits.GuildMessages, GatewayIntentBits.GuildPresences],
	presence: {
		status: "online",
	},
});

export const rest = new REST().setToken(processEnv.TOKEN);

export const roles = {
	PROJECT_LEADER: "493135149274365975",
	STAFF_COORDINATOR: "691382096878370837",
	ADMINISTRATOR: "685969048399249459",
	PROJECT_MANAGEMENT: "673682085608816652",
	REVIEWER: "630445337143935009",
	DEVELOPER: "1027665813525778436",
	DESIGNER: "691386502566903850",
	MODERATOR: "514546359865442304",
	SUPPORT_AGENT: "566417964820070421",
	MARKETING_DIRECTOR: "673681900476432387",
	LOCALIZATION_MANAGER: "811262682408943616",
	REPRESENTATIVE: "691384256672563332",
	CONTRIBUTOR: "1032759805732978708",
	PATRON: "515874214750715904",
	DONATOR: "502165799172309013",
	BOOSTER: "585532751663333383",
	PROOFREADER: "522755339448483840",
	TRANSLATOR: "502148045991968788",
	PRESENCE_DEV: "606222296016879722",
} as const;

export const roleColors = {
	PROJECT_LEADER: "#E43725",
	STAFF_COORDINATOR: "#E43725",
	ADMINISTRATOR: "#E43725",
	PROJECT_MANAGEMENT: "#E43725",
	REVIEWER: "#3BA576",
	DEVELOPER: "#3BA576",
	DESIGNER: "#3BA576",
	MODERATOR: "#D67118",
	SUPPORT_AGENT: "#D67118",
	MARKETING_DIRECTOR: "#3BA576",
	LOCALIZATION_MANAGER: "#3BA576",
	REPRESENTATIVE: "#3BA576",
	CONTRIBUTOR: "#EB459E",
	PATRON: "#E5472F",
	DONATOR: "#FFAA33",
	BOOSTER: "#F265FF",
	PROOFREADER: "#00B0E6",
	TRANSLATOR: "#2286D0",
	PRESENCE_DEV: "#96A5E9",
} as const;
