### Server Metadata Summary Example Source: https://docs.hetzner.cloud/reference/cloud This is an example output of the server metadata, including availability zone, hostname, instance ID, public IPv4, and region. ```text availability-zone: hel1-dc2 hostname: my-server instance-id: 42 public-ipv4: 1.2.3.4 region: eu-central ``` -------------------------------- ### Example API Response for Servers Source: https://docs.hetzner.cloud/reference/cloud This is an example of a successful response when listing servers. It includes an empty 'servers' array and pagination metadata. ```json { "servers": [], "meta": { "pagination": { "page": 1, "per_page": 25, "previous_page": null, "next_page": null, "last_page": 1, "total_entries": 0 } } } ``` -------------------------------- ### Example Labels Object Source: https://docs.hetzner.cloud/reference/hetzner This JSON object demonstrates the structure for applying labels to resources. It includes examples of different key formats and value types, adhering to the specified constraints. ```json { "labels": { "environment": "development", "service": "backend", "example.com/my": "label", "just-a-key": "" } } ``` -------------------------------- ### Example Pagination Link Header Source: https://docs.hetzner.cloud/reference/hetzner This is an example of a 'Link' header used for pagination, providing URIs for previous, next, and last pages. Line breaks are for display only. ```http Link: ; rel="prev", ; rel="next", ; rel="last" ``` -------------------------------- ### Zone File Example Source: https://docs.hetzner.cloud/reference/cloud This example demonstrates the structure of a zone file that can be imported into Hetzner Cloud for DNS management. It includes directives like $ORIGIN and $TTL, along with NS and SOA records. ```dns $ORIGIN example.com. $TTL 3600 @ IN SOA hydrogen.ns.hetzner.com. dns.hetzner.com. 2024010100 86400 10800 3600000 3600 @ IN 10800 NS hydrogen.ns.hetzner.com. ; Some comment. @ IN 10800 NS oxygen.ns.hetzner.com. @ IN 10800 NS helium.ns.hetzner.de. ``` -------------------------------- ### Get All Pricing Information Source: https://docs.hetzner.cloud/reference/cloud Retrieves all available pricing information for Hetzner Cloud resources. Ensure the HCLOUD_TOKEN environment variable is set. ```Go package examples import ( "context" "os" "github.com/hetznercloud/hcloud-go/v2/hcloud" ) func main() { token := os.Getenv("HCLOUD_TOKEN") client := hcloud.NewClient(hcloud.WithToken(token)) ctx := context.TODO() pricing, _, err := client.Pricing.Get(ctx) } ``` -------------------------------- ### Example Hetzner API Response Source: https://docs.hetzner.cloud/reference/hetzner This is an example of a successful response from the Hetzner API when retrieving storage boxes. It includes a list of storage boxes (empty in this case) and pagination metadata. ```json { "storage_boxes": [], "meta": { "pagination": { "page": 1, "per_page": 25, "previous_page": null, "next_page": null, "last_page": 1, "total_entries": 0 } } } ``` -------------------------------- ### GET /v1/actions Source: https://docs.hetzner.cloud/changelog The functionality to list all actions via GET /v1/actions has been removed. The endpoint now only supports retrieving multiple actions by their IDs using GET /v1/actions?id=. ```APIDOC ## GET /v1/actions ### Description This endpoint is used to retrieve multiple actions by their IDs. The functionality to list all actions has been removed. ### Method GET ### Endpoint /v1/actions ### Query Parameters - **id** (string) - Required - Comma-separated list of action IDs to retrieve. ``` -------------------------------- ### Server Private Networks Example Source: https://docs.hetzner.cloud/reference/cloud This YAML output details the private network configurations, including IP addresses, MAC addresses, and network details. ```yaml - ip: 10.0.0.2 alias_ips: [10.0.0.3, 10.0.0.4] interface_num: 1 mac_address: 86:00:00:2a:7d:e0 network_id: 1234 network_name: nw-test1 network: 10.0.0.0/8 subnet: 10.0.0.0/24 gateway: 10.0.0.1 - ip: 192.168.0.2 alias_ips: [] interface_num: 2 mac_address: 86:00:00:2a:7d:e1 network_id: 4321 network_name: nw-test2 network: 192.168.0.0/16 subnet: 192.168.0.0/24 gateway: 192.168.0.1 ``` -------------------------------- ### GET /isos Source: https://docs.hetzner.cloud/changelog/feed.rss Retrieves a list of available ISOs. Supports filtering by architecture and wildcard inclusion. ```APIDOC ## GET /isos ### Description Retrieves a list of available ISOs. Supports filtering by architecture and wildcard inclusion. ### Method GET ### Endpoint /isos ### Query Parameters - **architecture** (string) - Optional - Filters ISOs by architecture (e.g., "x86", "arm"). - **include_architecture_wildcard** (boolean) - Optional - Whether to include ISOs that support all architectures. ``` -------------------------------- ### Get all prices Source: https://docs.hetzner.cloud/reference/cloud Returns prices for all resources available on the platform. VAT and currency of the Project owner are used for calculations. Both net and gross prices are included in the response. ```APIDOC ## GET /pricing ### Description Returns prices for all resources available on the platform. VAT and currency of the Project owner are used for calculations. Both net and gross prices are included in the response. ### Method GET ### Endpoint /pricing ### Response #### Success Response (200) - **pricing** (object) - Contains pricing details for various resources. - **currency** (string) - The currency used for pricing. - **vat_rate** (string) - The VAT rate applied. - **primary_ips** (array) - Pricing for primary IP addresses. - **floating_ips** (array) - Pricing for floating IP addresses. - **image** (object) - Pricing for images. - **volume** (object) - Pricing for volumes. - **server_backup** (object) - Pricing for server backups. - **server_types** (array) - Pricing for different server types. - **load_balancer_types** (array) - Pricing for different load balancer types. #### Response Example ```json { "pricing": { "currency": "EUR", "vat_rate": "19.00", "primary_ips": [ { "type": "ipv4", "prices": [ { "location": "fsn1", "price_hourly": { "net": "1.0000", "gross": "1.1900" }, "price_monthly": { "net": "1.0000", "gross": "1.1900" } } ] } ], "floating_ips": [ { "type": "ipv4", "prices": [ { "location": "fsn1", "price_monthly": { "net": "1.0000", "gross": "1.1900" } } ] } ], "image": { "price_per_gb_month": { "net": "1.0000", "gross": "1.1900" } }, "volume": { "price_per_gb_month": { "net": "1.0000", "gross": "1.1900" } }, "server_backup": { "percentage": "20.00" }, "server_types": [ { "id": 104, "name": "cpx22", "prices": [ { "location": "fsn1", "price_hourly": { "net": "1.0000", "gross": "1.1900" }, "price_monthly": { "net": "1.0000", "gross": "1.1900" }, "included_traffic": 654321, "price_per_tb_traffic": { "net": "1.0000", "gross": "1.1900" } } ] } ], "load_balancer_types": [ { "id": 1, "name": "lb11", "prices": [ { "location": "fsn1", "price_hourly": { "net": "1.0000", "gross": "1.1900" }, "price_monthly": { "net": "1.0000", "gross": "1.1900" }, "included_traffic": 654321, "price_per_tb_traffic": { "net": "1.0000", "gross": "1.1900" } } ] } ] } } ``` ``` -------------------------------- ### Make a Request to the Hetzner API Source: https://docs.hetzner.cloud/reference/hetzner Use this curl command to make your first request to the Hetzner API. Replace the placeholder token with your actual API token. This example retrieves a list of all Storage Boxes in your project. ```bash curl -H "Authorization: Bearer LRK9DAWQ1ZAEFSrCNEEzLCUwhYX1U3g7wMg4dTlkkDC96fyDuyJ39nVbVjCKSDfj" \ https://api.hetzner.com/v1/storage_boxes ``` -------------------------------- ### List Storage Boxes Source: https://docs.hetzner.cloud/reference/hetzner Retrieves a list of all Storage Boxes in your project. This is a basic example of an API request. ```APIDOC ## GET /v1/storage_boxes ### Description Retrieves a list of all Storage Boxes in your project. ### Method GET ### Endpoint https://api.hetzner.com/v1/storage_boxes ### Query Parameters #### Pagination - **page** (integer) - Optional - The page number to retrieve. - **page_size** (integer) - Optional - The number of items to return per page. #### Sorting - **sort** (string) - Optional - Field to sort by. Can be used multiple times for multi-field sorting. #### Filtering - **label_selector** (string) - Optional - Label selector to filter resources. ### Request Example ```bash curl -H "Authorization: Bearer YOUR_API_TOKEN" \ https://api.hetzner.com/v1/storage_boxes?page=1&page_size=10 ``` ### Response #### Success Response (200) - **storage_boxes** (array) - A list of storage box objects. - **meta** (object) - Contains pagination information. - **pagination** (object) - Pagination details. - **page** (integer) - Current page number. - **per_page** (integer) - Number of items per page. - **previous_page** (integer or null) - Previous page number. - **next_page** (integer or null) - Next page number. - **last_page** (integer) - Last page number. - **total_entries** (integer) - Total number of entries. #### Response Example ```json { "storage_boxes": [ { "id": 12345, "name": "my-storage-box", "folder_path": "/my-storage-box", "created": "2023-01-01T10:00:00Z", "status": "available", "files_count": 0, "size": 1000000000000, "used": 0, "product": "storagebox-s1000", "region": "nbg1", "backup_window": "22:00", "next_backup`: "2023-01-02T22:00:00Z" } ], "meta": { "pagination": { "page": 1, "per_page": 10, "previous_page": null, "next_page": null, "last_page": 1, "total_entries": 1 } } } ``` ``` -------------------------------- ### Get Servers List Source: https://docs.hetzner.cloud/reference/cloud This endpoint retrieves a list of all servers in your project. It supports pagination and filtering via query parameters. ```APIDOC ## GET /v1/servers ### Description Retrieves a list of all servers in the project. ### Method GET ### Endpoint /v1/servers ### Query Parameters #### Pagination - **page** (integer) - Optional - Specifies the page number to retrieve. - **page_size** (integer) - Optional - Specifies the number of items per page. Defaults to 25. #### Filtering - **label_selector** (string) - Optional - Comma-separated list of labels to filter servers by. ### Request Example ```bash curl -H "Authorization: Bearer YOUR_API_TOKEN" \ https://api.hetzner.cloud/v1/servers?page=1&page_size=10 ``` ### Response #### Success Response (200) - **servers** (array) - A list of server objects. - **meta** (object) - Contains pagination information. - **pagination** (object) - **page** (integer) - Current page number. - **per_page** (integer) - Number of items per page. - **previous_page** (integer or null) - Previous page number. - **next_page** (integer or null) - Next page number. - **last_page** (integer) - Last page number. - **total_entries** (integer) - Total number of entries. #### Response Example ```json { "servers": [ { "id": 12345, "name": "my-server-1", "status": "running", "created": "2023-01-01T10:00:00Z" } ], "meta": { "pagination": { "page": 1, "per_page": 25, "previous_page": null, "next_page": null, "last_page": 1, "total_entries": 1 } } } ``` ``` -------------------------------- ### Get multiple Actions Source: https://docs.hetzner.cloud/reference/cloud Retrieves a list of all actions performed on the Hetzner Cloud platform. This can be filtered by action ID. ```APIDOC ## GET /actions ### Description Retrieves a list of all actions performed on the Hetzner Cloud platform. This can be filtered by action ID. ### Method GET ### Endpoint /actions ### Query Parameters - **id** (integer) - Required - The ID of the action to retrieve. ``` -------------------------------- ### Get Multiple Actions by ID in Go Source: https://docs.hetzner.cloud/reference/cloud Use the `hcloud-go` client library to retrieve multiple actions by their IDs. Ensure the `HCLOUD_TOKEN` environment variable is set for authentication. ```go package examples import ( "context" "os" "github.com/hetznercloud/hcloud-go/v2/hcloud" ) func main() { token := os.Getenv("HCLOUD_TOKEN") client := hcloud.NewClient(hcloud.WithToken(token)) ctx := context.TODO() actions, err := client.Action.AllWithOpts(ctx, hcloud.ActionListOpts{ID: []int64{123, 456}}) } ``` -------------------------------- ### Example Pagination in JSON Response Source: https://docs.hetzner.cloud/reference/hetzner This JSON structure shows how pagination information is included in the 'meta' object for paginated API responses. ```json { "storage_boxes": [...], "meta": { "pagination": { "page": 2, "per_page": 25, "previous_page": 1, "next_page": 3, "last_page": 4, "total_entries": 100 } } } ``` -------------------------------- ### Resource Limit Exceeded Error Example Source: https://docs.hetzner.cloud/reference/hetzner This JSON structure is returned when an attempt is made to create a resource that would exceed the account's defined limits, such as the maximum number of projects allowed. ```json { "error": { "code": "resource_limit_exceeded", "message": "project limit exceeded", "details": { "limits": [ { "name": "project_limit" } ] } } } ``` -------------------------------- ### GET /v1/server_types Source: https://docs.hetzner.cloud/changelog/feed.rss The Server Types resource now includes a new string field `category`. This field categorizes server plans, aiding in distinguishing between different plan types. ```APIDOC ## GET /v1/server_types ### Description Retrieves a list of all available Server Types, including a new `category` field. ### Method GET ### Endpoint /v1/server_types ### Response #### Success Response (200) - **server_types** (array) - List of server types. - **id** (int) - Unique ID of the Server Type. - **name** (string) - Name of the Server Type. - **description** (string) - Description of the Server Type. - **cores** (int) - Number of cores. - **memory** (float) - Amount of memory in GB. - **disk** (int) - Amount of disk space in GB. - **storage_type** (string) - Type of storage. - **transfer** (float) - Included transfer in TB. - **price_hourly** (float) - Price per hour. - **price_monthly** (float) - Price per month. - **availability** (array) - Availability of the Server Type. - **location** (string) - Location name. - **available** (boolean) - Whether the Server Type is available in the location. - **deprecation** (object) - Deprecation information. (Deprecated) - **unavailable_after** (string) - Timestamp when the Server Type will be unavailable. - **category** (string) - Category of the Server Type (e.g., "shared", "dedicated", "gpu"). ``` -------------------------------- ### ISOs API Source: https://docs.hetzner.cloud/changelog Updates to the ISO handling in the Hetzner Cloud API. A new `architecture` field has been added to ISO responses, and new query parameters `architecture` and `include_architecture_wildcard` are available for the `GET /isos` endpoint. ```APIDOC ## ISOs API Documentation ### Description Information on ISO management, including the addition of an `architecture` field to responses and new filtering capabilities for the `GET /isos` endpoint. ### Endpoints #### GET /isos ##### Query Parameters - **architecture** (string) - Optional - Filters ISOs by architecture. - **include_architecture_wildcard** (boolean) - Optional - Allows wildcard matching for architecture. ``` -------------------------------- ### GET /v1/actions Source: https://docs.hetzner.cloud/changelog/feed.rss This endpoint has been updated. The functionality to list all actions has been removed and will return a 410 Gone status code. The functionality to get multiple actions by their IDs is still available. ```APIDOC ## GET /v1/actions ### Description Retrieves multiple actions by their IDs. The functionality to list all actions has been removed. ### Method GET ### Endpoint /v1/actions ### Query Parameters - **id** (integer) - Required - Comma-separated list of action IDs to retrieve. ### Response #### Success Response (200) - **actions** (array) - A list of action objects. - **id** (integer) - ID of the action. - **command** (string) - Command of the action. - **current_url** (string) - URL of the resource. - **finished** (string) - Timestamp of when the action finished. - **started** (string) - Timestamp of when the action started. - **status** (string) - Status of the action. - **resources** (array) - Resources related to the action. - **id** (integer) - ID of the resource. - **type** (string) - Type of the resource. - **error** (object) - Error details if the action failed. - **code** (string) - Error code. - **message** (string) - Error message. #### Error Response (410 Gone) Returned when attempting to list all actions without specifying IDs. ### Response Example ```json { "actions": [ { "id": 123, "command": "create_server", "current_url": "https://api.example.com/v1/servers/456", "finished": "2023-10-27T10:00:00Z", "started": "2023-10-27T09:55:00Z", "status": "success", "resources": [ { "id": 456, "type": "server" } ], "error": null } ] } ``` ``` -------------------------------- ### Example Hetzner API Error Response Source: https://docs.hetzner.cloud/reference/hetzner This is an example of an error response from the Hetzner API. It includes an error code, a human-readable message, and optional details about the error, such as invalid fields. ```json { "error": { "code": "invalid_input", "message": "invalid input in field 'broken_field': is too long", "details": { "fields": [ { "name": "broken_field", "messages": ["is too long"] } ] } } } ``` -------------------------------- ### Create a Storage Box Source: https://docs.hetzner.cloud/reference/hetzner Use this to create a new Storage Box. Ensure you have set the HCLOUD_TOKEN environment variable. The creation process is asynchronous and can be waited upon. ```Go package examples import ( "context" "os" "github.com/hetznercloud/hcloud-go/v2/hcloud" ) func main() { token := os.Getenv("HCLOUD_TOKEN") client := hcloud.NewClient(hcloud.WithToken(token)) ctx := context.TODO() result, _, err := client.StorageBox.Create(ctx, hcloud.StorageBoxCreateOpts{ Name: "string", Location: &hcloud.Location{Name: "fsn1"}, StorageBoxType: &hcloud.StorageBoxType{ Name: "bx11", }, Labels: map[string]string{ "environment": "prod", "example.com/my": "label", "just-a-key": "", }, Password: "my-password", AccessSettings: &hcloud.StorageBoxCreateOptsAccessSettings{ ReachableExternally: hcloud.Ptr(false), SambaEnabled: hcloud.Ptr(false), SSHEnabled: hcloud.Ptr(false), WebDAVEnabled: hcloud.Ptr(false), ZFSEnabled: hcloud.Ptr(false), }, SSHKeys: []*hcloud.SSHKey{ {PublicKey: "ssh-rsa AAAjjk76kgf...Xt"}, }, }) err = client.Action.WaitFor(ctx, result.Action) storageBox := result.StorageBox } ``` -------------------------------- ### DNS API Beta Launch Source: https://docs.hetzner.cloud/changelog Introduction of the new DNS API in beta. ```APIDOC ### DNS API Beta A new DNS API is now available in beta. The beta period is expected to end on November 10, 2025. Refer to the DNS beta FAQ for more details. ``` -------------------------------- ### Firewall Label Selectors Source: https://docs.hetzner.cloud/changelog From December 1, 2025, the GET /v1/firewalls and GET /v1/firewalls/$ID endpoints will return all Servers matching a Firewall label selector, reverting to previous behavior. ```APIDOC ## GET /v1/firewalls ### Description Retrieves a list of all firewalls. From December 1, 2025, this endpoint will display all Servers matching a Firewall label selector. ### Method GET ### Endpoint /v1/firewalls ## GET /v1/firewalls/$ID ### Description Retrieves a specific firewall by its ID. From December 1, 2025, this endpoint will display all Servers matching a Firewall label selector. ### Method GET ### Endpoint /v1/firewalls/$ID ``` -------------------------------- ### GET /images Source: https://docs.hetzner.cloud/changelog/feed.rss Retrieves a list of available images. Supports filtering by architecture. ```APIDOC ## GET /images ### Description Retrieves a list of available images. Supports filtering by architecture. ### Method GET ### Endpoint /images ### Query Parameters - **architecture** (string) - Optional - Filters images by architecture (e.g., "x86", "arm"). ``` -------------------------------- ### Fetch All Server Metadata Source: https://docs.hetzner.cloud/reference/cloud Use this curl command to retrieve a summary of all available metadata for the server. ```bash $ curl http://169.254.169.254/hetzner/v1/metadata ``` -------------------------------- ### Get a Specific Action Source: https://docs.hetzner.cloud/reference/cloud Retrieves a single Action object by its unique ID. ```APIDOC ### Get an Action Returns a specific Action object. Path Parameters * idCopy link to id Type: integerFormat: int64 min: 1 max: 9007199254740991 required Example 42 ID of the Action. Responses * 200 Request succeeded. application/json * 4xx Request failed with a user error. application/json * 5xx Request failed with a server error. application/json Request Example for get/actions/_{id}_ ```go package examples import ( "context" "os" "github.com/hetznercloud/hcloud-go/v2/hcloud" ) func main() { token := os.Getenv("HCLOUD_TOKEN") client := hcloud.NewClient(hcloud.WithToken(token)) ctx := context.TODO() action, _, err := client.Action.GetByID(ctx, 123) } ``` Response Example (200 OK): ```json { "action": { "id": 42, "command": "start_resource", "status": "running", "started": "2016-01-30T23:55:00Z", "finished": "2016-01-30T23:55:00Z", "progress": 100, "resources": [ { "id": 42, "type": "server" } ], "error": { "code": "action_failed", "message": "Action failed" } } } ``` ``` -------------------------------- ### Get Storage Box Source: https://docs.hetzner.cloud/reference/hetzner Retrieves details of a specific Storage Box by its ID. ```APIDOC ## GET /storage_boxes/{id} ### Description Returns a specific Storage Box. ### Method GET ### Endpoint /storage_boxes/{id} ### Parameters #### Path Parameters - **id** (integer) - Required - ID of the Storage Box. ### Response #### Success Response (200) - **storage_box** (object) - Contains details of the Storage Box. ### Response Example ```json { "storage_box": { "id": 42, "name": "string", "storage_box_type": { "id": 42, "name": "bx11", "description": "BX11", "snapshot_limit": 10, "automatic_snapshot_limit": 10, "subaccounts_limit": 200, "size": 1073741824, "prices": [ { "location": "fsn1", "price_hourly": { "net": "1.0000", "gross": "1.1900" }, "price_monthly": { "net": "1.0000", "gross": "1.1900" }, "setup_fee": { "net": "1.0000", "gross": "1.1900" } } ], "deprecation": { "unavailable_after": "2023-09-01T00:00:00Z", "announced": "2023-06-01T00:00:00Z" } }, "location": { "id": 42, "name": "fsn1", "description": "Falkenstein DC Park 1", "country": "DE", "city": "Falkenstein", "latitude": 50.47612, "longitude": 12.370071, "network_zone": "eu-central" }, "access_settings": { "reachable_externally": true, "samba_enabled": true, "ssh_enabled": true, "webdav_enabled": true, "zfs_enabled": true }, "snapshot_plan": { "max_snapshots": 10, "minute": 30, "hour": 3, "day_of_week": 7, "day_of_month": null }, "protection": { "delete": false }, "labels": { "environment": "prod", "example.com/my": "label", "just-a-key": "" }, "status": "active", "username": "u12345", "server": "u1337.your-storagebox.de", "system": "FSN1-BX355", "stats": { "size": 1, "size_data": 1, "size_snapshots": 1 }, "created": "2016-01-30T23:55:00Z" } } ``` ``` -------------------------------- ### List Storage Boxes in Go Source: https://docs.hetzner.cloud/reference/hetzner Fetches a paginated list of all Storage Boxes associated with the account. Ensure the HCLOUD_TOKEN environment variable is set. ```go package examples import ( "context" "os" "github.com/hetznercloud/hcloud-go/v2/hcloud" ) func main() { token := os.Getenv("HCLOUD_TOKEN") client := hcloud.NewClient(hcloud.WithToken(token)) ctx := context.TODO() storageBoxes, err := client.StorageBox.All(ctx) } ``` -------------------------------- ### Floating IPs API Source: https://docs.hetzner.cloud/reference/cloud Operations for managing Floating IPs for high availability setups. ```APIDOC ## Floating IPs API ### Description Manages Floating IPs, which can be assigned to servers to create highly available setups. Floating IPs can be reassigned or unassigned at any time and can be used globally. ### Endpoints * **GET /floating_ips** * Description: Retrieves a list of all Floating IPs. * **POST /floating_ips** * Description: Creates a new Floating IP. * **GET /floating_ips/{id}** * Description: Retrieves a specific Floating IP by its ID. * **PUT /floating_ips/{id}** * Description: Updates a specific Floating IP by its ID. * **DELETE /floating_ips/{id}** * Description: Deletes a specific Floating IP by its ID. ``` -------------------------------- ### List All Servers using curl Source: https://docs.hetzner.cloud/reference/cloud Use this command to retrieve a list of all servers in your project. Ensure you replace the placeholder token with your actual API token. ```bash curl -H "Authorization: Bearer LRK9DAWQ1ZAEFSrCNEEzLCUwhYX1U3g7wMg4dTlkkDC96fyDuyJ39nVbVjCKSDfj" \ https://api.hetzner.cloud/v1/servers ``` -------------------------------- ### Storage Box Creation and Listing Enhancements Source: https://docs.hetzner.cloud/changelog Endpoints for creating and listing Storage Boxes, Subaccounts, and Snapshots have been enhanced with return IDs and sort/filter parameters. ```APIDOC ## Create a Storage Box / Subaccount / Snapshot ### Description Creates a new Storage Box, Subaccount, or Snapshot. The response now includes the ID of the created resource. ### Method POST ### Endpoint (Endpoint for creating Storage Box / Subaccount / Snapshot) ### Response #### Success Response (200 or 201) - **id** (integer) - The ID of the created resource. ## List Storage Boxes / Subaccounts / Snapshots ### Description Lists Storage Boxes, Subaccounts, or Snapshots. Supports the `sort` query parameter for ordering results and the `username` query parameter for filtering subaccounts. ### Method GET ### Endpoint (Endpoint for listing Storage Boxes / Subaccounts / Snapshots) ### Parameters #### Query Parameters - **sort** (string) - Optional - Parameter to sort the results (e.g., `name:asc`). - **username** (string) - Optional - Filters subaccounts by username. ``` -------------------------------- ### New Apps Available Source: https://docs.hetzner.cloud/changelog Lists new applications that are now available for deployment on Hetzner Cloud servers, including Owncast, PhotoPrism®, RustDesk, Go, Ruby, Prometheus Grafana, and Collab Tools. ```APIDOC ## New Apps Available ### Description Several new applications have been added to the Hetzner Cloud App catalog, allowing for easier deployment on your servers. ### Available Apps - **AlmaLinux 8** (`alma-8`) - **AlmaLinux 9** (`alma-9`) - **Owncast** (`owncast`) - **PhotoPrism®** (`photoprism`) - **RustDesk** (`rustdesk`) - **Go** (`go`) - **Ruby** (`ruby`) - **Prometheus Grafana** (`prometheus-grafana`) - **Collaboration Tools** (`collab-tools`) ``` -------------------------------- ### New Apps Available Source: https://docs.hetzner.cloud/changelog Information about newly added applications for servers. ```APIDOC ## New Apps ### New App: Coolify.io - **App Name**: `coolify` - **App IDs**: `197238872` (x86), `197238880` (arm) - **Availability**: Available for your servers. ``` -------------------------------- ### Create Storage Box Source: https://docs.hetzner.cloud/reference/hetzner Creates a new Storage Box with specified configurations. ```APIDOC ## POST /storage/boxes ### Description Creates a Storage Box. ### Method POST ### Endpoint /storage/boxes ### Parameters #### Request Body - **location** (string) - Required - ID or Name of Location. - **name** (string) - Required - Name of the Storage Box. - **password** (string) - Required - Password of the Storage Box. For more details, see the Storage Boxes password policy. - **storage_box_type** (string) - Required - ID or Name of the Storage Box Type. - **access_settings** (object) - Optional - Access settings of the Storage Box. - **labels** (object) - Optional - User-defined labels (`key/value` pairs) for the Resource. - **ssh_keys** (array of strings) - Optional - SSH public keys in OpenSSH format to inject into the Storage Box. ### Request Example ```json { "location": "fsn1", "name": "my-storage-box", "password": "my-secret-password", "storage_box_type": "bx20", "access_settings": { "labels": { "environment": "prod", "example.com/my": "label", "just-a-key": "" }, "ssh_keys": [ "ssh-rsa AAAjjk76kgf...Xt" ] } } ``` ### Response #### Success Response (201) - **storage_box** (object) - Details of the created Storage Box. - **action** (object) - Details of the action performed. #### Response Example ```json { "storage_box": { "id": 42, "status": "initializing", "name": "my-resource", "username": "u45321", "storage_box_type": { "id": 1, "name": "bx20", "description": "BX20", "snapshot_limit": 10, "automatic_snapshot_limit": 10, "subaccounts_limit": 100, "size": 1073741824, "prices": [ { "location": "fsn1", "price_hourly": { "gross": "0.0061", "net": "0.0051" }, "price_monthly": { "gross": "3.8080", "net": "3.2000" }, "setup_fee": { "gross": "0.0000", "net": "0.0000" } } ], "deprecation": null }, "location": { "id": 1, "country": "DE", "city": "Falkenstein", "name": "fsn1", "network_zone": "eu-central", "latitude": 50.476119, "longitude": 12.370071, "description": "Falkenstein DC Park 1" }, "access_settings": { "reachable_externally": false, "samba_enabled": false, "ssh_enabled": false, "webdav_enabled": false, "zfs_enabled": false }, "server": null, "system": null, "stats": { "size": 0, "size_data": 0, "size_snapshots": 0 }, "labels": { "environment": "prod", "example.com/my": "label", "just-a-key": "" }, "protection": { "delete": false }, "snapshot_plan": null, "created": "2016-01-30T23:50:00Z" }, "action": { "id": 13, "command": "create", "status": "running", "progress": 0, "started": "2016-01-30T23:50:00Z", "finished": null, "resources": [ { "id": 42, "type": "storage_box" } ], "error": null } } ``` ``` -------------------------------- ### Get Storage Box by ID in Go Source: https://docs.hetzner.cloud/reference/hetzner Retrieves a specific Storage Box using its ID. Ensure the HCLOUD_TOKEN environment variable is set. ```go package examples import ( "context" "os" "github.com/hetznercloud/hcloud-go/v2/hcloud" ) func main() { token := os.Getenv("HCLOUD_TOKEN") client := hcloud.NewClient(hcloud.WithToken(token)) ctx := context.TODO() storageBox, _, err := client.StorageBox.GetByID(ctx, 123) } ``` -------------------------------- ### Storage Box Initialization and Creation Updates Source: https://docs.hetzner.cloud/changelog Changes related to Storage Box stats during initialization and specifying location ID during creation. ```APIDOC ## GET /storage_boxes/{id} ### Description When a Storage Box is in the `initializing` status, the `stats` property will now return an object with all stats set to `0`, instead of `null`. ### Method GET ### Endpoint /storage_boxes/{id} ### Response #### Success Response (200) - **storage_box.stats** (object) - Statistics of the Storage Box. Example: `{"size": 0, "size_data": 0, "size_snapshots": 0}` when initializing. ## POST /storage_boxes ### Description Create a Storage Box endpoint now accepts the ID of a location in the `location` field, in addition to the name. ### Method POST ### Endpoint /storage_boxes ### Request Body - **location** (string or integer) - Optional - Name or ID of the location where the Storage Box should be created. ``` -------------------------------- ### New Server Images Available Source: https://docs.hetzner.cloud/changelog Details on newly available server images. ```APIDOC ## New Server Images ### IPFire 2.29 ISO now available - **Image Name**: `IPFire 2.29-core192` - **Image IDs**: `119405` (x86), `119404` (arm) - **Availability**: Available for all Cloud Servers as ISO. ### CentOS Stream 10 now available - **Image Name**: `centos-stream-10` - **Image IDs**: `210163277` (x86), `210163284` (arm) - **Availability**: Available for all Cloud Servers as a Rapid Deploy Image. ### openSUSE 15.6 now available - **Image Name**: `opensuse-15` - **Availability**: Available as a Rapid Deploy Image for all Cloud Servers. ``` -------------------------------- ### Query Parameters for Pagination Source: https://docs.hetzner.cloud/reference/cloud Demonstrates how to use query parameters to paginate results. 'page' specifies the page number and 'page_size' controls the number of items per page. ```url https://api.hetzner.cloud/v1/certificates?page=1&page_size=12 ``` -------------------------------- ### DNS API General Availability Source: https://docs.hetzner.cloud/changelog/feed.rss DNS is now generally available in Hetzner Console and via the DNS API. Creating new zones via dns.hetzner.com is no longer possible. ```bash POST /v1/zones ``` -------------------------------- ### Get Multiple Actions Source: https://docs.hetzner.cloud/reference/cloud Retrieves a list of Action objects, optionally filtered by their IDs. This endpoint previously supported listing all actions but this functionality has been deprecated and removed. ```APIDOC ## Actions Actions represent asynchronous tasks within the API, targeting one or more resources. ### Get multiple Actions Returns multiple Action objects specified by the `id` parameter. **Note** : This endpoint previously allowed listing all actions in the project. This functionality was deprecated in July 2023 and removed on 30 January 2025. Query Parameters * idCopy link to id Type: array integer[] required Filter the actions by ID. May be used multiple times. The response will only contain actions matching the specified IDs. Responses * 200 Request succeeded. application/json * 4xx Request failed with a user error. application/json * 5xx Request failed with a server error. application/json Request Example for get/actions ```go package examples import ( "context" "os" "github.com/hetznercloud/hcloud-go/v2/hcloud" ) func main() { token := os.Getenv("HCLOUD_TOKEN") client := hcloud.NewClient(hcloud.WithToken(token)) ctx := context.TODO() actions, err := client.Action.AllWithOpts(ctx, hcloud.ActionListOpts{ID: []int64{123, 456}}) } ``` Response Example (200 OK): ```json { "actions": [ { "id": 42, "command": "start_resource", "status": "running", "started": "2016-01-30T23:55:00Z", "finished": "2016-01-30T23:55:00Z", "progress": 100, "resources": [ { "id": 42, "type": "server" } ], "error": { "code": "action_failed", "message": "Action failed" } } ] } ``` ``` -------------------------------- ### Sorting by Status Source: https://docs.hetzner.cloud/reference/hetzner Demonstrates how to sort resources by the 'status' field in ascending order. This is the default sort direction. ```http https://api.hetzner.com/v1/storage_boxes?sort=status ``` -------------------------------- ### Get a Specific Action by ID in Go Source: https://docs.hetzner.cloud/reference/cloud Retrieve a single action by its ID using the `hcloud-go` client library. Authentication is handled via the `HCLOUD_TOKEN` environment variable. ```go package examples import ( "context" "os" "github.com/hetznercloud/hcloud-go/v2/hcloud" ) func main() { token := os.Getenv("HCLOUD_TOKEN") client := hcloud.NewClient(hcloud.WithToken(token)) ctx := context.TODO() action, _, err := client.Action.GetByID(ctx, 123) } ``` -------------------------------- ### New ISO Availability Source: https://docs.hetzner.cloud/changelog Announcement of the availability of Talos Linux v1.11.2 ISO. ```APIDOC ### Talos Linux v1.11.2 ISO The `Talos Linux 1.11.2` ISO is now available for all Cloud Servers. - **Standard ISO IDs**: `122630` (x86) & `122629` (arm) - **Customized Models**: Available with Hetzner metadata support and qemu-guest-agent, identified by schematic ID `ce4c980550dd2ab1b17bbf2b08801c7eb59418eafe8f279833297925d67c7515`. ```