import { lotteryRequest } from "@/lib/lottery-http";

export type SettingItem = {
  key: string;
  value: unknown;
  group: string;
  description: string | null;
};

export type SettingListResponse = {
  items: SettingItem[];
};

export async function getPublicSettings(group: string): Promise<SettingListResponse> {
  return lotteryRequest.get<SettingListResponse>(`/settings`, {
    params: { group },
  });
}
