import * as API from "@distilled.cloud/core/api"; import { type HetznerOpError, type HetznerOpContext } from "../protocol.ts"; export type { HetznerOpError, HetznerOpContext }; /** [Transaction signature (TSIG)](https://en.wikipedia.org/wiki/TSIG) algorithm used to generate the TSIG key. */ export type ChangeZonePrimaryNameserversRequestPrimaryNameserversItemTsigAlgorithm = "hmac-md5" | "hmac-sha1" | "hmac-sha256"; /** Primary nameserver that returns [Zones](#tag/zones) via `AXFR`. Must allow queries from and may send `NOTIFY` queries to [Hetzner's secondary nameservers](https://docs.hetzner.com/dns-console/dns/general/authoritative-name-servers#secondary-dns-servers-old-name-servers-for-robot-customers). */ export interface ChangeZonePrimaryNameserversRequestPrimaryNameserversItem { /** Public IPv4 or IPv6 address of the primary nameserver. Must be unique across all primary nameservers of this zone. */ address: string; /** Port of the primary nameserver. */ port?: number; /** [Transaction signature (TSIG)](https://en.wikipedia.org/wiki/TSIG) key to use for the zone transfer. Must be base64 encoded. */ tsig_key?: string; /** [Transaction signature (TSIG)](https://en.wikipedia.org/wiki/TSIG) algorithm used to generate the TSIG key. */ tsig_algorithm?: ChangeZonePrimaryNameserversRequestPrimaryNameserversItemTsigAlgorithm | (string & {}); } /** Primary nameservers of the [Zone](#tag/zones). */ export type ChangeZonePrimaryNameserversRequestPrimaryNameserversList = Array; export interface ChangeZonePrimaryNameserversRequest { /** ID or Name of the Zone. */ id_or_name: string; /** Primary nameservers of the [Zone](#tag/zones). */ primary_nameservers: ChangeZonePrimaryNameserversRequestPrimaryNameserversList; } /** Status of the Action. */ export type ChangeZonePrimaryNameserversResponseActionStatus = "running" | "success" | "error"; export interface ChangeZonePrimaryNameserversResponseActionResourcesItem { /** ID of the Resource. */ id: number; /** Type of the Resource. */ type: string; } /** Resources the Action relates to. */ export type ChangeZonePrimaryNameserversResponseActionResourcesList = Array; /** Error message for the Action if an error occurred, otherwise null. */ export interface ChangeZonePrimaryNameserversResponseActionError { /** Fixed error code for machines. */ code: string; /** Error message for humans. */ message: string; } export interface ChangeZonePrimaryNameserversResponseAction { /** ID of the [Action](#description/actions). */ id: number; /** Command executed in the Action. */ command: string; /** Status of the Action. */ status: ChangeZonePrimaryNameserversResponseActionStatus; /** 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: ChangeZonePrimaryNameserversResponseActionResourcesList; /** Error message for the Action if an error occurred, otherwise null. */ error: ChangeZonePrimaryNameserversResponseActionError | null; } export interface ChangeZonePrimaryNameserversResponse { action: ChangeZonePrimaryNameserversResponseAction; } export interface ChangeZoneProtectionRequest { /** ID or Name of the Zone. */ id_or_name: string; /** Prevents the [Zone](#tag/zones) from being deleted. */ delete?: boolean; } /** Status of the Action. */ export type ChangeZoneProtectionResponseActionStatus = "running" | "success" | "error"; export type ChangeZoneProtectionResponseActionResourcesItem = ChangeZonePrimaryNameserversResponseActionResourcesItem; /** Resources the Action relates to. */ export type ChangeZoneProtectionResponseActionResourcesList = Array; /** Error message for the Action if an error occurred, otherwise null. */ export type ChangeZoneProtectionResponseActionError = ChangeZonePrimaryNameserversResponseActionError; export interface ChangeZoneProtectionResponseAction { /** ID of the [Action](#description/actions). */ id: number; /** Command executed in the Action. */ command: string; /** Status of the Action. */ status: ChangeZoneProtectionResponseActionStatus; /** 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: ChangeZoneProtectionResponseActionResourcesList; /** Error message for the Action if an error occurred, otherwise null. */ error: ChangeZonePrimaryNameserversResponseActionError | null; } export interface ChangeZoneProtectionResponse { action: ChangeZoneProtectionResponseAction; } export interface ChangeZoneTtlRequest { /** ID or Name of the Zone. */ id_or_name: string; /** Default Time To Live (TTL) of the [Zone](#tag/zones). Must be in between 60s and 2147483647s. This TTL is used for [RRSets](#tag/zone-rrsets) that do not explicitly define a TTL. */ ttl: number; } /** Status of the Action. */ export type ChangeZoneTtlResponseActionStatus = "running" | "success" | "error"; export type ChangeZoneTtlResponseActionResourcesItem = ChangeZonePrimaryNameserversResponseActionResourcesItem; /** Resources the Action relates to. */ export type ChangeZoneTtlResponseActionResourcesList = Array; /** Error message for the Action if an error occurred, otherwise null. */ export type ChangeZoneTtlResponseActionError = ChangeZonePrimaryNameserversResponseActionError; export interface ChangeZoneTtlResponseAction { /** ID of the [Action](#description/actions). */ id: number; /** Command executed in the Action. */ command: string; /** Status of the Action. */ status: ChangeZoneTtlResponseActionStatus; /** 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: ChangeZoneTtlResponseActionResourcesList; /** Error message for the Action if an error occurred, otherwise null. */ error: ChangeZonePrimaryNameserversResponseActionError | null; } export interface ChangeZoneTtlResponse { action: ChangeZoneTtlResponseAction; } export interface GetZonesActionRequest { /** ID of the Action. */ id: number; } /** Status of the Action. */ export type GetZonesActionResponseActionStatus = "running" | "success" | "error"; export type GetZonesActionResponseActionResourcesItem = ChangeZonePrimaryNameserversResponseActionResourcesItem; /** Resources the Action relates to. */ export type GetZonesActionResponseActionResourcesList = Array; /** Error message for the Action if an error occurred, otherwise null. */ export type GetZonesActionResponseActionError = ChangeZonePrimaryNameserversResponseActionError; export interface GetZonesActionResponseAction { /** ID of the [Action](#description/actions). */ id: number; /** Command executed in the Action. */ command: string; /** Status of the Action. */ status: GetZonesActionResponseActionStatus; /** 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: GetZonesActionResponseActionResourcesList; /** Error message for the Action if an error occurred, otherwise null. */ error: ChangeZonePrimaryNameserversResponseActionError | null; } export interface GetZonesActionResponse { action: GetZonesActionResponseAction; } export interface ImportZoneZonefileRequest { /** ID or Name of the Zone. */ id_or_name: string; /** Zone file to import. See [Zone file import](#tag/zones/zone-file-import) for more details. */ zonefile: string; } /** Status of the Action. */ export type ImportZoneZonefileResponseActionStatus = "running" | "success" | "error"; export type ImportZoneZonefileResponseActionResourcesItem = ChangeZonePrimaryNameserversResponseActionResourcesItem; /** Resources the Action relates to. */ export type ImportZoneZonefileResponseActionResourcesList = Array; /** Error message for the Action if an error occurred, otherwise null. */ export type ImportZoneZonefileResponseActionError = ChangeZonePrimaryNameserversResponseActionError; export interface ImportZoneZonefileResponseAction { /** ID of the [Action](#description/actions). */ id: number; /** Command executed in the Action. */ command: string; /** Status of the Action. */ status: ImportZoneZonefileResponseActionStatus; /** 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: ImportZoneZonefileResponseActionResourcesList; /** Error message for the Action if an error occurred, otherwise null. */ error: ChangeZonePrimaryNameserversResponseActionError | null; } export interface ImportZoneZonefileResponse { action: ImportZoneZonefileResponseAction; } export type ListZoneActionsRequestSortItem = "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 ListZoneActionsRequestSortList = Array; /** Status of the Action. */ export type ListZoneActionsRequestStatusItem = "running" | "success" | "error"; export type ListZoneActionsRequestStatusList = Array; export interface ListZoneActionsRequest { /** ID or Name of the Zone. */ id_or_name: string; /** Sort actions by field and direction. May be used multiple times. For more information, see "[Sorting](#description/sorting)". */ sort?: ListZoneActionsRequestSortList; /** Filter the actions by status. May be used multiple times. The response will only contain actions matching the specified statuses. */ status?: ListZoneActionsRequestStatusList; /** 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 ListZoneActionsResponseActionsItemStatus = "running" | "success" | "error"; export type ListZoneActionsResponseActionsItemResourcesItem = ChangeZonePrimaryNameserversResponseActionResourcesItem; /** Resources the Action relates to. */ export type ListZoneActionsResponseActionsItemResourcesList = Array; /** Error message for the Action if an error occurred, otherwise null. */ export type ListZoneActionsResponseActionsItemError = ChangeZonePrimaryNameserversResponseActionError; export interface ListZoneActionsResponseActionsItem { /** ID of the [Action](#description/actions). */ id: number; /** Command executed in the Action. */ command: string; /** Status of the Action. */ status: ListZoneActionsResponseActionsItemStatus; /** 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: ListZoneActionsResponseActionsItemResourcesList; /** Error message for the Action if an error occurred, otherwise null. */ error: ChangeZonePrimaryNameserversResponseActionError | null; } export type ListZoneActionsResponseActionsList = Array; /** See "[Pagination](#description/pagination)" for more information. */ export interface ListZoneActionsResponseMetaPagination { /** 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 ListZoneActionsResponseMeta { /** See "[Pagination](#description/pagination)" for more information. */ pagination: ListZoneActionsResponseMetaPagination; } export interface ListZoneActionsResponse { actions: ListZoneActionsResponseActionsList; meta: ListZoneActionsResponseMeta; } export type ListZonesActionsRequestIdList = Array; export type ListZonesActionsRequestSortItem = "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 ListZonesActionsRequestSortList = Array; /** Status of the Action. */ export type ListZonesActionsRequestStatusItem = "running" | "success" | "error"; export type ListZonesActionsRequestStatusList = Array; export interface ListZonesActionsRequest { /** Filter the actions by ID. May be used multiple times. The response will only contain actions matching the specified IDs. */ id?: ListZonesActionsRequestIdList; /** Sort actions by field and direction. May be used multiple times. For more information, see "[Sorting](#description/sorting)". */ sort?: ListZonesActionsRequestSortList; /** Filter the actions by status. May be used multiple times. The response will only contain actions matching the specified statuses. */ status?: ListZonesActionsRequestStatusList; /** 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 ListZonesActionsResponseActionsItemStatus = "running" | "success" | "error"; export type ListZonesActionsResponseActionsItemResourcesItem = ChangeZonePrimaryNameserversResponseActionResourcesItem; /** Resources the Action relates to. */ export type ListZonesActionsResponseActionsItemResourcesList = Array; /** Error message for the Action if an error occurred, otherwise null. */ export type ListZonesActionsResponseActionsItemError = ChangeZonePrimaryNameserversResponseActionError; export interface ListZonesActionsResponseActionsItem { /** ID of the [Action](#description/actions). */ id: number; /** Command executed in the Action. */ command: string; /** Status of the Action. */ status: ListZonesActionsResponseActionsItemStatus; /** 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: ListZonesActionsResponseActionsItemResourcesList; /** Error message for the Action if an error occurred, otherwise null. */ error: ChangeZonePrimaryNameserversResponseActionError | null; } export type ListZonesActionsResponseActionsList = Array; /** See "[Pagination](#description/pagination)" for more information. */ export type ListZonesActionsResponseMetaPagination = ListZoneActionsResponseMetaPagination; export type ListZonesActionsResponseMeta = ListZoneActionsResponseMeta; export interface ListZonesActionsResponse { actions: ListZonesActionsResponseActionsList; meta: ListZoneActionsResponseMeta; } export type ChangeZonePrimaryNameserversError = HetznerOpError; /** Change a Zone's Primary Nameservers Overwrites the primary nameservers of a [Zone](#tag/zones). Only applicable for [Zones](#tag/zones) in secondary mode. #### Operation specific errors */ export declare const changeZonePrimaryNameservers: API.OperationMethod; export type ChangeZoneProtectionError = HetznerOpError; /** Change a Zone's Protection Changes the protection configuration of a [Zone](#tag/zones). */ export declare const changeZoneProtection: API.OperationMethod; export type ChangeZoneTtlError = HetznerOpError; /** Change a Zone's Default TTL Changes the default Time To Live (TTL) of a [Zone](#tag/zones). This TTL is used for [RRSets](#tag/zone-rrsets) that do not explicitly define a TTL. Only applicable for [Zones](#tag/zones) in primary mode. #### Operation specific errors */ export declare const changeZoneTtl: API.OperationMethod; export type GetZonesActionError = HetznerOpError; /** Get an Action Returns a specific [Action](#tag/actions). */ export declare const getZonesAction: API.OperationMethod; export type ImportZoneZonefileError = HetznerOpError; /** Import a Zone file Imports a zone file, replacing all resource record sets ([RRSets](#tag/zone-rrsets)). The import will fail if existing [RRSet](#tag/zone-rrsets) are `change` protected. See [Zone file import](#tag/zones/zone-file-import) for more details. Only applicable for [Zones](#tag/zones) in primary mode. #### Operation specific errors */ export declare const importZoneZonefile: API.OperationMethod; export type ListZoneActionsError = HetznerOpError; /** List Actions for a Zone Returns all [Actions](#tag/actions) for a [Zone](#tag/zones). Use the provided URI parameters to modify the result. */ export declare const listZoneActions: API.PaginatedOperationMethod; export type ListZonesActionsError = HetznerOpError; /** List Actions Returns all [Zone](#tag/zones) [Actions](#tag/actions). Use the provided URI parameters to modify the result. */ export declare const listZonesActions: API.PaginatedOperationMethod; //# sourceMappingURL=zone_actions.d.ts.map