@infrapilot-jur/sdk 0.4.3 → 0.5.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +26 -0
- package/README.md +28 -2
- package/dist/index.cjs +95 -2
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +490 -11
- package/dist/index.d.ts +490 -11
- package/dist/index.js +95 -2
- package/dist/index.js.map +1 -1
- package/docs/AL3-CANDIDATE-PACK.md +35 -0
- package/docs/KVM-LIVE-METRICS-LM3.md +38 -0
- package/docs/LM3-CANDIDATE-PACK.md +38 -0
- package/docs/operation-coverage.md +13 -1
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -628,6 +628,45 @@ interface paths {
|
|
|
628
628
|
patch?: never;
|
|
629
629
|
trace?: never;
|
|
630
630
|
};
|
|
631
|
+
"/api/v1/node/kvm/{uuid}/metrics": {
|
|
632
|
+
parameters: {
|
|
633
|
+
query?: never;
|
|
634
|
+
header?: never;
|
|
635
|
+
path?: never;
|
|
636
|
+
cookie?: never;
|
|
637
|
+
};
|
|
638
|
+
/**
|
|
639
|
+
* Get an on-demand aggregated KVM live metrics sample
|
|
640
|
+
* @description Returns one `KvmDomainMetrics` sample for the domain (LM1 engine via
|
|
641
|
+
* `GetDomainMetrics`). Reuses the existing CPU/memory/disks/network collectors
|
|
642
|
+
* and shared rate caches; concurrent callers for the same UUID share a single
|
|
643
|
+
* in-flight collect (`singleflight`). Requires `kvm:read`.
|
|
644
|
+
*
|
|
645
|
+
* `collected_at` is the wall time when this metrics sample was assembled
|
|
646
|
+
* (not refreshed when serving concurrent singleflight waiters after the
|
|
647
|
+
* producer finishes). `sample_interval_ns` is the effective wall interval
|
|
648
|
+
* between successive metrics samples for this UUID (null on first/invalid).
|
|
649
|
+
*
|
|
650
|
+
* Subsystem rates (CPU %, disk B/s, NIC B/s) use each collector's own sample
|
|
651
|
+
* baselines and intervals — they are not recomputed from `sample_interval_ns`.
|
|
652
|
+
* Collectors run sequentially; the sample is not an atomic snapshot of all
|
|
653
|
+
* subsystems at one libvirt instant.
|
|
654
|
+
*
|
|
655
|
+
* Unavailable rates are null (never fabricated as 0). Observed zero activity
|
|
656
|
+
* is reported as 0. Partial collector failures appear in `warnings` while
|
|
657
|
+
* successful components remain present. Total failures use platform error
|
|
658
|
+
* mapping (400/404/502). No privileged operation audit is emitted for this
|
|
659
|
+
* read path.
|
|
660
|
+
*/
|
|
661
|
+
get: operations["kvmDomainMetrics"];
|
|
662
|
+
put?: never;
|
|
663
|
+
post?: never;
|
|
664
|
+
delete?: never;
|
|
665
|
+
options?: never;
|
|
666
|
+
head?: never;
|
|
667
|
+
patch?: never;
|
|
668
|
+
trace?: never;
|
|
669
|
+
};
|
|
631
670
|
"/api/v1/node/kvm/{uuid}/start": {
|
|
632
671
|
parameters: {
|
|
633
672
|
query?: never;
|
|
@@ -641,7 +680,9 @@ interface paths {
|
|
|
641
680
|
* Start a libvirt domain
|
|
642
681
|
* @description Starts a defined domain (`DomainCreate`) looked up by UUID. Requires
|
|
643
682
|
* `kvm:power` for client keys; Authelia viewers are denied. Admins always
|
|
644
|
-
* allowed.
|
|
683
|
+
* allowed. Inspect `outcome` (`accepted`/`completed`); 504 `KVM_INDETERMINATE`
|
|
684
|
+
* means the result could not be confirmed after a possible send — re-read state,
|
|
685
|
+
* do not blindly retry.
|
|
645
686
|
*/
|
|
646
687
|
post: operations["startNodeKvmDomain"];
|
|
647
688
|
delete?: never;
|
|
@@ -663,7 +704,8 @@ interface paths {
|
|
|
663
704
|
* Gracefully stop a libvirt domain
|
|
664
705
|
* @description Requests ACPI shutdown (`DomainShutdown`) by UUID. Requires `kvm:power`.
|
|
665
706
|
* A 200 means libvirt accepted the request (or the domain was already shutoff/shutdown);
|
|
666
|
-
* it does not wait for the guest to finish powering off. Inspect `state`
|
|
707
|
+
* it does not wait for the guest to finish powering off. Inspect `outcome`/`state`
|
|
708
|
+
* and re-read the domain. There is no separate `/shutdown` endpoint.
|
|
667
709
|
*/
|
|
668
710
|
post: operations["stopNodeKvmDomain"];
|
|
669
711
|
delete?: never;
|
|
@@ -684,6 +726,7 @@ interface paths {
|
|
|
684
726
|
/**
|
|
685
727
|
* Reboot a libvirt domain
|
|
686
728
|
* @description Requests reboot (`DomainReboot`) by UUID. Requires `kvm:power`.
|
|
729
|
+
* A 200 means libvirt accepted the request; inspect `outcome` and re-read state.
|
|
687
730
|
*/
|
|
688
731
|
post: operations["rebootNodeKvmDomain"];
|
|
689
732
|
delete?: never;
|
|
@@ -692,6 +735,95 @@ interface paths {
|
|
|
692
735
|
patch?: never;
|
|
693
736
|
trace?: never;
|
|
694
737
|
};
|
|
738
|
+
"/api/v1/node/kvm/{uuid}/force-stop": {
|
|
739
|
+
parameters: {
|
|
740
|
+
query?: never;
|
|
741
|
+
header?: never;
|
|
742
|
+
path?: never;
|
|
743
|
+
cookie?: never;
|
|
744
|
+
};
|
|
745
|
+
get?: never;
|
|
746
|
+
put?: never;
|
|
747
|
+
/**
|
|
748
|
+
* Force-stop a libvirt domain
|
|
749
|
+
* @description Abruptly terminates the domain process (`DomainDestroy`) by UUID while
|
|
750
|
+
* preserving the domain definition and disks. This is not domain deletion.
|
|
751
|
+
* Risk: unsaved guest data loss and possible guest filesystem corruption.
|
|
752
|
+
* Requires `kvm:power:destructive` (does not imply `kvm:power`; audited as
|
|
753
|
+
* `node.kvm.force-stop`). A 200 with `outcome=accepted` means libvirt
|
|
754
|
+
* accepted the destroy request.
|
|
755
|
+
*/
|
|
756
|
+
post: operations["forceStopNodeKvmDomain"];
|
|
757
|
+
delete?: never;
|
|
758
|
+
options?: never;
|
|
759
|
+
head?: never;
|
|
760
|
+
patch?: never;
|
|
761
|
+
trace?: never;
|
|
762
|
+
};
|
|
763
|
+
"/api/v1/node/kvm/{uuid}/pause": {
|
|
764
|
+
parameters: {
|
|
765
|
+
query?: never;
|
|
766
|
+
header?: never;
|
|
767
|
+
path?: never;
|
|
768
|
+
cookie?: never;
|
|
769
|
+
};
|
|
770
|
+
get?: never;
|
|
771
|
+
put?: never;
|
|
772
|
+
/**
|
|
773
|
+
* Pause a libvirt domain
|
|
774
|
+
* @description Suspends vCPU execution (`DomainSuspend`). Not shutdown, managed save, or
|
|
775
|
+
* host suspend. Requires `kvm:power`.
|
|
776
|
+
*/
|
|
777
|
+
post: operations["pauseNodeKvmDomain"];
|
|
778
|
+
delete?: never;
|
|
779
|
+
options?: never;
|
|
780
|
+
head?: never;
|
|
781
|
+
patch?: never;
|
|
782
|
+
trace?: never;
|
|
783
|
+
};
|
|
784
|
+
"/api/v1/node/kvm/{uuid}/resume": {
|
|
785
|
+
parameters: {
|
|
786
|
+
query?: never;
|
|
787
|
+
header?: never;
|
|
788
|
+
path?: never;
|
|
789
|
+
cookie?: never;
|
|
790
|
+
};
|
|
791
|
+
get?: never;
|
|
792
|
+
put?: never;
|
|
793
|
+
/**
|
|
794
|
+
* Resume a paused libvirt domain
|
|
795
|
+
* @description Resumes a paused domain (`DomainResume`). Not a substitute for start.
|
|
796
|
+
* Requires `kvm:power`.
|
|
797
|
+
*/
|
|
798
|
+
post: operations["resumeNodeKvmDomain"];
|
|
799
|
+
delete?: never;
|
|
800
|
+
options?: never;
|
|
801
|
+
head?: never;
|
|
802
|
+
patch?: never;
|
|
803
|
+
trace?: never;
|
|
804
|
+
};
|
|
805
|
+
"/api/v1/node/kvm/{uuid}/reset": {
|
|
806
|
+
parameters: {
|
|
807
|
+
query?: never;
|
|
808
|
+
header?: never;
|
|
809
|
+
path?: never;
|
|
810
|
+
cookie?: never;
|
|
811
|
+
};
|
|
812
|
+
get?: never;
|
|
813
|
+
put?: never;
|
|
814
|
+
/**
|
|
815
|
+
* Hard-reset a libvirt domain
|
|
816
|
+
* @description Abrupt CPU reset (`DomainReset`). Distinct from graceful reboot.
|
|
817
|
+
* Risk: unsaved guest data loss. Requires `kvm:power:destructive` (does not
|
|
818
|
+
* imply `kvm:power`; audited as `node.kvm.reset`).
|
|
819
|
+
*/
|
|
820
|
+
post: operations["resetNodeKvmDomain"];
|
|
821
|
+
delete?: never;
|
|
822
|
+
options?: never;
|
|
823
|
+
head?: never;
|
|
824
|
+
patch?: never;
|
|
825
|
+
trace?: never;
|
|
826
|
+
};
|
|
695
827
|
"/api/v1/auth/me": {
|
|
696
828
|
parameters: {
|
|
697
829
|
query?: never;
|
|
@@ -1100,8 +1232,12 @@ interface components {
|
|
|
1100
1232
|
next_cursor?: string;
|
|
1101
1233
|
limit: number;
|
|
1102
1234
|
};
|
|
1103
|
-
/**
|
|
1104
|
-
|
|
1235
|
+
/**
|
|
1236
|
+
* @description Issued API key scopes (exact match). `kvm:power` covers start/stop/reboot/pause/resume.
|
|
1237
|
+
* `kvm:power:destructive` covers force-stop and reset only; it is independent of `kvm:power`.
|
|
1238
|
+
* @enum {string}
|
|
1239
|
+
*/
|
|
1240
|
+
ClientScope: "domains:read" | "domains:write" | "domains:delete" | "domains:health" | "domains:preview" | "kvm:read" | "kvm:power" | "kvm:power:destructive";
|
|
1105
1241
|
Client: {
|
|
1106
1242
|
id: string;
|
|
1107
1243
|
name: string;
|
|
@@ -1432,8 +1568,12 @@ interface components {
|
|
|
1432
1568
|
* @enum {string|null}
|
|
1433
1569
|
*/
|
|
1434
1570
|
memory_used_source?: "guest" | "rss" | "estimated" | null;
|
|
1435
|
-
/**
|
|
1436
|
-
|
|
1571
|
+
/**
|
|
1572
|
+
* @description Power actions suggested for the observed domain state and the caller's scopes.
|
|
1573
|
+
* Conventional actions require `kvm:power`; force-stop/reset require
|
|
1574
|
+
* `kvm:power:destructive`. Hint only — revalidated on execute.
|
|
1575
|
+
*/
|
|
1576
|
+
allowed_actions: ("start" | "stop" | "reboot" | "force-stop" | "pause" | "resume" | "reset")[];
|
|
1437
1577
|
warnings: components["schemas"]["ResourceWarning"][];
|
|
1438
1578
|
};
|
|
1439
1579
|
NodeKvmVCPUStat: {
|
|
@@ -1592,6 +1732,9 @@ interface components {
|
|
|
1592
1732
|
/** @description Server-side rate from samples (≥1s, ≤120s TTL). Null when unavailable. */
|
|
1593
1733
|
rx_bytes_per_sec?: number | null;
|
|
1594
1734
|
tx_bytes_per_sec?: number | null;
|
|
1735
|
+
/** @description Server-side RX packet rate. Null when unavailable — never fabricated as 0. */
|
|
1736
|
+
rx_packets_per_sec?: number | null;
|
|
1737
|
+
tx_packets_per_sec?: number | null;
|
|
1595
1738
|
};
|
|
1596
1739
|
NodeKvmDomainNetwork: {
|
|
1597
1740
|
node_id: string;
|
|
@@ -1610,6 +1753,104 @@ interface components {
|
|
|
1610
1753
|
cores?: number | null;
|
|
1611
1754
|
threads?: number | null;
|
|
1612
1755
|
};
|
|
1756
|
+
/** @description On-demand aggregated live sample (LM1). Rate fields are null when a valid delta is unavailable. Disk `devices[].source` image paths are omitted. */
|
|
1757
|
+
NodeKvmDomainMetrics: {
|
|
1758
|
+
node_id: string;
|
|
1759
|
+
/**
|
|
1760
|
+
* Format: date-time
|
|
1761
|
+
* @description Wall time when this metrics sample was assembled.
|
|
1762
|
+
*/
|
|
1763
|
+
collected_at: string;
|
|
1764
|
+
/** Format: uuid */
|
|
1765
|
+
uuid: string;
|
|
1766
|
+
name: string;
|
|
1767
|
+
state: string;
|
|
1768
|
+
/**
|
|
1769
|
+
* Format: int64
|
|
1770
|
+
* @description Effective wall interval between successive GetDomainMetrics samples for this UUID (≥1s, ≤120s). Null on first sample or invalid interval. Not the denominator used for subsystem rate math.
|
|
1771
|
+
*/
|
|
1772
|
+
sample_interval_ns?: number | null;
|
|
1773
|
+
cpu: components["schemas"]["NodeKvmMetricsCPU"];
|
|
1774
|
+
memory: components["schemas"]["NodeKvmMetricsMemory"];
|
|
1775
|
+
disk: components["schemas"]["NodeKvmMetricsDisk"];
|
|
1776
|
+
network: components["schemas"]["NodeKvmMetricsNetwork"];
|
|
1777
|
+
availability: components["schemas"]["NodeKvmMetricsAvailability"];
|
|
1778
|
+
warnings: components["schemas"]["ResourceWarning"][];
|
|
1779
|
+
};
|
|
1780
|
+
NodeKvmMetricsCPU: {
|
|
1781
|
+
vcpus?: number | null;
|
|
1782
|
+
/**
|
|
1783
|
+
* Format: int64
|
|
1784
|
+
* @description Cumulative CPU time (ns). Prefer server-side usage_percent over browser deltas.
|
|
1785
|
+
*/
|
|
1786
|
+
cpu_time_ns?: number | null;
|
|
1787
|
+
/** @description Normalized VM capacity utilization 0–100: delta_cpu_time_ns / (delta_wall_ns × vcpus) × 100. */
|
|
1788
|
+
usage_percent?: number | null;
|
|
1789
|
+
/** @description Per-vCPU utilization when DomainGetVcpus times are available; null entries when unknown. */
|
|
1790
|
+
vcpu_usage_percent: (number | null)[];
|
|
1791
|
+
};
|
|
1792
|
+
NodeKvmMetricsMemory: {
|
|
1793
|
+
/** Format: int64 */
|
|
1794
|
+
assigned_bytes?: number | null;
|
|
1795
|
+
/** Format: int64 */
|
|
1796
|
+
used_bytes?: number | null;
|
|
1797
|
+
/** Format: int64 */
|
|
1798
|
+
available_bytes?: number | null;
|
|
1799
|
+
/**
|
|
1800
|
+
* Format: int64
|
|
1801
|
+
* @description Host-side QEMU RSS — not guest memory usage.
|
|
1802
|
+
*/
|
|
1803
|
+
rss_bytes?: number | null;
|
|
1804
|
+
used_percent?: number | null;
|
|
1805
|
+
/** @enum {string|null} */
|
|
1806
|
+
memory_used_source?: "guest" | "estimated" | "rss" | null;
|
|
1807
|
+
};
|
|
1808
|
+
NodeKvmMetricsDisk: {
|
|
1809
|
+
devices: components["schemas"]["NodeKvmDisk"][];
|
|
1810
|
+
/** Format: int64 */
|
|
1811
|
+
read_bytes_total?: number | null;
|
|
1812
|
+
/** Format: int64 */
|
|
1813
|
+
write_bytes_total?: number | null;
|
|
1814
|
+
/** Format: int64 */
|
|
1815
|
+
read_ops_total?: number | null;
|
|
1816
|
+
/** Format: int64 */
|
|
1817
|
+
write_ops_total?: number | null;
|
|
1818
|
+
read_bytes_per_sec_total?: number | null;
|
|
1819
|
+
write_bytes_per_sec_total?: number | null;
|
|
1820
|
+
read_iops_total?: number | null;
|
|
1821
|
+
write_iops_total?: number | null;
|
|
1822
|
+
};
|
|
1823
|
+
/** @description RX/TX follow libvirt DomainInterfaceStats (host view of the guest NIC / tap). Totals sum devices with present values only. */
|
|
1824
|
+
NodeKvmMetricsNetwork: {
|
|
1825
|
+
interfaces: components["schemas"]["NodeKvmNIC"][];
|
|
1826
|
+
/** Format: int64 */
|
|
1827
|
+
rx_bytes_total?: number | null;
|
|
1828
|
+
/** Format: int64 */
|
|
1829
|
+
tx_bytes_total?: number | null;
|
|
1830
|
+
/** Format: int64 */
|
|
1831
|
+
rx_packets_total?: number | null;
|
|
1832
|
+
/** Format: int64 */
|
|
1833
|
+
tx_packets_total?: number | null;
|
|
1834
|
+
rx_bytes_per_sec_total?: number | null;
|
|
1835
|
+
tx_bytes_per_sec_total?: number | null;
|
|
1836
|
+
rx_packets_per_sec_total?: number | null;
|
|
1837
|
+
tx_packets_per_sec_total?: number | null;
|
|
1838
|
+
/** Format: int64 */
|
|
1839
|
+
rx_errors_total?: number | null;
|
|
1840
|
+
/** Format: int64 */
|
|
1841
|
+
tx_errors_total?: number | null;
|
|
1842
|
+
/** Format: int64 */
|
|
1843
|
+
rx_drops_total?: number | null;
|
|
1844
|
+
/** Format: int64 */
|
|
1845
|
+
tx_drops_total?: number | null;
|
|
1846
|
+
};
|
|
1847
|
+
NodeKvmMetricsAvailability: {
|
|
1848
|
+
domain_active: boolean;
|
|
1849
|
+
cpu_rates: boolean;
|
|
1850
|
+
memory_used: boolean;
|
|
1851
|
+
disk_rates: boolean;
|
|
1852
|
+
network_rates: boolean;
|
|
1853
|
+
};
|
|
1613
1854
|
NodeKvmDomainConfig: {
|
|
1614
1855
|
node_id: string;
|
|
1615
1856
|
/** Format: date-time */
|
|
@@ -1646,8 +1887,17 @@ interface components {
|
|
|
1646
1887
|
/** @description Domain name at the time of the action (UX). */
|
|
1647
1888
|
name: string;
|
|
1648
1889
|
/** @enum {string} */
|
|
1649
|
-
action: "start" | "stop" | "reboot";
|
|
1890
|
+
action: "start" | "stop" | "reboot" | "force-stop" | "pause" | "resume" | "reset";
|
|
1650
1891
|
state: string;
|
|
1892
|
+
/**
|
|
1893
|
+
* @description accepted = libvirt accepted the mutation (guest may still be transitioning);
|
|
1894
|
+
* completed = idempotent/no-op because state already matched intent;
|
|
1895
|
+
* indeterminate = confirmation unavailable (typically returned as HTTP 504).
|
|
1896
|
+
* @enum {string}
|
|
1897
|
+
*/
|
|
1898
|
+
outcome?: "accepted" | "completed" | "indeterminate";
|
|
1899
|
+
/** @description True when the operation was accepted or completed without error. */
|
|
1900
|
+
accepted?: boolean;
|
|
1651
1901
|
};
|
|
1652
1902
|
NodeKvmDomain: {
|
|
1653
1903
|
name: string;
|
|
@@ -1678,6 +1928,14 @@ interface components {
|
|
|
1678
1928
|
* @enum {string|null}
|
|
1679
1929
|
*/
|
|
1680
1930
|
memory_used_source?: "guest" | "rss" | "estimated" | null;
|
|
1931
|
+
/**
|
|
1932
|
+
* @description Power actions suggested for the observed domain state and the caller's scopes
|
|
1933
|
+
* (same authority as domain detail). Conventional actions require `kvm:power`;
|
|
1934
|
+
* force-stop/reset require `kvm:power:destructive`. Hint only — revalidated on
|
|
1935
|
+
* execute. Computed during inventory collect from DomainGetInfo state (no per-VM
|
|
1936
|
+
* extra HTTP/libvirt round-trips).
|
|
1937
|
+
*/
|
|
1938
|
+
allowed_actions: ("start" | "stop" | "reboot" | "force-stop" | "pause" | "resume" | "reset")[];
|
|
1681
1939
|
};
|
|
1682
1940
|
NodeKvm: {
|
|
1683
1941
|
node_id: string;
|
|
@@ -1784,6 +2042,18 @@ interface components {
|
|
|
1784
2042
|
"application/json": components["schemas"]["Error"];
|
|
1785
2043
|
};
|
|
1786
2044
|
};
|
|
2045
|
+
/**
|
|
2046
|
+
* @description Operation timed out or result is indeterminate after a possible mutation send
|
|
2047
|
+
* (e.g. KVM_INDETERMINATE). Re-read resource state; do not auto-retry mutations.
|
|
2048
|
+
*/
|
|
2049
|
+
GatewayTimeout: {
|
|
2050
|
+
headers: {
|
|
2051
|
+
[name: string]: unknown;
|
|
2052
|
+
};
|
|
2053
|
+
content: {
|
|
2054
|
+
"application/json": components["schemas"]["Error"];
|
|
2055
|
+
};
|
|
2056
|
+
};
|
|
1787
2057
|
};
|
|
1788
2058
|
parameters: {
|
|
1789
2059
|
/** @description Stable libvirt domain UUID (not the temporary numeric domain id). */
|
|
@@ -1832,7 +2102,7 @@ interface operations {
|
|
|
1832
2102
|
/**
|
|
1833
2103
|
* @example {
|
|
1834
2104
|
* "status": "ok",
|
|
1835
|
-
* "version": "0.2.
|
|
2105
|
+
* "version": "0.2.18"
|
|
1836
2106
|
* }
|
|
1837
2107
|
*/
|
|
1838
2108
|
"application/json": components["schemas"]["Health"];
|
|
@@ -2838,6 +3108,34 @@ interface operations {
|
|
|
2838
3108
|
502: components["responses"]["BadGateway"];
|
|
2839
3109
|
};
|
|
2840
3110
|
};
|
|
3111
|
+
kvmDomainMetrics: {
|
|
3112
|
+
parameters: {
|
|
3113
|
+
query?: never;
|
|
3114
|
+
header?: never;
|
|
3115
|
+
path: {
|
|
3116
|
+
/** @description Stable libvirt domain UUID (not the temporary numeric domain id). */
|
|
3117
|
+
uuid: components["parameters"]["KvmDomainUUID"];
|
|
3118
|
+
};
|
|
3119
|
+
cookie?: never;
|
|
3120
|
+
};
|
|
3121
|
+
requestBody?: never;
|
|
3122
|
+
responses: {
|
|
3123
|
+
/** @description Aggregated live metrics sample */
|
|
3124
|
+
200: {
|
|
3125
|
+
headers: {
|
|
3126
|
+
[name: string]: unknown;
|
|
3127
|
+
};
|
|
3128
|
+
content: {
|
|
3129
|
+
"application/json": components["schemas"]["NodeKvmDomainMetrics"];
|
|
3130
|
+
};
|
|
3131
|
+
};
|
|
3132
|
+
400: components["responses"]["BadRequest"];
|
|
3133
|
+
401: components["responses"]["Unauthorized"];
|
|
3134
|
+
403: components["responses"]["Forbidden"];
|
|
3135
|
+
404: components["responses"]["NotFound"];
|
|
3136
|
+
502: components["responses"]["BadGateway"];
|
|
3137
|
+
};
|
|
3138
|
+
};
|
|
2841
3139
|
startNodeKvmDomain: {
|
|
2842
3140
|
parameters: {
|
|
2843
3141
|
query?: never;
|
|
@@ -2863,7 +3161,9 @@ interface operations {
|
|
|
2863
3161
|
401: components["responses"]["Unauthorized"];
|
|
2864
3162
|
403: components["responses"]["Forbidden"];
|
|
2865
3163
|
404: components["responses"]["NotFound"];
|
|
3164
|
+
409: components["responses"]["Conflict"];
|
|
2866
3165
|
502: components["responses"]["BadGateway"];
|
|
3166
|
+
504: components["responses"]["GatewayTimeout"];
|
|
2867
3167
|
};
|
|
2868
3168
|
};
|
|
2869
3169
|
stopNodeKvmDomain: {
|
|
@@ -2891,7 +3191,9 @@ interface operations {
|
|
|
2891
3191
|
401: components["responses"]["Unauthorized"];
|
|
2892
3192
|
403: components["responses"]["Forbidden"];
|
|
2893
3193
|
404: components["responses"]["NotFound"];
|
|
3194
|
+
409: components["responses"]["Conflict"];
|
|
2894
3195
|
502: components["responses"]["BadGateway"];
|
|
3196
|
+
504: components["responses"]["GatewayTimeout"];
|
|
2895
3197
|
};
|
|
2896
3198
|
};
|
|
2897
3199
|
rebootNodeKvmDomain: {
|
|
@@ -2919,7 +3221,129 @@ interface operations {
|
|
|
2919
3221
|
401: components["responses"]["Unauthorized"];
|
|
2920
3222
|
403: components["responses"]["Forbidden"];
|
|
2921
3223
|
404: components["responses"]["NotFound"];
|
|
3224
|
+
409: components["responses"]["Conflict"];
|
|
2922
3225
|
502: components["responses"]["BadGateway"];
|
|
3226
|
+
504: components["responses"]["GatewayTimeout"];
|
|
3227
|
+
};
|
|
3228
|
+
};
|
|
3229
|
+
forceStopNodeKvmDomain: {
|
|
3230
|
+
parameters: {
|
|
3231
|
+
query?: never;
|
|
3232
|
+
header?: never;
|
|
3233
|
+
path: {
|
|
3234
|
+
/** @description Stable libvirt domain UUID (not the temporary numeric domain id). */
|
|
3235
|
+
uuid: components["parameters"]["KvmDomainUUID"];
|
|
3236
|
+
};
|
|
3237
|
+
cookie?: never;
|
|
3238
|
+
};
|
|
3239
|
+
requestBody?: never;
|
|
3240
|
+
responses: {
|
|
3241
|
+
/** @description Power action result */
|
|
3242
|
+
200: {
|
|
3243
|
+
headers: {
|
|
3244
|
+
[name: string]: unknown;
|
|
3245
|
+
};
|
|
3246
|
+
content: {
|
|
3247
|
+
"application/json": components["schemas"]["NodeKvmPowerResult"];
|
|
3248
|
+
};
|
|
3249
|
+
};
|
|
3250
|
+
400: components["responses"]["BadRequest"];
|
|
3251
|
+
401: components["responses"]["Unauthorized"];
|
|
3252
|
+
403: components["responses"]["Forbidden"];
|
|
3253
|
+
404: components["responses"]["NotFound"];
|
|
3254
|
+
409: components["responses"]["Conflict"];
|
|
3255
|
+
502: components["responses"]["BadGateway"];
|
|
3256
|
+
504: components["responses"]["GatewayTimeout"];
|
|
3257
|
+
};
|
|
3258
|
+
};
|
|
3259
|
+
pauseNodeKvmDomain: {
|
|
3260
|
+
parameters: {
|
|
3261
|
+
query?: never;
|
|
3262
|
+
header?: never;
|
|
3263
|
+
path: {
|
|
3264
|
+
/** @description Stable libvirt domain UUID (not the temporary numeric domain id). */
|
|
3265
|
+
uuid: components["parameters"]["KvmDomainUUID"];
|
|
3266
|
+
};
|
|
3267
|
+
cookie?: never;
|
|
3268
|
+
};
|
|
3269
|
+
requestBody?: never;
|
|
3270
|
+
responses: {
|
|
3271
|
+
/** @description Power action result */
|
|
3272
|
+
200: {
|
|
3273
|
+
headers: {
|
|
3274
|
+
[name: string]: unknown;
|
|
3275
|
+
};
|
|
3276
|
+
content: {
|
|
3277
|
+
"application/json": components["schemas"]["NodeKvmPowerResult"];
|
|
3278
|
+
};
|
|
3279
|
+
};
|
|
3280
|
+
400: components["responses"]["BadRequest"];
|
|
3281
|
+
401: components["responses"]["Unauthorized"];
|
|
3282
|
+
403: components["responses"]["Forbidden"];
|
|
3283
|
+
404: components["responses"]["NotFound"];
|
|
3284
|
+
409: components["responses"]["Conflict"];
|
|
3285
|
+
502: components["responses"]["BadGateway"];
|
|
3286
|
+
504: components["responses"]["GatewayTimeout"];
|
|
3287
|
+
};
|
|
3288
|
+
};
|
|
3289
|
+
resumeNodeKvmDomain: {
|
|
3290
|
+
parameters: {
|
|
3291
|
+
query?: never;
|
|
3292
|
+
header?: never;
|
|
3293
|
+
path: {
|
|
3294
|
+
/** @description Stable libvirt domain UUID (not the temporary numeric domain id). */
|
|
3295
|
+
uuid: components["parameters"]["KvmDomainUUID"];
|
|
3296
|
+
};
|
|
3297
|
+
cookie?: never;
|
|
3298
|
+
};
|
|
3299
|
+
requestBody?: never;
|
|
3300
|
+
responses: {
|
|
3301
|
+
/** @description Power action result */
|
|
3302
|
+
200: {
|
|
3303
|
+
headers: {
|
|
3304
|
+
[name: string]: unknown;
|
|
3305
|
+
};
|
|
3306
|
+
content: {
|
|
3307
|
+
"application/json": components["schemas"]["NodeKvmPowerResult"];
|
|
3308
|
+
};
|
|
3309
|
+
};
|
|
3310
|
+
400: components["responses"]["BadRequest"];
|
|
3311
|
+
401: components["responses"]["Unauthorized"];
|
|
3312
|
+
403: components["responses"]["Forbidden"];
|
|
3313
|
+
404: components["responses"]["NotFound"];
|
|
3314
|
+
409: components["responses"]["Conflict"];
|
|
3315
|
+
502: components["responses"]["BadGateway"];
|
|
3316
|
+
504: components["responses"]["GatewayTimeout"];
|
|
3317
|
+
};
|
|
3318
|
+
};
|
|
3319
|
+
resetNodeKvmDomain: {
|
|
3320
|
+
parameters: {
|
|
3321
|
+
query?: never;
|
|
3322
|
+
header?: never;
|
|
3323
|
+
path: {
|
|
3324
|
+
/** @description Stable libvirt domain UUID (not the temporary numeric domain id). */
|
|
3325
|
+
uuid: components["parameters"]["KvmDomainUUID"];
|
|
3326
|
+
};
|
|
3327
|
+
cookie?: never;
|
|
3328
|
+
};
|
|
3329
|
+
requestBody?: never;
|
|
3330
|
+
responses: {
|
|
3331
|
+
/** @description Power action result */
|
|
3332
|
+
200: {
|
|
3333
|
+
headers: {
|
|
3334
|
+
[name: string]: unknown;
|
|
3335
|
+
};
|
|
3336
|
+
content: {
|
|
3337
|
+
"application/json": components["schemas"]["NodeKvmPowerResult"];
|
|
3338
|
+
};
|
|
3339
|
+
};
|
|
3340
|
+
400: components["responses"]["BadRequest"];
|
|
3341
|
+
401: components["responses"]["Unauthorized"];
|
|
3342
|
+
403: components["responses"]["Forbidden"];
|
|
3343
|
+
404: components["responses"]["NotFound"];
|
|
3344
|
+
409: components["responses"]["Conflict"];
|
|
3345
|
+
502: components["responses"]["BadGateway"];
|
|
3346
|
+
504: components["responses"]["GatewayTimeout"];
|
|
2923
3347
|
};
|
|
2924
3348
|
};
|
|
2925
3349
|
getAuthMe: {
|
|
@@ -3642,12 +4066,24 @@ declare class DomainsResource {
|
|
|
3642
4066
|
type NodeKvmDomain = components["schemas"]["NodeKvmDomain"];
|
|
3643
4067
|
type NodeKvm = components["schemas"]["NodeKvm"];
|
|
3644
4068
|
type NodeKvmPowerResult = components["schemas"]["NodeKvmPowerResult"];
|
|
4069
|
+
/** Observed domain power action names from OpenAPI `allowed_actions` / power `action`. */
|
|
4070
|
+
type NodeKvmAllowedAction = NonNullable<components["schemas"]["NodeKvmDomainDetail"]["allowed_actions"]>[number];
|
|
4071
|
+
/** Backend outcome for a power mutation (`accepted` | `completed` | `indeterminate`). */
|
|
4072
|
+
type NodeKvmPowerOutcome = NonNullable<NodeKvmPowerResult["outcome"]>;
|
|
3645
4073
|
type NodeKvmDomainDetail = components["schemas"]["NodeKvmDomainDetail"];
|
|
3646
4074
|
type NodeKvmDomainCPU = components["schemas"]["NodeKvmDomainCPU"];
|
|
3647
4075
|
type NodeKvmDomainMemory = components["schemas"]["NodeKvmDomainMemory"];
|
|
3648
4076
|
type NodeKvmDomainDisks = components["schemas"]["NodeKvmDomainDisks"];
|
|
3649
4077
|
type NodeKvmDomainNetwork = components["schemas"]["NodeKvmDomainNetwork"];
|
|
3650
4078
|
type NodeKvmDomainConfig = components["schemas"]["NodeKvmDomainConfig"];
|
|
4079
|
+
type NodeKvmDomainMetrics = components["schemas"]["NodeKvmDomainMetrics"];
|
|
4080
|
+
type NodeKvmMetricsCPU = components["schemas"]["NodeKvmMetricsCPU"];
|
|
4081
|
+
type NodeKvmMetricsMemory = components["schemas"]["NodeKvmMetricsMemory"];
|
|
4082
|
+
type NodeKvmMetricsDisk = components["schemas"]["NodeKvmMetricsDisk"];
|
|
4083
|
+
type NodeKvmMetricsNetwork = components["schemas"]["NodeKvmMetricsNetwork"];
|
|
4084
|
+
type NodeKvmMetricsAvailability = components["schemas"]["NodeKvmMetricsAvailability"];
|
|
4085
|
+
type NodeKvmDisk = components["schemas"]["NodeKvmDisk"];
|
|
4086
|
+
type NodeKvmNIC = components["schemas"]["NodeKvmNIC"];
|
|
3651
4087
|
/**
|
|
3652
4088
|
* Nested KVM/libvirt surface under `infra.node.kvm`.
|
|
3653
4089
|
*/
|
|
@@ -3662,9 +4098,52 @@ declare class NodeKvmResource {
|
|
|
3662
4098
|
disks(uuid: string, ctx?: RequestContext): Promise<NodeKvmDomainDisks>;
|
|
3663
4099
|
network(uuid: string, ctx?: RequestContext): Promise<NodeKvmDomainNetwork>;
|
|
3664
4100
|
config(uuid: string, ctx?: RequestContext): Promise<NodeKvmDomainConfig>;
|
|
4101
|
+
/**
|
|
4102
|
+
* On-demand aggregated live metrics sample (`kvmDomainMetrics`).
|
|
4103
|
+
* Requires `kvm:read`. Pass `ctx.signal` / `ctx.timeoutMs` for Panel cancellation.
|
|
4104
|
+
* Does not poll, retry, or recompute server-side rates.
|
|
4105
|
+
*/
|
|
4106
|
+
metrics(uuid: string, ctx?: RequestContext): Promise<NodeKvmDomainMetrics>;
|
|
4107
|
+
/**
|
|
4108
|
+
* Start a defined domain (`DomainCreate`). Requires `kvm:power`.
|
|
4109
|
+
* A successful response means libvirt accepted the request (see `outcome`);
|
|
4110
|
+
* it does not fabricate guest readiness. No automatic retries.
|
|
4111
|
+
*/
|
|
3665
4112
|
start(uuid: string, ctx?: RequestContext): Promise<NodeKvmPowerResult>;
|
|
4113
|
+
/**
|
|
4114
|
+
* Request graceful ACPI shutdown (`DomainShutdown`). Requires `kvm:power`.
|
|
4115
|
+
* Does not guarantee immediate shutoff — inspect `outcome`/`state` and re-read.
|
|
4116
|
+
* There is no `shutdown()` helper; use `stop`. No automatic retries.
|
|
4117
|
+
*/
|
|
3666
4118
|
stop(uuid: string, ctx?: RequestContext): Promise<NodeKvmPowerResult>;
|
|
4119
|
+
/**
|
|
4120
|
+
* Request reboot (`DomainReboot`). Requires `kvm:power`.
|
|
4121
|
+
* Acceptance ≠ guest finished rebooting. No automatic retries.
|
|
4122
|
+
*/
|
|
3667
4123
|
reboot(uuid: string, ctx?: RequestContext): Promise<NodeKvmPowerResult>;
|
|
4124
|
+
/**
|
|
4125
|
+
* Abruptly terminate the domain process (`DomainDestroy`) — not domain deletion.
|
|
4126
|
+
* Preserves definition and disks. Risk: unsaved guest data / filesystem corruption.
|
|
4127
|
+
* HTTP path uses `force-stop`; this method is `forceStop`. Requires `kvm:power:destructive`.
|
|
4128
|
+
* No fallback to `stop`. No automatic retries.
|
|
4129
|
+
*/
|
|
4130
|
+
forceStop(uuid: string, ctx?: RequestContext): Promise<NodeKvmPowerResult>;
|
|
4131
|
+
/**
|
|
4132
|
+
* Suspend vCPU execution (`DomainSuspend`). Not shutdown or managed save.
|
|
4133
|
+
* Requires `kvm:power`. No automatic retries.
|
|
4134
|
+
*/
|
|
4135
|
+
pause(uuid: string, ctx?: RequestContext): Promise<NodeKvmPowerResult>;
|
|
4136
|
+
/**
|
|
4137
|
+
* Resume a paused domain (`DomainResume`). Not a substitute for `start`.
|
|
4138
|
+
* Requires `kvm:power`. No automatic retries.
|
|
4139
|
+
*/
|
|
4140
|
+
resume(uuid: string, ctx?: RequestContext): Promise<NodeKvmPowerResult>;
|
|
4141
|
+
/**
|
|
4142
|
+
* Abrupt CPU reset (`DomainReset`). Distinct from graceful `reboot`.
|
|
4143
|
+
* Risk: unsaved guest data loss. Requires `kvm:power:destructive`.
|
|
4144
|
+
* No fallback to `reboot`. No automatic retries.
|
|
4145
|
+
*/
|
|
4146
|
+
reset(uuid: string, ctx?: RequestContext): Promise<NodeKvmPowerResult>;
|
|
3668
4147
|
}
|
|
3669
4148
|
|
|
3670
4149
|
type NodeIdentity = components["schemas"]["NodeIdentity"];
|
|
@@ -3803,7 +4282,7 @@ declare class InfraPilotTransportError extends InfraPilotError {
|
|
|
3803
4282
|
}
|
|
3804
4283
|
|
|
3805
4284
|
declare const openapiSourcePath = "../../services/domains/docs/openapi.yaml";
|
|
3806
|
-
declare const openapiSha256 = "
|
|
3807
|
-
declare const generatedAt = "
|
|
4285
|
+
declare const openapiSha256 = "08a921bdaa0214b92f54bb88d6e535fd343e9b0915197c572290ea797de47ac7";
|
|
4286
|
+
declare const generatedAt = "08a921bdaa0214b92f54bb88d6e535fd343e9b0915197c572290ea797de47ac7";
|
|
3808
4287
|
|
|
3809
|
-
export { type APIKeyCreateInput, type APIKeyCreated, type APIKeyListResponse, type APIKeyPublic, type APIKeyResponse, type APIKeyRotated, type APIKeyUpdateInput, type AuthErrorCode, AuthErrorCodes, type AuthMeResponse, type AuthMode, type BackupListResponse, type BackupRestoreResponse, type CaddyStatusResponse, type CapabilityStatus, type Client, type ClientCreateInput, type ClientListResponse, type ClientResponse, type ClientScope, type ClientUpdateInput, type CredentialsMode, type DetailedHealth, type Domain, type DomainConfigResponse, type DomainCreateInput, type DomainDeleteResponse, type DomainListResponse, type DomainMutationResponse, type DomainProbeResponse, type DomainResponse, type DomainUpdateInput, type Health, InfraPilot, InfraPilotError, type InfraPilotErrorBody, InfraPilotHttpError, type InfraPilotOptions, InfraPilotTransportError, type ListAPIKeysParams, type ListCaddyLogsParams, type ListClientsParams, type ListOperationsParams, type ListProcessesParams, type LogPage, type NodeCapabilitiesReport, type NodeCapability, type NodeIdentity, type NodeKvm, type NodeKvmDomain, type NodeKvmDomainCPU, type NodeKvmDomainConfig, type NodeKvmDomainDetail, type NodeKvmDomainDisks, type NodeKvmDomainMemory, type NodeKvmDomainNetwork, type NodeKvmPowerResult, NodeKvmResource, type NodeNetwork, type NodeNetworkAddress, type NodeNetworkInterface, type NodeProcess, type NodeProcesses, type NodeResources, type NodeResponse, type NodeService, type NodeServices, type NodeUpdateInput, type OperationsPage, type PreviewCreateRequest, type PreviewDeleteRequest, type PreviewRequest, type PreviewResponse, type PreviewUpdateRequest, type Principal, type RequestContext, type ResourceWarning, type components, generatedAt, openapiSha256, openapiSourcePath, type operations, type paths };
|
|
4288
|
+
export { type APIKeyCreateInput, type APIKeyCreated, type APIKeyListResponse, type APIKeyPublic, type APIKeyResponse, type APIKeyRotated, type APIKeyUpdateInput, type AuthErrorCode, AuthErrorCodes, type AuthMeResponse, type AuthMode, type BackupListResponse, type BackupRestoreResponse, type CaddyStatusResponse, type CapabilityStatus, type Client, type ClientCreateInput, type ClientListResponse, type ClientResponse, type ClientScope, type ClientUpdateInput, type CredentialsMode, type DetailedHealth, type Domain, type DomainConfigResponse, type DomainCreateInput, type DomainDeleteResponse, type DomainListResponse, type DomainMutationResponse, type DomainProbeResponse, type DomainResponse, type DomainUpdateInput, type Health, InfraPilot, InfraPilotError, type InfraPilotErrorBody, InfraPilotHttpError, type InfraPilotOptions, InfraPilotTransportError, type ListAPIKeysParams, type ListCaddyLogsParams, type ListClientsParams, type ListOperationsParams, type ListProcessesParams, type LogPage, type NodeCapabilitiesReport, type NodeCapability, type NodeIdentity, type NodeKvm, type NodeKvmAllowedAction, type NodeKvmDisk, type NodeKvmDomain, type NodeKvmDomainCPU, type NodeKvmDomainConfig, type NodeKvmDomainDetail, type NodeKvmDomainDisks, type NodeKvmDomainMemory, type NodeKvmDomainMetrics, type NodeKvmDomainNetwork, type NodeKvmMetricsAvailability, type NodeKvmMetricsCPU, type NodeKvmMetricsDisk, type NodeKvmMetricsMemory, type NodeKvmMetricsNetwork, type NodeKvmNIC, type NodeKvmPowerOutcome, type NodeKvmPowerResult, NodeKvmResource, type NodeNetwork, type NodeNetworkAddress, type NodeNetworkInterface, type NodeProcess, type NodeProcesses, type NodeResources, type NodeResponse, type NodeService, type NodeServices, type NodeUpdateInput, type OperationsPage, type PreviewCreateRequest, type PreviewDeleteRequest, type PreviewRequest, type PreviewResponse, type PreviewUpdateRequest, type Principal, type RequestContext, type ResourceWarning, type components, generatedAt, openapiSha256, openapiSourcePath, type operations, type paths };
|