Extract responses

This commit is contained in:
Andras Schmelczer 2024-12-14 16:48:31 +00:00
parent f803ec0da5
commit fe8d236948
No known key found for this signature in database
GPG key ID: FC8F2C3D3D1A718C
3 changed files with 21 additions and 2 deletions

View file

@ -0,0 +1,18 @@
use schemars::JsonSchema;
use serde::{self, Serialize};
use crate::database::models::{DocumentVersionWithoutContent, VaultUpdateId};
#[derive(Debug, Clone, Serialize, JsonSchema)]
#[serde(rename_all = "camelCase")]
pub struct PingResponse {
pub server_version: String,
pub is_authenticated: bool,
}
#[derive(Debug, Clone, Serialize, JsonSchema)]
#[serde(rename_all = "camelCase")]
pub struct FetchLatestDocumentsResponse {
pub latest_documents: Vec<DocumentVersionWithoutContent>,
pub last_update_id: VaultUpdateId,
}