import * as API from "@distilled.cloud/core/api"; import { type HetznerOpError, type HetznerOpContext } from "../protocol.ts"; export type { HetznerOpError, HetznerOpContext }; export interface AssignFloatingIpRequest { /** ID of the Floating IP. */ id: number; /** [Server](#tag/servers) the [Floating IP](#tag/floating-ips) is assigned to. `null` if not assigned. */ server: number | null; } /** Status of the Action. */ export type AssignFloatingIpResponseActionStatus = "running" | "success" | "error"; export interface AssignFloatingIpResponseActionResourcesItem { /** ID of the Resource. */ id: number; /** Type of the Resource. */ type: string; } /** Resources the Action relates to. */ export type AssignFloatingIpResponseActionResourcesList = Array; /** Error message for the Action if an error occurred, otherwise null. */ export interface AssignFloatingIpResponseActionError { /** Fixed error code for machines. */ code: string; /** Error message for humans. */ message: string; } export interface AssignFloatingIpResponseAction { /** ID of the [Action](#description/actions). */ id: number; /** Command executed in the Action. */ command: string; /** Status of the Action. */ status: AssignFloatingIpResponseActionStatus; /** Point in time when the Action was started (in [RFC3339](https://datatracker.ietf.org/doc/html/rfc3339#section-5.6) format). */ started: string; /** Point in time when the Action was finished (in [RFC3339](https://datatracker.ietf.org/doc/html/rfc3339#section-5.6) format). Only set if the Action is finished otherwise null. */ finished: string | null; /** Progress of the Action in percent. */ progress: number; /** Resources the Action relates to. */ resources: AssignFloatingIpResponseActionResourcesList; /** Error message for the Action if an error occurred, otherwise null. */ error: AssignFloatingIpResponseActionError | null; } export interface AssignFloatingIpResponse { action: AssignFloatingIpResponseAction; } export interface ChangeFloatingIpDnsPtrRequest { /** ID of the Floating IP. */ id: number; /** Single IPv4 or IPv6 address to create pointer for. */ ip: string; /** Domain Name to point to. PTR record content used for reverse DNS. Set to null to reset (IPv4) to the default value or remove (IPv6) the record. */ dns_ptr: string | null; } /** Status of the Action. */ export type ChangeFloatingIpDnsPtrResponseActionStatus = "running" | "success" | "error"; export type ChangeFloatingIpDnsPtrResponseActionResourcesItem = AssignFloatingIpResponseActionResourcesItem; /** Resources the Action relates to. */ export type ChangeFloatingIpDnsPtrResponseActionResourcesList = Array; /** Error message for the Action if an error occurred, otherwise null. */ export type ChangeFloatingIpDnsPtrResponseActionError = AssignFloatingIpResponseActionError; export interface ChangeFloatingIpDnsPtrResponseAction { /** ID of the [Action](#description/actions). */ id: number; /** Command executed in the Action. */ command: string; /** Status of the Action. */ status: ChangeFloatingIpDnsPtrResponseActionStatus; /** Point in time when the Action was started (in [RFC3339](https://datatracker.ietf.org/doc/html/rfc3339#section-5.6) format). */ started: string; /** Point in time when the Action was finished (in [RFC3339](https://datatracker.ietf.org/doc/html/rfc3339#section-5.6) format). Only set if the Action is finished otherwise null. */ finished: string | null; /** Progress of the Action in percent. */ progress: number; /** Resources the Action relates to. */ resources: ChangeFloatingIpDnsPtrResponseActionResourcesList; /** Error message for the Action if an error occurred, otherwise null. */ error: AssignFloatingIpResponseActionError | null; } export interface ChangeFloatingIpDnsPtrResponse { action: ChangeFloatingIpDnsPtrResponseAction; } export interface ChangeFloatingIpProtectionRequest { /** ID of the Floating IP. */ id: number; /** Prevent the Resource from being deleted. */ delete: boolean; } /** Status of the Action. */ export type ChangeFloatingIpProtectionResponseActionStatus = "running" | "success" | "error"; export type ChangeFloatingIpProtectionResponseActionResourcesItem = AssignFloatingIpResponseActionResourcesItem; /** Resources the Action relates to. */ export type ChangeFloatingIpProtectionResponseActionResourcesList = Array; /** Error message for the Action if an error occurred, otherwise null. */ export type ChangeFloatingIpProtectionResponseActionError = AssignFloatingIpResponseActionError; export interface ChangeFloatingIpProtectionResponseAction { /** ID of the [Action](#description/actions). */ id: number; /** Command executed in the Action. */ command: string; /** Status of the Action. */ status: ChangeFloatingIpProtectionResponseActionStatus; /** Point in time when the Action was started (in [RFC3339](https://datatracker.ietf.org/doc/html/rfc3339#section-5.6) format). */ started: string; /** Point in time when the Action was finished (in [RFC3339](https://datatracker.ietf.org/doc/html/rfc3339#section-5.6) format). Only set if the Action is finished otherwise null. */ finished: string | null; /** Progress of the Action in percent. */ progress: number; /** Resources the Action relates to. */ resources: ChangeFloatingIpProtectionResponseActionResourcesList; /** Error message for the Action if an error occurred, otherwise null. */ error: AssignFloatingIpResponseActionError | null; } export interface ChangeFloatingIpProtectionResponse { action: ChangeFloatingIpProtectionResponseAction; } export interface GetFloatingIpsActionRequest { /** ID of the Action. */ id: number; } /** Status of the Action. */ export type GetFloatingIpsActionResponseActionStatus = "running" | "success" | "error"; export type GetFloatingIpsActionResponseActionResourcesItem = AssignFloatingIpResponseActionResourcesItem; /** Resources the Action relates to. */ export type GetFloatingIpsActionResponseActionResourcesList = Array; /** Error message for the Action if an error occurred, otherwise null. */ export type GetFloatingIpsActionResponseActionError = AssignFloatingIpResponseActionError; export interface GetFloatingIpsActionResponseAction { /** ID of the [Action](#description/actions). */ id: number; /** Command executed in the Action. */ command: string; /** Status of the Action. */ status: GetFloatingIpsActionResponseActionStatus; /** Point in time when the Action was started (in [RFC3339](https://datatracker.ietf.org/doc/html/rfc3339#section-5.6) format). */ started: string; /** Point in time when the Action was finished (in [RFC3339](https://datatracker.ietf.org/doc/html/rfc3339#section-5.6) format). Only set if the Action is finished otherwise null. */ finished: string | null; /** Progress of the Action in percent. */ progress: number; /** Resources the Action relates to. */ resources: GetFloatingIpsActionResponseActionResourcesList; /** Error message for the Action if an error occurred, otherwise null. */ error: AssignFloatingIpResponseActionError | null; } export interface GetFloatingIpsActionResponse { action: GetFloatingIpsActionResponseAction; } export type ListFloatingIpActionsRequestSortItem = "id" | "id:asc" | "id:desc" | "command" | "command:asc" | "command:desc" | "status" | "status:asc" | "status:desc" | "started" | "started:asc" | "started:desc" | "finished" | "finished:asc" | "finished:desc"; export type ListFloatingIpActionsRequestSortList = Array; /** Status of the Action. */ export type ListFloatingIpActionsRequestStatusItem = "running" | "success" | "error"; export type ListFloatingIpActionsRequestStatusList = Array; export interface ListFloatingIpActionsRequest { /** ID of the Floating IP. */ id: number; /** Sort actions by field and direction. May be used multiple times. For more information, see "[Sorting](#description/sorting)". */ sort?: ListFloatingIpActionsRequestSortList; /** Filter the actions by status. May be used multiple times. The response will only contain actions matching the specified statuses. */ status?: ListFloatingIpActionsRequestStatusList; /** Page number to return. For more information, see "[Pagination](#description/pagination)". */ page?: number; /** Maximum number of entries returned per page. For more information, see "[Pagination](#description/pagination)". */ per_page?: number; } /** Status of the Action. */ export type ListFloatingIpActionsResponseActionsItemStatus = "running" | "success" | "error"; export type ListFloatingIpActionsResponseActionsItemResourcesItem = AssignFloatingIpResponseActionResourcesItem; /** Resources the Action relates to. */ export type ListFloatingIpActionsResponseActionsItemResourcesList = Array; /** Error message for the Action if an error occurred, otherwise null. */ export type ListFloatingIpActionsResponseActionsItemError = AssignFloatingIpResponseActionError; export interface ListFloatingIpActionsResponseActionsItem { /** ID of the [Action](#description/actions). */ id: number; /** Command executed in the Action. */ command: string; /** Status of the Action. */ status: ListFloatingIpActionsResponseActionsItemStatus; /** Point in time when the Action was started (in [RFC3339](https://datatracker.ietf.org/doc/html/rfc3339#section-5.6) format). */ started: string; /** Point in time when the Action was finished (in [RFC3339](https://datatracker.ietf.org/doc/html/rfc3339#section-5.6) format). Only set if the Action is finished otherwise null. */ finished: string | null; /** Progress of the Action in percent. */ progress: number; /** Resources the Action relates to. */ resources: ListFloatingIpActionsResponseActionsItemResourcesList; /** Error message for the Action if an error occurred, otherwise null. */ error: AssignFloatingIpResponseActionError | null; } export type ListFloatingIpActionsResponseActionsList = Array; /** See "[Pagination](#description/pagination)" for more information. */ export interface ListFloatingIpActionsResponseMetaPagination { /** Current page number. */ page: number; /** Maximum number of entries returned per page. */ per_page: number; /** Page number of the previous page. Can be null if the current page is the first one. */ previous_page: number | null; /** Page number of the next page. Can be null if the current page is the last one. */ next_page: number | null; /** Page number of the last page available. Can be null if the current page is the last one. */ last_page: number | null; /** Total number of entries that exist for this query. Can be null if unknown. */ total_entries: number | null; } export interface ListFloatingIpActionsResponseMeta { /** See "[Pagination](#description/pagination)" for more information. */ pagination: ListFloatingIpActionsResponseMetaPagination; } export interface ListFloatingIpActionsResponse { actions: ListFloatingIpActionsResponseActionsList; meta: ListFloatingIpActionsResponseMeta; } export type ListFloatingIpsActionsRequestIdList = Array; export type ListFloatingIpsActionsRequestSortItem = "id" | "id:asc" | "id:desc" | "command" | "command:asc" | "command:desc" | "status" | "status:asc" | "status:desc" | "started" | "started:asc" | "started:desc" | "finished" | "finished:asc" | "finished:desc"; export type ListFloatingIpsActionsRequestSortList = Array; /** Status of the Action. */ export type ListFloatingIpsActionsRequestStatusItem = "running" | "success" | "error"; export type ListFloatingIpsActionsRequestStatusList = Array; export interface ListFloatingIpsActionsRequest { /** Filter the actions by ID. May be used multiple times. The response will only contain actions matching the specified IDs. */ id?: ListFloatingIpsActionsRequestIdList; /** Sort actions by field and direction. May be used multiple times. For more information, see "[Sorting](#description/sorting)". */ sort?: ListFloatingIpsActionsRequestSortList; /** Filter the actions by status. May be used multiple times. The response will only contain actions matching the specified statuses. */ status?: ListFloatingIpsActionsRequestStatusList; /** Page number to return. For more information, see "[Pagination](#description/pagination)". */ page?: number; /** Maximum number of entries returned per page. For more information, see "[Pagination](#description/pagination)". */ per_page?: number; } /** Status of the Action. */ export type ListFloatingIpsActionsResponseActionsItemStatus = "running" | "success" | "error"; export type ListFloatingIpsActionsResponseActionsItemResourcesItem = AssignFloatingIpResponseActionResourcesItem; /** Resources the Action relates to. */ export type ListFloatingIpsActionsResponseActionsItemResourcesList = Array; /** Error message for the Action if an error occurred, otherwise null. */ export type ListFloatingIpsActionsResponseActionsItemError = AssignFloatingIpResponseActionError; export interface ListFloatingIpsActionsResponseActionsItem { /** ID of the [Action](#description/actions). */ id: number; /** Command executed in the Action. */ command: string; /** Status of the Action. */ status: ListFloatingIpsActionsResponseActionsItemStatus; /** Point in time when the Action was started (in [RFC3339](https://datatracker.ietf.org/doc/html/rfc3339#section-5.6) format). */ started: string; /** Point in time when the Action was finished (in [RFC3339](https://datatracker.ietf.org/doc/html/rfc3339#section-5.6) format). Only set if the Action is finished otherwise null. */ finished: string | null; /** Progress of the Action in percent. */ progress: number; /** Resources the Action relates to. */ resources: ListFloatingIpsActionsResponseActionsItemResourcesList; /** Error message for the Action if an error occurred, otherwise null. */ error: AssignFloatingIpResponseActionError | null; } export type ListFloatingIpsActionsResponseActionsList = Array; /** See "[Pagination](#description/pagination)" for more information. */ export type ListFloatingIpsActionsResponseMetaPagination = ListFloatingIpActionsResponseMetaPagination; export type ListFloatingIpsActionsResponseMeta = ListFloatingIpActionsResponseMeta; export interface ListFloatingIpsActionsResponse { actions: ListFloatingIpsActionsResponseActionsList; meta: ListFloatingIpActionsResponseMeta; } export interface UnassignFloatingIpRequest { /** ID of the Floating IP. */ id: number; } /** Status of the Action. */ export type UnassignFloatingIpResponseActionStatus = "running" | "success" | "error"; export type UnassignFloatingIpResponseActionResourcesItem = AssignFloatingIpResponseActionResourcesItem; /** Resources the Action relates to. */ export type UnassignFloatingIpResponseActionResourcesList = Array; /** Error message for the Action if an error occurred, otherwise null. */ export type UnassignFloatingIpResponseActionError = AssignFloatingIpResponseActionError; export interface UnassignFloatingIpResponseAction { /** ID of the [Action](#description/actions). */ id: number; /** Command executed in the Action. */ command: string; /** Status of the Action. */ status: UnassignFloatingIpResponseActionStatus; /** Point in time when the Action was started (in [RFC3339](https://datatracker.ietf.org/doc/html/rfc3339#section-5.6) format). */ started: string; /** Point in time when the Action was finished (in [RFC3339](https://datatracker.ietf.org/doc/html/rfc3339#section-5.6) format). Only set if the Action is finished otherwise null. */ finished: string | null; /** Progress of the Action in percent. */ progress: number; /** Resources the Action relates to. */ resources: UnassignFloatingIpResponseActionResourcesList; /** Error message for the Action if an error occurred, otherwise null. */ error: AssignFloatingIpResponseActionError | null; } export interface UnassignFloatingIpResponse { action: UnassignFloatingIpResponseAction; } export type AssignFloatingIpError = HetznerOpError; /** Assign a Floating IP to a Server Assigns a [Floating IP](#tag/floating-ips) to a [Server](#tag/servers). #### Operation specific errors */ export declare const assignFloatingIp: API.OperationMethod; export type ChangeFloatingIpDnsPtrError = HetznerOpError; /** Change reverse DNS records for a Floating IP Change the reverse DNS records for this [Floating IP](#tag/floating-ips). Allows to modify the PTR records set for the IP address. */ export declare const changeFloatingIpDnsPtr: API.OperationMethod; export type ChangeFloatingIpProtectionError = HetznerOpError; /** Change Floating IP Protection Changes the protection settings configured for the [Floating IP](#tag/floating-ips). */ export declare const changeFloatingIpProtection: API.OperationMethod; export type GetFloatingIpsActionError = HetznerOpError; /** Get an Action Returns a single [Action](#tag/actions). */ export declare const getFloatingIpsAction: API.OperationMethod; export type ListFloatingIpActionsError = HetznerOpError; /** List Actions for a Floating IP Lists [Actions](#tag/actions) for a [Floating IP](#tag/floating-ips). Use the provided URI parameters to modify the result. */ export declare const listFloatingIpActions: API.PaginatedOperationMethod; export type ListFloatingIpsActionsError = HetznerOpError; /** List Actions Lists multiple [Actions](#tag/actions). Use the provided URI parameters to modify the result. */ export declare const listFloatingIpsActions: API.PaginatedOperationMethod; export type UnassignFloatingIpError = HetznerOpError; /** Unassign a Floating IP Unassigns a [Floating IP](#tag/floating-ips). Results in the IP being unreachable. Can be assigned to another resource again. */ export declare const unassignFloatingIp: API.OperationMethod; //# sourceMappingURL=floating_ip_actions.d.ts.map