async def set_prefix(self, ctx, prefix): data.add_prefix_mapping(ctx.guild.id, prefix)
async def add_mapping(mapping: PrefixMapping, guildId: str): data.add_prefix_mapping(guildId, mapping.prefix) prefix = data.get_prefix(guildId) if not prefix: raise HTTPException(status_code=404, detail="Prefix not found") return {"guildId": guildId, "prefix": prefix}