added substitutions endpoints

This commit is contained in:
vextrixes committed 2026-10-29 18:35:19 +01:00
1 parent 01607db3e4
commit 32b2d69a43
8 files changed
+60 -7

No files matched your search

+9
View File
@@ -0,0 +1,9 @@
use serde::{Deserialize, Serialize};
#[derive(Debug, Clone, Serialize, Deserialize)]
#[serde(rename_all = "PascalCase")]
pub struct ApiInfo {
pub api_version: String,
pub application_version: String,
pub base_url: String,
}
+15
View File
@@ -0,0 +1,15 @@
use std::marker::PhantomData;
use crate::{ApiInfo, Endpoint};
pub const API_V3_INFO_ENDPOINT: Endpoint<(), ApiInfo> = Endpoint::Get {
url: "/api/3",
auth: false,
_types: PhantomData,
};
pub const APIS_INFO_ENDPOINT: Endpoint<(), Vec<ApiInfo>> = Endpoint::Get {
url: "/api",
auth: false,
_types: PhantomData,
};
+5
View File
@@ -0,0 +1,5 @@
mod api_info;
mod endpoints;
pub use api_info::*;
pub use endpoints::*;