MCPcopy Create free account
hub / github.com/devnullvoid/pvetui / Get

Method Get

pkg/api/client.go:47–54  ·  view source on GitHub ↗

Get makes a GET request to the Proxmox API with retry logic and timeout.

(path string, result *map[string]interface{})

Source from the content-addressed store, hash-verified

45
46// Get makes a GET request to the Proxmox API with retry logic and timeout.
47func (c *Client) Get(path string, result *map[string]interface{}) error {
48 ctx, cancel := context.WithTimeout(context.Background(), DefaultAPITimeout)
49 defer cancel()
50
51 c.logger.Debug("API GET: %s", path)
52
53 return c.httpClient.GetWithRetry(ctx, path, result, DefaultRetryCount)
54}
55
56// GetNoRetry makes a GET request to the Proxmox API without retry logic but with timeout.
57func (c *Client) GetNoRetry(path string, result *map[string]interface{}) error {

Callers 10

GetAvailableTemplatesMethod · 0.95
GetNextIDMethod · 0.95
GetVMConfigMethod · 0.95
GetSnapshotsMethod · 0.95
GetWithCacheMethod · 0.95
GetTaskStatusMethod · 0.95
GetClusterTasksMethod · 0.95
TestPVEMockAPIFunction · 0.95
fetchURLFunction · 0.95

Calls 2

DebugMethod · 0.65
GetWithRetryMethod · 0.45

Tested by 1

TestPVEMockAPIFunction · 0.76