ToggleAuthFile enables or disables an auth file.
(name string, disabled bool)
| 167 | |
| 168 | // ToggleAuthFile enables or disables an auth file. |
| 169 | func (c *Client) ToggleAuthFile(name string, disabled bool) error { |
| 170 | body, _ := json.Marshal(map[string]any{"name": name, "disabled": disabled}) |
| 171 | _, err := c.patch("/v0/management/auth-files/status", strings.NewReader(string(body))) |
| 172 | return err |
| 173 | } |
| 174 | |
| 175 | // PatchAuthFileFields updates editable fields on an auth file. |
| 176 | func (c *Client) PatchAuthFileFields(name string, fields map[string]any) error { |
no test coverage detected