Made delete song endpoint available

This commit is contained in:
kdeng00
2025-07-29 16:11:38 -04:00
parent 016cfab506
commit 87907ce5e7
2 changed files with 3 additions and 1 deletions
+1
View File
@@ -19,6 +19,7 @@ pub mod endpoints {
pub const GETSONGS: &str = "/api/v2/song";
pub const STREAMSONG: &str = "/api/v2/song/stream/{id}";
pub const DOWNLOADSONG: &str = "/api/v2/song/download/{id}";
pub const DELETESONG: &str = "/api/v2/song/{id}";
pub const CREATECOVERART: &str = "/api/v2/coverart";
pub const GETCOVERART: &str = "/api/v2/coverart";
pub const DOWNLOADCOVERART: &str = "/api/v2/coverart/download/{id}";
+2 -1
View File
@@ -44,7 +44,7 @@ async fn main() {
}
pub mod init {
use axum::routing::{get, patch, post};
use axum::routing::{delete, get, patch, post};
use std::time::Duration;
use tower_http::timeout::TimeoutLayer;
@@ -135,6 +135,7 @@ pub mod init {
crate::callers::endpoints::DOWNLOADSONG,
get(crate::callers::song::endpoint::download_song),
)
.route(crate::callers::endpoints::DELETESONG, delete(crate::callers::song::endpoint::delete_song))
}
pub async fn app() -> axum::Router {