[pdm-devel] [PATCH datacenter-manager v3 05/12] pdm-client: add API methods for remote update summaries
Lukas Wagner
l.wagner at proxmox.com
Thu Oct 23 14:44:13 CEST 2025
Adds methods to retrieve and refresh the update summary.
Signed-off-by: Lukas Wagner <l.wagner at proxmox.com>
Reviewed-by: Shannon Sterz <s.sterz at proxmox.com>
Tested-by: Shannon Sterz <s.sterz at proxmox.com>
---
lib/pdm-client/src/lib.rs | 22 ++++++++++++++++++++++
1 file changed, 22 insertions(+)
diff --git a/lib/pdm-client/src/lib.rs b/lib/pdm-client/src/lib.rs
index 2f36fab1..0cab7691 100644
--- a/lib/pdm-client/src/lib.rs
+++ b/lib/pdm-client/src/lib.rs
@@ -1109,6 +1109,28 @@ impl<T: HttpApiClient> PdmClient<T> {
}
Ok(self.0.post(&path, ¶ms).await?.expect_json()?.data)
}
+
+ /// Get remote update summary.
+ pub async fn remote_update_summary(
+ &self,
+ ) -> Result<pdm_api_types::remote_updates::UpdateSummary, Error> {
+ Ok(self
+ .0
+ .get("/api2/extjs/remote-updates/summary")
+ .await?
+ .expect_json()?
+ .data)
+ }
+
+ /// Refresh remote update summary.
+ pub async fn refresh_remote_update_summary(&self) -> Result<pdm_api_types::UPID, Error> {
+ Ok(self
+ .0
+ .post_without_body("/api2/extjs/remote-updates/refresh")
+ .await?
+ .expect_json()?
+ .data)
+ }
}
/// Builder for migration parameters.
--
2.47.3
More information about the pdm-devel
mailing list