package routers

import (
	"github.com/bwmarrin/discordgo"
	"kleincordBot/handlers"
	"kleincordBot/services"
)

func CommandRouter(s *discordgo.Session, i *discordgo.InteractionCreate) {
	data := i.ApplicationCommandData()
	switch data.Name {
	case "init":
		services.AddServer(i.GuildID, s)
		handlers.InitCommand(s, i)
	case "test1":
		handlers.Test1Command(s, i)
	case "read_back":
		handlers.ReadBackCommand(data, s, i)
	case "delete":
		handlers.DeleteCommand(data, s, i)
	case "stop":
		handlers.StopCommand(s, i)
	case "http":
		handlers.HttpCommand(data, s, i)
	}
}
