use bon::Builder;
use neptunium_model::id::{
    Id,
    marker::{GuildMarker, RoleMarker},
};
use reqwest::Method;

use crate::{endpoints::Endpoint, request::Request};

#[derive(Builder, Copy, Clone, Debug)]
pub struct DeleteGuildRole {
    pub guild_id: Id<GuildMarker>,
    pub role_id: Id<RoleMarker>,
}

impl Endpoint for DeleteGuildRole {
    type Response = ();

    fn into_request(self) -> crate::request::Request {
        Request::builder()
            .method(Method::DELETE)
            .path(format!("/guilds/{}/roles/{}", self.guild_id, self.role_id))
            .build()
    }
}
