Proxy Settings
Section titled “Proxy Settings”Container-wide proxy root settings for the Proxy Discovery service. These endpoints manage the enable_proxy kill-switch and the default allow/deny policy that gates every proxy rule under it.
Use GET to read the current settings and the file:v<N> ETag, then PUT (or PATCH, which the endpoint accepts with identical behavior) to mutate one or both fields under optimistic-concurrency control.
Get container proxy root settings
Section titled “Get container proxy root settings”Returns { enable_proxy, default } along with a file_version and etag for use as a precondition on the next update. The propagation object reports rollout state to running instances.
GET /api/v1/containers/{id}/proxy/settings
Section titled “GET /api/v1/containers/{id}/proxy/settings”curl -X GET "https://api.hoody.com/api/v1/containers/{containerId}/proxy/settings" \ -H "Authorization: Bearer <token>"import { HoodyClient } from 'hoody-sdk';
const client = new HoodyClient({ baseURL: 'https://api.hoody.com', token: process.env.HOODY_TOKEN });
await client.api.proxy.settings.get('{containerId}');{ "statusCode": 200, "message": "Proxy settings retrieved successfully", "data": { "enable_proxy": true, "default": "deny", "file_version": 3, "etag": "file:v3" }, "propagation": { "committed": true, "complete": true, "state": "applied", "status_scope": "current", "generation": 3, "action": "read", "file_version": 3, "succeeded_count": 1, "failed_count": 0, "pending_count": 0, "target_count": 1, "retained_count": 1 }}Validation Error: the request does not match the operation schema, or its JSON body cannot be parsed. message names each failing check, and data, when present, lists them one entry per failing field.
{ "statusCode": 422, "error": "Validation Error", "message": "Validation failed: /name must NOT have fewer than 3 characters"}Parameters
Section titled “Parameters”| Name | In | Type | Required | Description |
|---|---|---|---|---|
id | path | string | Yes | Container ID |
Response fields
Section titled “Response fields”| Field | Type | Description |
|---|---|---|
statusCode | number | HTTP-style status code returned in the envelope |
message | string | Human-readable summary of the outcome |
data.enable_proxy | boolean | Kill-switch for the entire proxy system. When false, every proxy request is blocked |
data.default | string | Default policy applied when no rule matches: allow or deny |
data.file_version | integer | Monotonic version counter for the settings file |
data.etag | string | Opaque ETag (file:v<N>) to send back as If-Match on update |
propagation.committed | boolean | Whether the change has been committed to the source of truth |
propagation.complete | boolean | Whether every target instance has acknowledged the change |
propagation.state | string | Rollout state: pending, applied, failed, unknown, or superseded |
propagation.status_scope | string | Scope of the reported status, here always current |
propagation.generation | integer | Generation number of the change being reported on |
propagation.action | string | Action that triggered this propagation record |
propagation.file_version | integer | File version associated with this propagation |
propagation.succeeded_count | integer | Number of instances that applied the change successfully |
propagation.failed_count | integer | Number of instances that failed to apply the change |
propagation.pending_count | integer | Number of instances that have not yet acknowledged |
propagation.target_count | integer | Total number of instances the change was targeted at |
propagation.retained_count | integer | Number of instances that retain an older generation |
Update container proxy root settings
Section titled “Update container proxy root settings”Updates one or both of enable_proxy and default. Optimistic concurrency is enforced through the If-Match header, which must carry the file:v<N> ETag returned by the previous GET. The endpoint also accepts PATCH with identical behavior.
PUT /api/v1/containers/{id}/proxy/settings
Section titled “PUT /api/v1/containers/{id}/proxy/settings”curl -X PUT "https://api.hoody.com/api/v1/containers/{containerId}/proxy/settings" \ -H "Authorization: Bearer <token>" \ -H "Content-Type: application/json" \ -H "If-Match: file:v3" \ -d '{ "enable_proxy": true, "default": "allow" }'import { HoodyClient } from 'hoody-sdk';
const client = new HoodyClient({ baseURL: 'https://api.hoody.com', token: process.env.HOODY_TOKEN });
await client.api.proxy.settings.update( '{containerId}', { enable_proxy: true, default: 'allow' }, { ifMatch: 'file:v3' });{ "statusCode": 200, "message": "Proxy settings updated successfully", "data": { "enable_proxy": true, "default": "allow", "file_version": 4, "etag": "file:v4" }, "propagation": { "committed": true, "complete": false, "state": "pending", "status_scope": "current", "generation": 4, "action": "update", "file_version": 4, "succeeded_count": 0, "failed_count": 0, "pending_count": 1, "target_count": 1, "retained_count": 0 }}Validation Error: the request does not match the operation schema, or its JSON body cannot be parsed. message names each failing check, and data, when present, lists them one entry per failing field.
{ "statusCode": 422, "error": "Validation Error", "message": "Validation failed: /name must NOT have fewer than 3 characters"}Parameters
Section titled “Parameters”| Name | In | Type | Required | Description |
|---|---|---|---|---|
id | path | string | Yes | Container ID |
if-match | header | string | Yes | file:v<N> ETag precondition returned by the previous read |
Request body
Section titled “Request body”Send at least one of the fields. Omitting both violates minProperties: 1 and is rejected.
| Field | Type | Required | Description |
|---|---|---|---|
enable_proxy | boolean | No | Kill-switch for the entire proxy system. When false, every proxy request is blocked |
default | string | No | Default policy applied when no rule matches. Allowed values: allow, deny |
{ "enable_proxy": true, "default": "allow"}Response fields
Section titled “Response fields”| Field | Type | Description |
|---|---|---|
statusCode | number | HTTP-style status code returned in the envelope |
message | string | Human-readable summary of the outcome |
data.enable_proxy | boolean | Updated value of the kill-switch |
data.default | string | Updated default policy: allow or deny |
data.file_version | integer | New monotonic version counter after the update |
data.etag | string | New ETag (file:v<N>) to use for the next update |
propagation.committed | boolean | Whether the change has been committed to the source of truth |
propagation.complete | boolean | Whether every target instance has acknowledged the change |
propagation.state | string | Rollout state: pending, applied, failed, unknown, or superseded |
propagation.status_scope | string | Scope of the reported status, here always current |
propagation.generation | integer | Generation number of the change being reported on |
propagation.action | string | Action that triggered this propagation record |
propagation.file_version | integer | File version associated with this propagation |
propagation.succeeded_count | integer | Number of instances that applied the change successfully |
propagation.failed_count | integer | Number of instances that failed to apply the change |
propagation.pending_count | integer | Number of instances that have not yet acknowledged |
propagation.target_count | integer | Total number of instances the change was targeted at |
propagation.retained_count | integer | Number of instances that retain an older generation |