ibm-vpc
Version:
IBM Cloud VPC Node.js SDK
783 lines • 2.24 MB
TypeScript
/**
* (C) Copyright IBM Corp. 2023, 2024, 2025.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/// <reference types="node" />
import { IncomingHttpHeaders, OutgoingHttpHeaders } from 'http';
import { AbortSignal, BaseService, SDKLogger, UserOptions } from 'ibm-cloud-sdk-core';
/**
* The IBM Cloud Virtual Private Cloud (VPC) API can be used to programmatically provision and manage virtual server
* instances, along with subnets, volumes, load balancers, and more.
*
* API Version: 2025-09-23
*/
declare class VpcV1 extends BaseService {
static _logger: SDKLogger;
static DEFAULT_SERVICE_URL: string;
static DEFAULT_SERVICE_NAME: string;
private static _regionalEndpoints;
/**
* Returns the service URL associated with the specified region.
* @param region a string representing the region
* @returns the service URL associated with the specified region or undefined
* if no mapping for the region exists
*/
static getServiceUrlForRegion(region: string): string;
/*************************
* Factory method
************************/
/**
* Constructs an instance of VpcV1 with passed in options and external configuration.
*
* @param {UserOptions} [options] - The parameters to send to the service.
* @param {string} [options.serviceName] - The name of the service to configure
* @param {Authenticator} [options.authenticator] - The Authenticator object used to authenticate requests to the service
* @param {string} [options.serviceUrl] - The base URL for the service
* @returns {VpcV1}
*/
static newInstance(options: UserOptions): VpcV1;
/** The infrastructure generation. For the API behavior documented here, specify `2`. */
generation?: number;
/** The API version, in format `YYYY-MM-DD`. For the API behavior documented here, specify any date between
* `2025-09-16` and `2025-09-24`.
*/
version: string;
/**
* Construct a VpcV1 object.
*
* @param {Object} options - Options for the service.
* @param {number} [options.generation] - The infrastructure generation. For the API behavior documented here, specify
* `2`.
* @param {string} options.version - The API version, in format `YYYY-MM-DD`. For the API behavior documented here,
* specify any date between `2025-09-16` and `2025-09-24`.
* @param {string} [options.serviceUrl] - The base URL for the service
* @param {OutgoingHttpHeaders} [options.headers] - Default headers that shall be included with every request to the service.
* @param {Authenticator} options.authenticator - The Authenticator object used to authenticate requests to the service
* @constructor
* @returns {VpcV1}
*/
constructor(options: UserOptions);
/*************************
* backupPolicies
************************/
/**
* List backup policies.
*
* This request lists backup policies in the region. Backup policies control which sources are selected for backup and
* include a set of backup policy plans that provide the backup schedules and deletion triggers.
*
* @param {Object} [params] - The parameters to send to the service.
* @param {string} [params.start] - A server-provided token determining what resource to start the page on.
* @param {number} [params.limit] - The number of resources to return on a page.
* @param {string} [params.resourceGroupId] - Filters the collection to resources with a `resource_group.id` property
* matching the specified identifier.
* @param {string} [params.name] - Filters the collection to resources with a `name` property matching the exact
* specified name.
* @param {string} [params.tag] - Filters the collection to resources with an item in the `tags` property matching the
* exact specified tag.
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
* @returns {Promise<VpcV1.Response<VpcV1.BackupPolicyCollection>>}
*/
listBackupPolicies(params?: VpcV1.ListBackupPoliciesParams): Promise<VpcV1.Response<VpcV1.BackupPolicyCollection>>;
/**
* Create a backup policy.
*
* This request creates a new backup policy from a backup policy prototype object. The prototype object is structured
* in the same way as a retrieved backup policy, and contains the information necessary to create the new backup
* policy.
*
* @param {Object} params - The parameters to send to the service.
* @param {BackupPolicyPrototype} params.backupPolicyPrototype - The backup policy prototype object.
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
* @returns {Promise<VpcV1.Response<VpcV1.BackupPolicy>>}
*/
createBackupPolicy(params: VpcV1.CreateBackupPolicyParams): Promise<VpcV1.Response<VpcV1.BackupPolicy>>;
/**
* List jobs for a backup policy.
*
* This request retrieves jobs for a backup policy. A backup job represents the execution of a backup policy plan for
* a resource matching the policy's criteria.
*
* @param {Object} params - The parameters to send to the service.
* @param {string} params.backupPolicyId - The backup policy identifier.
* @param {string} [params.status] - Filters the collection to backup policy jobs with a `status` property matching
* the specified value.
* @param {string} [params.backupPolicyPlanId] - Filters the collection to backup policy jobs with a
* `backup_policy_plan.id` property matching the specified identifier.
* @param {string} [params.start] - A server-provided token determining what resource to start the page on.
* @param {number} [params.limit] - The number of resources to return on a page.
* @param {string} [params.sort] - Sorts the returned collection by the specified property name in ascending order. A
* `-` may be prepended to the name to sort in descending order. For example, the value `-created_at` sorts the
* collection by the `created_at` property in descending order, and the value `name` sorts it by the `name` property
* in ascending order.
* @param {string} [params.sourceId] - Filters the collection to backup policy jobs with a `source.id` property
* matching the specified identifier.
* @param {string} [params.targetSnapshotsId] - Filters the collection to backup policy jobs with an item in the
* `target_snapshots` property with an `id` property matching the specified identifier.
* @param {string} [params.targetSnapshotsCrn] - Filters the collection to backup policy jobs with an item in the
* `target_snapshots` property with a `crn` property matching the specified CRN.
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
* @returns {Promise<VpcV1.Response<VpcV1.BackupPolicyJobCollection>>}
*/
listBackupPolicyJobs(params: VpcV1.ListBackupPolicyJobsParams): Promise<VpcV1.Response<VpcV1.BackupPolicyJobCollection>>;
/**
* Retrieve a backup policy job.
*
* This request retrieves a single backup policy job specified by the identifier in the URL.
*
* @param {Object} params - The parameters to send to the service.
* @param {string} params.backupPolicyId - The backup policy identifier.
* @param {string} params.id - The backup policy job identifier.
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
* @returns {Promise<VpcV1.Response<VpcV1.BackupPolicyJob>>}
*/
getBackupPolicyJob(params: VpcV1.GetBackupPolicyJobParams): Promise<VpcV1.Response<VpcV1.BackupPolicyJob>>;
/**
* List plans for a backup policy.
*
* This request retrieves plans for a backup policy. Backup plans provide the backup schedule and deletion triggers.
*
* @param {Object} params - The parameters to send to the service.
* @param {string} params.backupPolicyId - The backup policy identifier.
* @param {string} [params.name] - Filters the collection to resources with a `name` property matching the exact
* specified name.
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
* @returns {Promise<VpcV1.Response<VpcV1.BackupPolicyPlanCollection>>}
*/
listBackupPolicyPlans(params: VpcV1.ListBackupPolicyPlansParams): Promise<VpcV1.Response<VpcV1.BackupPolicyPlanCollection>>;
/**
* Create a plan for a backup policy.
*
* This request creates a new backup policy plan from a backup policy plan prototype object. The prototype object is
* structured in the same way as a retrieved backup policy plan, and contains the information necessary to create the
* new backup policy plan.
*
* Backups created by this plan will use the resource group of the source being backed up.
*
* Backups created by this plan will use the plan's name truncated to 46 characters, followed by a unique 16-character
* suffix.
*
* @param {Object} params - The parameters to send to the service.
* @param {string} params.backupPolicyId - The backup policy identifier.
* @param {string} params.cronSpec - The cron specification for the backup schedule. The backup policy jobs
* (which create and delete backups for this plan) will not start until this time, and may start for up to 90 minutes
* after this time.
*
* All backup schedules for plans in the same policy must be at least an hour apart.
* @param {boolean} [params.active] - Indicates whether the plan is active.
* @param {string[]} [params.attachUserTags] - The user tags to attach to each backup (snapshot) created by this plan.
* @param {BackupPolicyPlanClonePolicyPrototype} [params.clonePolicy] -
* @param {boolean} [params.copyUserTags] - Indicates whether to copy the source's user tags to the created backups
* (snapshots).
* @param {BackupPolicyPlanDeletionTriggerPrototype} [params.deletionTrigger] -
* @param {string} [params.name] - The name for this backup policy plan. The name must not be used by another plan for
* the backup policy. If unspecified, the name will be a hyphenated list of randomly-selected words.
* @param {BackupPolicyPlanRemoteRegionPolicyPrototype[]} [params.remoteRegionPolicies] - The policies for additional
* backups in remote regions.
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
* @returns {Promise<VpcV1.Response<VpcV1.BackupPolicyPlan>>}
*/
createBackupPolicyPlan(params: VpcV1.CreateBackupPolicyPlanParams): Promise<VpcV1.Response<VpcV1.BackupPolicyPlan>>;
/**
* Delete a backup policy plan.
*
* This request deletes a backup policy plan. This operation cannot be reversed. Any backups that have been created by
* the plan will remain but will no longer be subject to the plan's deletion trigger. Any running jobs associated with
* the plan will run to completion before the plan is deleted.
*
* If the request is accepted, the backup policy plan `status` will be set to `deleting`. Once deletion processing
* completes, the backup policy plan will no longer be retrievable.
*
* @param {Object} params - The parameters to send to the service.
* @param {string} params.backupPolicyId - The backup policy identifier.
* @param {string} params.id - The backup policy plan identifier.
* @param {string} [params.ifMatch] - If present, the request will fail if the specified ETag value does not match the
* resource's current ETag value.
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
* @returns {Promise<VpcV1.Response<VpcV1.BackupPolicyPlan>>}
*/
deleteBackupPolicyPlan(params: VpcV1.DeleteBackupPolicyPlanParams): Promise<VpcV1.Response<VpcV1.BackupPolicyPlan>>;
/**
* Retrieve a backup policy plan.
*
* This request retrieves a single backup policy plan specified by the identifier in the URL.
*
* @param {Object} params - The parameters to send to the service.
* @param {string} params.backupPolicyId - The backup policy identifier.
* @param {string} params.id - The backup policy plan identifier.
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
* @returns {Promise<VpcV1.Response<VpcV1.BackupPolicyPlan>>}
*/
getBackupPolicyPlan(params: VpcV1.GetBackupPolicyPlanParams): Promise<VpcV1.Response<VpcV1.BackupPolicyPlan>>;
/**
* Update a backup policy plan.
*
* This request updates a backup policy plan with the information in a provided plan patch. The plan patch object is
* structured in the same way as a retrieved backup policy plan and can contains only the information to be updated.
*
* @param {Object} params - The parameters to send to the service.
* @param {string} params.backupPolicyId - The backup policy identifier.
* @param {string} params.id - The backup policy plan identifier.
* @param {boolean} [params.active] - Indicates whether the plan is active.
* @param {string[]} [params.attachUserTags] - The user tags to attach to backups (snapshots) created by this plan.
* Updating this value does not change the user tags for backups that have already been created by this plan.
* @param {BackupPolicyPlanClonePolicyPatch} [params.clonePolicy] -
* @param {boolean} [params.copyUserTags] - Indicates whether to copy the source's user tags to the created backups
* (snapshots).
* @param {string} [params.cronSpec] - The cron specification for the backup schedule. The backup policy jobs
* (which create and delete backups for this plan) will not start until this time, and may start for up to 90 minutes
* after this time.
*
* All backup schedules for plans in the same policy must be at least an hour apart.
* @param {BackupPolicyPlanDeletionTriggerPatch} [params.deletionTrigger] -
* @param {string} [params.name] - The name for this backup policy plan. The name must not be used by another plan for
* the backup policy.
* @param {BackupPolicyPlanRemoteRegionPolicyPrototype[]} [params.remoteRegionPolicies] - The policies for additional
* backups in remote regions (replacing any existing policies).
* @param {string} [params.ifMatch] - If present, the request will fail if the specified ETag value does not match the
* resource's current ETag value. Required if the request body includes an array.
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
* @returns {Promise<VpcV1.Response<VpcV1.BackupPolicyPlan>>}
*/
updateBackupPolicyPlan(params: VpcV1.UpdateBackupPolicyPlanParams): Promise<VpcV1.Response<VpcV1.BackupPolicyPlan>>;
/**
* Delete a backup policy.
*
* This request deletes a backup policy. This operation cannot be reversed.
*
* If the request is accepted, the backup policy `status` will be set to `deleting`. Once deletion processing
* completes, the backup policy will no longer be retrievable.
*
* @param {Object} params - The parameters to send to the service.
* @param {string} params.id - The backup policy identifier.
* @param {string} [params.ifMatch] - If present, the request will fail if the specified ETag value does not match the
* resource's current ETag value.
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
* @returns {Promise<VpcV1.Response<VpcV1.BackupPolicy>>}
*/
deleteBackupPolicy(params: VpcV1.DeleteBackupPolicyParams): Promise<VpcV1.Response<VpcV1.BackupPolicy>>;
/**
* Retrieve a backup policy.
*
* This request retrieves a single backup policy specified by the identifier in the URL.
*
* @param {Object} params - The parameters to send to the service.
* @param {string} params.id - The backup policy identifier.
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
* @returns {Promise<VpcV1.Response<VpcV1.BackupPolicy>>}
*/
getBackupPolicy(params: VpcV1.GetBackupPolicyParams): Promise<VpcV1.Response<VpcV1.BackupPolicy>>;
/**
* Update a backup policy.
*
* This request updates a backup policy with the information in a provided backup policy patch. The backup policy
* patch object is structured in the same way as a retrieved backup policy and contains only the information to be
* updated.
*
* @param {Object} params - The parameters to send to the service.
* @param {string} params.id - The backup policy identifier.
* @param {string[]} [params.includedContent] - The included content for backups created using this policy:
* - `boot_volume`: Include the instance's boot volume.
* - `data_volumes`: Include the instance's data volumes.
* @param {string[]} [params.matchUserTags] - The user tags this backup policy will apply to (replacing any existing
* tags). Resources that have both a matching user tag and a matching type will be subject to the backup policy.
* @param {string} [params.name] - The name for this backup policy. The name must not be used by another backup policy
* in the region.
* @param {string} [params.ifMatch] - If present, the request will fail if the specified ETag value does not match the
* resource's current ETag value. Required if the request body includes an array.
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
* @returns {Promise<VpcV1.Response<VpcV1.BackupPolicy>>}
*/
updateBackupPolicy(params: VpcV1.UpdateBackupPolicyParams): Promise<VpcV1.Response<VpcV1.BackupPolicy>>;
/*************************
* bareMetalServers
************************/
/**
* List bare metal server profiles.
*
* This request lists [bare metal server
* profiles](https://cloud.ibm.com/docs/vpc?topic=vpc-bare-metal-servers-profile) available in the region. A bare
* metal server profile specifies the performance characteristics and pricing model for a bare metal server.
*
* @param {Object} [params] - The parameters to send to the service.
* @param {string} [params.start] - A server-provided token determining what resource to start the page on.
* @param {number} [params.limit] - The number of resources to return on a page.
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
* @returns {Promise<VpcV1.Response<VpcV1.BareMetalServerProfileCollection>>}
*/
listBareMetalServerProfiles(params?: VpcV1.ListBareMetalServerProfilesParams): Promise<VpcV1.Response<VpcV1.BareMetalServerProfileCollection>>;
/**
* Retrieve a bare metal server profile.
*
* This request retrieves a single bare metal server profile specified by the name in the URL.
*
* @param {Object} params - The parameters to send to the service.
* @param {string} params.name - The bare metal server profile name.
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
* @returns {Promise<VpcV1.Response<VpcV1.BareMetalServerProfile>>}
*/
getBareMetalServerProfile(params: VpcV1.GetBareMetalServerProfileParams): Promise<VpcV1.Response<VpcV1.BareMetalServerProfile>>;
/**
* List bare metal servers.
*
* This request lists bare metal servers in the region.
*
* @param {Object} [params] - The parameters to send to the service.
* @param {string} [params.start] - A server-provided token determining what resource to start the page on.
* @param {number} [params.limit] - The number of resources to return on a page.
* @param {string} [params.resourceGroupId] - Filters the collection to resources with a `resource_group.id` property
* matching the specified identifier.
* @param {string} [params.name] - Filters the collection to resources with a `name` property matching the exact
* specified name.
* @param {string} [params.reservationId] - Filters the collection to resources with a `reservation.id` property
* matching the specified identifier.
* @param {string} [params.reservationCrn] - Filters the collection to resources with a `reservation.crn` property
* matching the specified identifier.
* @param {string} [params.reservationName] - Filters the collection to resources with a `reservation.name` property
* matching the specified identifier.
* @param {string} [params.vpcId] - Filters the collection to resources with a `vpc.id` property matching the
* specified identifier.
* @param {string} [params.vpcCrn] - Filters the collection to resources with a `vpc.crn` property matching the
* specified CRN.
* @param {string} [params.vpcName] - Filters the collection to resources with a `vpc.name` property matching the
* exact specified name.
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
* @returns {Promise<VpcV1.Response<VpcV1.BareMetalServerCollection>>}
*/
listBareMetalServers(params?: VpcV1.ListBareMetalServersParams): Promise<VpcV1.Response<VpcV1.BareMetalServerCollection>>;
/**
* Create a bare metal server.
*
* This request provisions a new bare metal server from a prototype object. The prototype object is structured in the
* same way as a retrieved bare metal server, and contains the information necessary to provision the new bare metal
* server. The bare metal server is automatically started.
*
* For this request to succeed, the properties in the request must adhere to the source image's `allowed_use`
* property.
*
* @param {Object} params - The parameters to send to the service.
* @param {BareMetalServerPrototype} params.bareMetalServerPrototype - The bare metal server prototype object.
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
* @returns {Promise<VpcV1.Response<VpcV1.BareMetalServer>>}
*/
createBareMetalServer(params: VpcV1.CreateBareMetalServerParams): Promise<VpcV1.Response<VpcV1.BareMetalServer>>;
/**
* Create a console access token for a bare metal server.
*
* This request creates a new single-use console access token for a bare metal server. All console configuration is
* provided at token create time, and the token is subsequently used in the `access_token` query parameter for the
* WebSocket request. The access token is only valid for a short period of time, and a maximum of one token is valid
* for a given bare metal server at a time. For this request to succeed, the server must have a `status` of
* `stopped`, `starting`, or `running`.
*
* @param {Object} params - The parameters to send to the service.
* @param {string} params.bareMetalServerId - The bare metal server identifier.
* @param {string} params.consoleType - The bare metal server console type for which this token may be used
*
* Must be `serial` for bare metal servers with a `cpu.architecture` of `s390x`.
* @param {boolean} [params.force] - Indicates whether to disconnect an existing serial console session as the serial
* console cannot be shared. This has no effect on VNC consoles.
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
* @returns {Promise<VpcV1.Response<VpcV1.BareMetalServerConsoleAccessToken>>}
*/
createBareMetalServerConsoleAccessToken(params: VpcV1.CreateBareMetalServerConsoleAccessTokenParams): Promise<VpcV1.Response<VpcV1.BareMetalServerConsoleAccessToken>>;
/**
* List disks on a bare metal server.
*
* This request lists disks on a bare metal server. A disk is a block device that is locally attached to the
* physical server. By default, the listed disks are sorted by their `created_at` property values, with the newest
* disk first.
*
* @param {Object} params - The parameters to send to the service.
* @param {string} params.bareMetalServerId - The bare metal server identifier.
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
* @returns {Promise<VpcV1.Response<VpcV1.BareMetalServerDiskCollection>>}
*/
listBareMetalServerDisks(params: VpcV1.ListBareMetalServerDisksParams): Promise<VpcV1.Response<VpcV1.BareMetalServerDiskCollection>>;
/**
* Retrieve a bare metal server disk.
*
* This request retrieves a single disk specified by the identifier in the URL.
*
* @param {Object} params - The parameters to send to the service.
* @param {string} params.bareMetalServerId - The bare metal server identifier.
* @param {string} params.id - The bare metal server disk identifier.
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
* @returns {Promise<VpcV1.Response<VpcV1.BareMetalServerDisk>>}
*/
getBareMetalServerDisk(params: VpcV1.GetBareMetalServerDiskParams): Promise<VpcV1.Response<VpcV1.BareMetalServerDisk>>;
/**
* Update a bare metal server disk.
*
* This request updates the bare metal server disk with the information in a provided patch.
*
* @param {Object} params - The parameters to send to the service.
* @param {string} params.bareMetalServerId - The bare metal server identifier.
* @param {string} params.id - The bare metal server disk identifier.
* @param {string} [params.name] - The name for this bare metal server disk. The name must not be used by another disk
* on the bare metal server.
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
* @returns {Promise<VpcV1.Response<VpcV1.BareMetalServerDisk>>}
*/
updateBareMetalServerDisk(params: VpcV1.UpdateBareMetalServerDiskParams): Promise<VpcV1.Response<VpcV1.BareMetalServerDisk>>;
/**
* List network attachments on a bare metal server.
*
* This request lists network attachments on a bare metal server. A bare metal server network attachment is an
* abstract representation of a network device and attaches a bare metal server to a single subnet. Each network
* interface on a bare metal server can attach to any subnet in the zone, including subnets that are already attached
* to the bare metal server.
*
* The network attachments will be sorted by their `created_at` property values, with newest network attachments
* first. Network attachments with identical `created_at` property values will in turn be sorted by ascending `name`
* property values.
*
* @param {Object} params - The parameters to send to the service.
* @param {string} params.bareMetalServerId - The bare metal server identifier.
* @param {string} [params.start] - A server-provided token determining what resource to start the page on.
* @param {number} [params.limit] - The number of resources to return on a page.
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
* @returns {Promise<VpcV1.Response<VpcV1.BareMetalServerNetworkAttachmentCollection>>}
*/
listBareMetalServerNetworkAttachments(params: VpcV1.ListBareMetalServerNetworkAttachmentsParams): Promise<VpcV1.Response<VpcV1.BareMetalServerNetworkAttachmentCollection>>;
/**
* Create a network attachment on a bare metal server.
*
* This request creates a new bare metal server network attachment from a bare metal server network attachment
* prototype object. The prototype object is structured in the same way as a retrieved bare metal server network
* attachment, and contains the information necessary to create the new bare metal server network attachment.
*
* @param {Object} params - The parameters to send to the service.
* @param {string} params.bareMetalServerId - The bare metal server identifier.
* @param {BareMetalServerNetworkAttachmentPrototype} params.bareMetalServerNetworkAttachmentPrototype - The bare
* metal server network attachment prototype object.
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
* @returns {Promise<VpcV1.Response<VpcV1.BareMetalServerNetworkAttachment>>}
*/
createBareMetalServerNetworkAttachment(params: VpcV1.CreateBareMetalServerNetworkAttachmentParams): Promise<VpcV1.Response<VpcV1.BareMetalServerNetworkAttachment>>;
/**
* Delete a bare metal server network attachment.
*
* This request deletes a bare metal server network attachment. This operation cannot be reversed. Any floating IPs
* associated with the bare metal server network attachment are implicitly disassociated.
*
* The bare metal server's primary network attachment cannot be deleted.
*
* @param {Object} params - The parameters to send to the service.
* @param {string} params.bareMetalServerId - The bare metal server identifier.
* @param {string} params.id - The bare metal server network attachment identifier.
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
* @returns {Promise<VpcV1.Response<VpcV1.EmptyObject>>}
*/
deleteBareMetalServerNetworkAttachment(params: VpcV1.DeleteBareMetalServerNetworkAttachmentParams): Promise<VpcV1.Response<VpcV1.EmptyObject>>;
/**
* Retrieve a bare metal server network attachment.
*
* This request retrieves a single bare metal server network attachment specified by the identifier in the URL.
*
* @param {Object} params - The parameters to send to the service.
* @param {string} params.bareMetalServerId - The bare metal server identifier.
* @param {string} params.id - The bare metal server network attachment identifier.
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
* @returns {Promise<VpcV1.Response<VpcV1.BareMetalServerNetworkAttachment>>}
*/
getBareMetalServerNetworkAttachment(params: VpcV1.GetBareMetalServerNetworkAttachmentParams): Promise<VpcV1.Response<VpcV1.BareMetalServerNetworkAttachment>>;
/**
* Update a bare metal server network attachment.
*
* This request updates a bare metal server network attachment with the information provided in a bare metal server
* network attachment patch object. The bare metal server network attachment patch object is structured in the same
* way as a retrieved bare metal server network attachment and contains only the information to be updated.
*
* @param {Object} params - The parameters to send to the service.
* @param {string} params.bareMetalServerId - The bare metal server identifier.
* @param {string} params.id - The bare metal server network attachment identifier.
* @param {number[]} [params.allowedVlans] - The VLAN IDs to allow for `vlan` attachments using this PCI attachment,
* replacing any existing VLAN IDs. The specified values must include IDs for all `vlan` attachments currently using
* this PCI attachment.
* @param {string} [params.name] - The name for this network attachment. The name must not be used by another network
* attachment for the bare metal server.
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
* @returns {Promise<VpcV1.Response<VpcV1.BareMetalServerNetworkAttachment>>}
*/
updateBareMetalServerNetworkAttachment(params: VpcV1.UpdateBareMetalServerNetworkAttachmentParams): Promise<VpcV1.Response<VpcV1.BareMetalServerNetworkAttachment>>;
/**
* List network interfaces on a bare metal server.
*
* This request lists network interfaces on a bare metal server. A bare metal server network interface is an abstract
* representation of a network device and attaches a bare metal server to a single subnet. Each network interface on a
* bare metal server can attach to any subnet in the zone, including subnets that are already attached to the bare
* metal server.
*
* If this bare metal server has network attachments, each returned network interface is a [read-only
* representation](https://cloud.ibm.com/docs/vpc?topic=vpc-vni-about#vni-old-api-clients) of its corresponding
* network attachment and its attached virtual network interface.
*
* @param {Object} params - The parameters to send to the service.
* @param {string} params.bareMetalServerId - The bare metal server identifier.
* @param {string} [params.start] - A server-provided token determining what resource to start the page on.
* @param {number} [params.limit] - The number of resources to return on a page.
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
* @returns {Promise<VpcV1.Response<VpcV1.BareMetalServerNetworkInterfaceCollection>>}
*/
listBareMetalServerNetworkInterfaces(params: VpcV1.ListBareMetalServerNetworkInterfacesParams): Promise<VpcV1.Response<VpcV1.BareMetalServerNetworkInterfaceCollection>>;
/**
* Create a network interface on a bare metal server.
*
* This request creates a new bare metal server network interface from a bare metal server network interface prototype
* object. The prototype object is structured in the same way as a retrieved bare metal server network interface, and
* contains the information necessary to create the new bare metal server network interface. Any subnet in the bare
* metal server's VPC may be specified, even if it is already attached to another bare metal server network interface.
* Addresses on the bare metal server network interface must be within the specified subnet's CIDR blocks.
*
* If this bare metal server has network attachments, each network interface is a [read-only
* representation](https://cloud.ibm.com/docs/vpc?topic=vpc-vni-about#vni-old-api-clients) of its corresponding
* network attachment and its attached virtual network interface, and new network interfaces are not allowed to be
* created.
*
* @param {Object} params - The parameters to send to the service.
* @param {string} params.bareMetalServerId - The bare metal server identifier.
* @param {BareMetalServerNetworkInterfacePrototype} params.bareMetalServerNetworkInterfacePrototype - The bare metal
* server network interface prototype object.
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
* @returns {Promise<VpcV1.Response<VpcV1.BareMetalServerNetworkInterface>>}
*/
createBareMetalServerNetworkInterface(params: VpcV1.CreateBareMetalServerNetworkInterfaceParams): Promise<VpcV1.Response<VpcV1.BareMetalServerNetworkInterface>>;
/**
* Delete a bare metal server network interface.
*
* This request deletes a bare metal server network interface. This operation cannot be reversed. Any floating IPs
* associated with the bare metal server network interface are implicitly disassociated. The primary bare metal
* server network interface is not allowed to be deleted.
*
* If this bare metal server has network attachments, this network interface is a [read-only
* representation](https://cloud.ibm.com/docs/vpc?topic=vpc-vni-about#vni-old-api-clients) of its corresponding
* network attachment and its attached virtual network interface, and is not allowed to be deleted.
*
* @param {Object} params - The parameters to send to the service.
* @param {string} params.bareMetalServerId - The bare metal server identifier.
* @param {string} params.id - The bare metal server network interface identifier.
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
* @returns {Promise<VpcV1.Response<VpcV1.EmptyObject>>}
*/
deleteBareMetalServerNetworkInterface(params: VpcV1.DeleteBareMetalServerNetworkInterfaceParams): Promise<VpcV1.Response<VpcV1.EmptyObject>>;
/**
* Retrieve a bare metal server network interface.
*
* This request retrieves a single bare metal server network interface specified by the identifier in the URL.
*
* If this bare metal server has network attachments, the retrieved network interface is a [read-only
* representation](https://cloud.ibm.com/docs/vpc?topic=vpc-vni-about#vni-old-api-clients) of its corresponding
* network attachment and its attached virtual network interface.
*
* @param {Object} params - The parameters to send to the service.
* @param {string} params.bareMetalServerId - The bare metal server identifier.
* @param {string} params.id - The bare metal server network interface identifier.
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
* @returns {Promise<VpcV1.Response<VpcV1.BareMetalServerNetworkInterface>>}
*/
getBareMetalServerNetworkInterface(params: VpcV1.GetBareMetalServerNetworkInterfaceParams): Promise<VpcV1.Response<VpcV1.BareMetalServerNetworkInterface>>;
/**
* Update a bare metal server network interface.
*
* This request updates a bare metal server network interface with the information provided in a bare metal server
* network interface patch object. The bare metal server network interface patch object is structured in the same way
* as a retrieved bare metal server network interface and needs to contain only the information to be updated.
*
* If this bare metal server has network attachments, this network interface is a [read-only
* representation](https://cloud.ibm.com/docs/vpc?topic=vpc-vni-about#vni-old-api-clients) of its corresponding
* network attachment and its attached virtual network interface, and is not allowed to be updated.
*
* @param {Object} params - The parameters to send to the service.
* @param {string} params.bareMetalServerId - The bare metal server identifier.
* @param {string} params.id - The bare metal server network interface identifier.
* @param {boolean} [params.allowIpSpoofing] - Indicates whether source IP spoofing is allowed on this bare metal
* server network interface.
*
* If this bare metal server has network attachments, this network interface is a
* [read-only representation](https://cloud.ibm.com/docs/vpc?topic=vpc-vni-about#vni-old-api-clients) of its
* corresponding network attachment and its attached virtual network interface, and source IP spoofing is managed on
* the attached virtual network interface.
* @param {number[]} [params.allowedVlans] - The VLAN IDs to allow for `vlan` interfaces using this PCI interface,
* replacing any existing VLAN IDs. The specified values must include IDs for all `vlan` interfaces currently using
* this PCI interface.
* @param {boolean} [params.enableInfrastructureNat] - If `true`:
* - The VPC infrastructure performs any needed NAT operations.
* - `floating_ips` must not have more than one floating IP.
*
* If `false`:
* - Packets are passed unchanged to/from the bare metal server network interface,
* allowing the workload to perform any needed NAT operations.
* - `allow_ip_spoofing` must be `false`.
* - `interface_type` must not be `hipersocket`.
*
* If this bare metal server has network attachments, this network interface is a
* [read-only representation](https://cloud.ibm.com/docs/vpc?topic=vpc-vni-about#vni-old-api-clients) of its
* corresponding network attachment and its attached virtual network interface, and infrastructure NAT is managed on
* the attached virtual network interface.
* @param {string} [params.name] - The name for this bare metal server network interface. The name must not be used by
* another network interface on the bare metal server.
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
* @returns {Promise<VpcV1.Response<VpcV1.BareMetalServerNetworkInterface>>}
*/
updateBareMetalServerNetworkInterface(params: VpcV1.UpdateBareMetalServerNetworkInterfaceParams): Promise<VpcV1.Response<VpcV1.BareMetalServerNetworkInterface>>;
/**
* List floating IPs associated with a bare metal server network interface.
*
* This request lists floating IPs associated with a bare metal server network interface.
*
* @param {Object} params - The parameters to send to the service.
* @param {string} params.bareMetalServerId - The bare metal server identifier.
* @param {string} params.networkInterfaceId - The bare metal server network interface identifier.
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
* @returns {Promise<VpcV1.Response<VpcV1.FloatingIPUnpaginatedCollection>>}
*/
listBareMetalServerNetworkInterfaceFloatingIps(params: VpcV1.ListBareMetalServerNetworkInterfaceFloatingIpsParams): Promise<VpcV1.Response<VpcV1.FloatingIPUnpaginatedCollection>>;
/**
* Disassociate a floating IP from a bare metal server network interface.
*
* This request disassociates the specified floating IP from the specified bare metal server network interface.
*
* @param {Object} params - The parameters to send to the service.
* @param {string} params.bareMetalServerId - The bare metal server identifier.
* @param {string} params.networkInterfaceId - The bare metal server network interface identifier.
* @param {string} params.id - The floating IP identifier.
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
* @returns {Promise<VpcV1.Response<VpcV1.EmptyObject>>}
*/
removeBareMetalServerNetworkInterfaceFloatingIp(params: VpcV1.RemoveBareMetalServerNetworkInterfaceFloatingIpParams): Promise<VpcV1.Response<VpcV1.EmptyObject>>;
/**
* Retrieve associated floating IP.
*
* This request retrieves a specified floating IP if it is associated with the bare metal server network interface
* specified in the URL.
*
* @param {Object} params - The parameters to send to the service.
* @param {string} params.bareMetalServerId - The bare metal server identifier.
* @param {string} params.networkInterfaceId - The bare metal server network interface identifier.
* @param {string} params.id - The floating IP identifier.
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
* @returns {Promise<VpcV1.Response<VpcV1.FloatingIP>>}
*/
getBareMetalServerNetworkInterfaceFloatingIp(params: VpcV1.GetBareMetalServerNetworkInterfaceFloatingIpParams): Promise<VpcV1.Response<VpcV1.FloatingIP>>;
/**
* Associate a floating IP with a bare metal server network interface.
*
* This request associates the specified floating IP with the specified bare metal server network interface. If
* `enable_infrastructure_nat` is `false`, this adds the IP to any existing associations. If
* `enable_infrastructure_nat` is `true`, this replaces any existing association.
*
* The existing floating IP must:
* - not be required by another resource, such as a public gateway
* - be in the same `zone` as the bare metal server
*
* A request body is not required, and if provided, is ignored.
*
* @param {Object} params - The parameters to send to the service.
* @param {string} params.bareMetalServerId - The bare metal server identifier.
* @param {string} params.networkInterfaceId - The bare metal server network interface identifier.
* @param {string} params.id - The floating IP identifier.
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
* @returns {Promise<VpcV1.Response<VpcV1.FloatingIP>>}
*/
addBareMetalServerNetworkInterfaceFloatingIp(params: VpcV1.AddBareMetalServerNetworkInterfaceFloatingIpParams): Promise<VpcV1.Response<VpcV1.FloatingIP>>;
/**
* List the primary reserved IP for a bare metal server network interface.
*
* This request lists the primary reserved IP for a bare metal server network interface.
*
* @param {Object} params - The parameters to send to the service.
* @param {string} params.bareMetalServerId - The bare metal server identifier.
* @param {string} params.networkInterfaceId - The bare metal server network interface identifier.
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
* @returns {Promise<VpcV1.Response<VpcV1.ReservedIPCollectionBareMetalServerNetworkInterfaceContext>>}
* @deprecated this method is deprecated and may be removed in a future release
*/
listBareMetalServerNetworkInterfaceIps(params: VpcV1.ListBareMetalServerNetworkInterfaceIpsParams): Promise<VpcV1.Response<VpcV1.ReservedIPCollectionBareMetalServerNetworkInterfaceContext>>;
/**
* Retrieve the primary reserved IP.
*
* This request retrieves the primary reserved IP for a bare metal server network interface.
*
* @param {Object} params - The parameters to send to the service.
* @param {string} params.bareMetalServerId - The bare metal server identifier.
* @param {string} params.networkInterfaceId - The bare metal server network interface identifier.
* @param {string} params.id - The reserved IP identifier.
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
* @returns {Promise<VpcV1.Response<VpcV1.ReservedIP>>}
* @deprecated this method is deprecated and may be removed in a future release
*/
getBareMetalServerNetworkInterfaceIp(params: VpcV1.GetBareMetalServerNetworkInterfaceIpParams): Promise<VpcV1.Response<VpcV1.ReservedIP>>;
/**
* Delete a bare metal server.
*
* This request deletes a bare metal server. This operation cannot be reversed. Any floating IPs associated with the
* bare metal server network interfaces are implicitly disassociated.
*
* @param {Object} params - The parameters to send to the service.
* @param {string} params.id - The bare metal server identifier.
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
* @returns {Promise<VpcV1.Response<VpcV1.EmptyObject>>}
*/
deleteBareMetalServer(params: VpcV1.DeleteBareMetalServerParams): Promise<VpcV1.Response<VpcV1.EmptyObject>>;
/**
* Retrieve a bare metal server.
*
* This request retrieves a single bare metal server specified by the identifier in the URL.
*
* @param {Object} params - The parameters to send to the service.
* @param {string} params.id - The bare metal server identifier.
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
* @returns {Promise<VpcV1.Response<VpcV1.BareMetalServer>>}
*/
getBareMetalServer(params: VpcV1.GetBareMetalServerParams): Promise<VpcV1.Response<VpcV1.BareMetalServer>>;
/**
* Update a bare metal server.
*
* This request updates a bare metal server with the information in a provided patch. The bare metal server patch
* object is structured in the same way as a retrieved bare metal server and contains only the information to be
* updated.
*
* For this request to succeed, the properties in the request must adhere to the `allowed_use` property of the disk
* referenced in the server's `boot_target`.
*
* @param {Object} params - The parameters to send to the service.
* @param {string} params.id - The bare metal server identifier.
* @param {number} [params.bandwidth] - The total bandwidth (in megabits per second) shared across the bare metal
* server's network interfaces. The specified value must match one of the bandwidth values in the bare metal server's
* profile.
* @param {boolean} [params.enableSecureBoot] - Indicates whether secure boot is enabled. If enabled, the image must
* support secure boot or the bare metal server will fail to boot.
*
* For `enable_secure_boot` to be changed, the bare metal server `status` must be
* `stopped`.
* @param {BareMetalServerMetadataServicePatch} [params.metadataService] - The metadata service configuration for the
* bare metal server.
* @param {string} [params.name] - The name for this bare metal server. The name must not be used by another bare
* metal server in the region. Changing the name will not affect the system hostname.
* @param {BareMetalServerReservationAffinityPatch} [params.reservationAffinity] -
* @param {BareMetalServerTrustedPlatformModulePatch} [params.trustedPlatformModule] -
* @param {OutgoingHttpHeaders} [params.headers] - Custom request headers
* @returns {Promise<VpcV1.Response<VpcV1.BareMetalServer>>}
*/
updateBareMetalServer(params: VpcV1.UpdateBareMetalServerParams): Promise<VpcV1.Response<VpcV1.BareMetalServer>>;
/**
* Update firmware for a bare metal server.
*
* This request updates a bare metal server to the latest available firmware. The server must be stopped.
*
* @param {Object} params - The parameters to send to the service.
* @param {string} params.id - The bare metal server identifier.
* @param {boolean} [params.autoStart] - Indicates whether to automatically start the bare metal server after the
* firmware update is successful