pinakes-server: add GET /plugins/ui-pages endpoint

Signed-off-by: NotAShelf <raf@notashelf.dev>
Change-Id: Id09d4dce060e0a79586251a16fb6bdbc6a6a6964
This commit is contained in:
raf 2026-03-09 21:59:22 +03:00
commit 29ba24ae01
Signed by: NotAShelf
GPG key ID: 29D95B64378DB4BF
3 changed files with 35 additions and 1 deletions

View file

@ -1,3 +1,4 @@
use pinakes_plugin_api::UiPage;
use serde::{Deserialize, Serialize};
#[derive(Debug, Serialize)]
@ -21,6 +22,15 @@ pub struct TogglePluginRequest {
pub enabled: bool,
}
/// A single plugin UI page entry in the list response
#[derive(Debug, Serialize)]
pub struct PluginUiPageEntry {
/// Plugin ID that provides this page
pub plugin_id: String,
/// Full page definition
pub page: UiPage,
}
impl PluginResponse {
#[must_use]
pub fn new(meta: pinakes_plugin_api::PluginMetadata, enabled: bool) -> Self {