action hetzner_get_load_balancers { label: "Get all Load Balancers" description: "Gets all existing Load Balancers that you have available." provider: hetzner method: GET path: "/load_balancers" encoding: json input: { type: "object" properties: { label_selector: { type: "string" } name: { type: "string" } sort: { type: "string" enum: ["id", "id:asc", "id:desc", "name", "name:asc", "name:desc", "created", "created:asc", "created:desc"] } } additionalProperties: false } output: { type: "object" required: ["load_balancers"] properties: { load_balancers: { type: "array" items: { type: "object" required: ["id", "name", "public_net", "private_net", "location", "load_balancer_type", "protection", "labels", "created", "services", "targets", "algorithm", "outgoing_traffic", "ingoing_traffic", "included_traffic"] properties: { algorithm: { type: "object" description: "Algorithm of the Load Balancer" required: ["type"] properties: { type: { type: "string" description: "Type of the algorithm" enum: ["round_robin", "least_connections"] } } } created: { type: "string" description: "Point in time when the Resource was created (in ISO-8601 format)" } id: { type: "integer" description: "ID of the Resource" } included_traffic: { type: "integer" description: "Free Traffic for the current billing period in bytes" } ingoing_traffic: { type: "integer" description: "Inbound Traffic for the current billing period in bytes" } labels: { type: "object" description: "User-defined labels (key-value pairs)" } load_balancer_type: { type: "object" required: ["id", "name", "description", "max_connections", "max_services", "max_targets", "max_assigned_certificates", "deprecated", "prices"] properties: { deprecated: { type: "string" description: "Point in time when the Load Balancer type is deprecated (in ISO-8601 format)" } description: { type: "string" description: "Description of the Load Balancer type" } id: { type: "number" description: "ID of the Load Balancer type" } max_assigned_certificates: { type: "number" description: "Number of SSL Certificates that can be assigned to a single Load Balancer" } max_connections: { type: "number" description: "Number of maximum simultaneous open connections" } max_services: { type: "number" description: "Number of services a Load Balancer of this type can have" } max_targets: { type: "number" description: "Number of targets a single Load Balancer can have" } name: { type: "string" description: "Unique identifier of the Load Balancer type" } prices: { type: "array" description: "Prices in different network zones" items: { type: "object" required: ["location", "price_hourly", "price_monthly"] properties: { location: { type: "string" description: "Name of the Location the price is for" } price_hourly: { type: "object" description: "Hourly costs for a Resource in this Location" required: ["net", "gross"] properties: { gross: { type: "string" description: "Price with VAT added" } net: { type: "string" description: "Price without VAT" } } } price_monthly: { type: "object" description: "Monthly costs for a Resource in this Location" required: ["net", "gross"] properties: { gross: { type: "string" description: "Price with VAT added" } net: { type: "string" description: "Price without VAT" } } } } } } } } location: { type: "object" required: ["id", "name", "description", "country", "city", "latitude", "longitude", "network_zone"] properties: { city: { type: "string" description: "City the Location is closest to" } country: { type: "string" description: "ISO 3166-1 alpha-2 code of the country the Location resides in" } description: { type: "string" description: "Description of the Location" } id: { type: "number" description: "ID of the Location" } latitude: { type: "number" description: "Latitude of the city closest to the Location" } longitude: { type: "number" description: "Longitude of the city closest to the Location" } name: { type: "string" description: "Unique identifier of the Location" } network_zone: { type: "string" description: "Name of network zone this Location resides in" } } } name: { type: "string" description: "Name of the Resource. Must be unique per Project." } outgoing_traffic: { type: "integer" description: "Outbound Traffic for the current billing period in bytes" } private_net: { type: "array" description: "Private networks information" items: { type: "object" properties: { ip: { type: "string" } network: { type: "integer" } } } } protection: { type: "object" description: "Protection configuration for the Resource" required: ["delete"] properties: { delete: { type: "boolean" description: "If true, prevents the Resource from being deleted" } } } public_net: { type: "object" description: "Public network information" required: ["enabled", "ipv4", "ipv6"] properties: { enabled: { type: "boolean" description: "Public Interface enabled or not" } ipv4: { type: "object" description: "IP address (v4)" properties: { dns_ptr: { type: "string" description: "Reverse DNS PTR entry for the IPv4 address of this Load Balancer" } ip: { type: "string" description: "IP address (v4) of this Load Balancer" } } } ipv6: { type: "object" description: "IP address (v6)" properties: { dns_ptr: { type: "string" description: "Reverse DNS PTR entry for the IPv6 address of this Load Balancer" } ip: { type: "string" description: "IP address (v6) of this Load Balancer" } } } } } services: { type: "array" description: "List of services that belong to this Load Balancer" items: { type: "object" required: ["protocol", "listen_port", "destination_port", "proxyprotocol", "health_check"] properties: { destination_port: { type: "integer" description: "Port the Load Balancer will balance to" } health_check: { type: "object" description: "Service health check" required: ["protocol", "port", "interval", "timeout", "retries"] properties: { http: { type: "object" description: "Additional configuration for protocol http" required: ["domain", "path"] properties: { domain: { type: "string" description: "Host header to send in the HTTP request. May not contain spaces, percent or backslash symbols. Can be null, in that case no host header is sent." } path: { type: "string" description: "HTTP path to use for health checks. May not contain literal spaces, use percent-encoding instead." } response: { type: "string" description: "String that must be contained in HTTP response in order to pass the health check" } status_codes: { type: "array" description: "List of returned HTTP status codes in order to pass the health check. Supports the wildcards `?` for exactly one character and `*` for multiple ones. The default is to pass the health check for any status code between 2?? and 3??." items: { type: "object" additionalProperties: true } } tls: { type: "boolean" description: "Use HTTPS for health check" } } additionalProperties: false } interval: { type: "integer" description: "Time interval in seconds health checks are performed" } port: { type: "integer" description: "Port the health check will be performed on" } protocol: { type: "string" description: "Type of the health check" enum: ["tcp", "http"] } retries: { type: "integer" description: "Unsuccessful retries needed until a target is considered unhealthy; an unhealthy target needs the same number of successful retries to become healthy again" } timeout: { type: "integer" description: "Time in seconds after an attempt is considered a timeout" } } additionalProperties: false } http: { type: "object" description: "Configuration option for protocols http and https" properties: { certificates: { type: "array" description: "IDs of the Certificates to use for TLS/SSL termination by the Load Balancer; empty for TLS/SSL passthrough or if `protocol` is \"http\"" items: { type: "integer" } } cookie_lifetime: { type: "integer" description: "Lifetime of the cookie used for sticky sessions" } cookie_name: { type: "string" description: "Name of the cookie used for sticky sessions" } redirect_http: { type: "boolean" description: "Redirect HTTP requests to HTTPS. Only available if protocol is \"https\". Default `false`" } sticky_sessions: { type: "boolean" description: "Use sticky sessions. Only available if protocol is \"http\" or \"https\". Default `false`" } } } listen_port: { type: "integer" description: "Port the Load Balancer listens on" } protocol: { type: "string" description: "Protocol of the Load Balancer" enum: ["tcp", "http", "https"] } proxyprotocol: { type: "boolean" description: "Is Proxyprotocol enabled or not" } } } } targets: { type: "array" description: "List of targets that belong to this Load Balancer" items: { type: "object" required: ["type"] properties: { health_status: { type: "array" description: "List of health statuses of the services on this target" items: { type: "object" properties: { listen_port: { type: "integer" } status: { type: "string" enum: ["healthy", "unhealthy", "unknown"] } } } } ip: { type: "object" description: "IP targets where the traffic should be routed through. It is only possible to use the (Public or vSwitch) IPs of Hetzner Online Root Servers belonging to the project owner. IPs belonging to other users are blocked. Additionally IPs belonging to services provided by Hetzner Cloud (Servers, Load Balancers, ...) are blocked as well." required: ["ip"] properties: { ip: { type: "string" description: "IP of a server that belongs to the same customer (public IPv4/IPv6) or private IP in a Subnetwork type vswitch." } } } label_selector: { type: "object" description: "Label selector and a list of selected targets" required: ["selector"] properties: { selector: { type: "string" description: "Label selector" } } } server: { type: "object" description: "Server where the traffic should be routed through" required: ["id"] properties: { id: { type: "integer" description: "ID of the Server" } } } targets: { type: "array" description: "List of selected targets" items: { type: "object" properties: { health_status: { type: "array" items: { type: "object" additionalProperties: true } } server: { type: "object" required: ["id"] properties: { id: { type: "object" additionalProperties: true } } } type: { type: "string" } use_private_ip: { type: "boolean" } } } } type: { type: "string" description: "Type of the resource" enum: ["server", "label_selector", "ip"] } use_private_ip: { type: "boolean" description: "Use the private network IP instead of the public IP. Default value is false." } } } } } } } meta: { type: "object" required: ["pagination"] properties: { pagination: { type: "object" required: ["last_page", "next_page", "page", "per_page", "previous_page", "total_entries"] properties: { last_page: { type: "number" description: "ID of the last page available. Can be null if the current page is the last one." } next_page: { type: "number" description: "ID of the next page. Can be null if the current page is the last one." } page: { type: "number" description: "Current page number" } per_page: { type: "number" description: "Maximum number of items shown per page in the response" } previous_page: { type: "number" description: "ID of the previous page. Can be null if the current page is the first one." } total_entries: { type: "number" description: "The total number of entries that exist in the database for this query. Nullable if unknown." } } } } } } } }