working example

This commit is contained in:
Jonas Rabenstein 2026-03-05 01:57:37 +01:00
commit e69bcfc23d
18 changed files with 1290 additions and 252 deletions

18
api/src/series.rs Normal file
View file

@ -0,0 +1,18 @@
use restson::{Error, RestPath};
use serde::Deserialize;
use super::SeriesId as Id;
#[derive(Debug, Deserialize)]
pub struct Series {
pub id: Id,
#[serde(flatten)]
pub unknown: serde_json::Value,
}
impl RestPath<Id> for Series {
fn get_path(id: Id) -> std::result::Result<String, Error> {
Ok(format!("series/{id}"))
}
}