Skip to navigation

Batch Create Instances

View as Markdown

Batch create multiple Instances for Tenant with NVLink domain-aware machine allocation.

This endpoint creates multiple instances in a single atomic transaction. All instances share the same configuration (interfaces, OS, SSH keys, etc.) but are assigned different machines.

When topologyOptimized is true (default), all instances must be allocated on machines within the same NVLink domain. If insufficient machines are available in a single NVLink domain, the request will fail.

When topologyOptimized is false, instances can be spread across different NVLink domains.

Instance names are automatically generated using the namePrefix with a random 6-character suffix (e.g., “worker” becomes “worker-abc123”, “worker-def456”).

Org must have a Tenant entity. User must have authorization role with TENANT_ADMIN suffix.

Authentication

AuthorizationBearer
export JWT_BEARER_TOKEN="<jwt-bearer-token>"

# Example org name: "acme-inc
export ORG_NAME=<org-name>

# Use the JWT bearer token in your API request auth header:
curl -v -X GET -H "Content-Type: application/json" -H "Authorization: Bearer $JWT_BEARER_TOKEN" https://nico-rest-api.nico.svc.cluster.local/v2/org/$ORG_NAME/nico/user/current

Path parameters

orgstringRequired
Name of the Org

Request

This endpoint expects an object.
namePrefixstringRequired2-240 characters

Prefix for instance names. Instances will be named with this prefix followed by a random 6-character suffix (e.g., “worker” becomes “worker-abc123”)

countintegerRequired2-18

Number of instances to create in this batch. Minimum 2, maximum 18 (limited by topology domain size)

tenantIdstringRequiredformat: "uuid"
ID of the Tenant creating the Instances
instanceTypeIdstringRequiredformat: "uuid"
ID of the Instance Type to use for all Instances in the batch
vpcIdstringRequiredformat: "uuid"

ID of the Tenant-owned primary VPC the Instances should belong to

descriptionstring or nullOptional<=1024 characters
Description applied to all instances in the batch, optional
machineLabelSelectormap from strings to stringsOptional

Optional exact-match selector applied to Machine labels during placement. Property names are arbitrary Machine label keys rather than predefined selector fields. Every supplied key/value pair must match (AND semantics). An omitted or empty object does not restrict placement. The selector constrains placement only; it is not persisted on the created Instances.

A non-empty object requires the Tenant to have effective targetedInstanceCreation capability for the selected Site; otherwise the request is rejected with 403. Selection occurs before topology optimization. When topologyOptimized is true, all selected Machines must both match the selector and belong to the same NVLink domain. If too few matching Machines are available, the request is rejected with 409.

secondaryVpcIdslist of stringsOptional

IDs of additional VPCs every Instance should attach to through non-primary Interfaces. With effective crossTenantInterfaceCreation, these may include same-Site FNN VPC IDs owned by another Tenant, obtained out of band; the capability does not expose them through VPC discovery. This field may only be specified when every entry in interfaces uses vpcPrefixId or vpcId. IDs must be unique, valid UUIDs, and must not include the primary vpcId.

userDatastring or nullOptional

User data applied to all instances. Can only be specified if allowOverride is set to true in Operating System. Limited to 32768 bytes (32 KiB), measured on the effective value NICo stores rather than the text submitted. Operating System defaults are inherited first, and when phone-home is configured the document is re-serialized with a phone_home block added. Re-serialization normalizes indentation and can grow the document, so a request just under the limit may still be rejected.

operatingSystemIdstring or nullOptionalformat: "uuid"
Must be specified if iPXE Script field is empty
powerProfilestring or nullOptional>=1 character

Power profile to apply to every Instance in the batch. A non-empty value requires the Site’s dpsPowerManagement capability to be true.

networkSecurityGroupIdstring or nullOptionalformat: "uuid"

ID of a Network Security Group to attach to all Instances. This Instance-level policy takes precedence over VPC-level policy on every Interface.

ipxeScriptstring or nullOptional
Override iPXE script specified in OS, must be specified if Operating System is not specified
alwaysBootWithCustomIpxebooleanOptional
When set to true, the iPXE script specified by OS or overridden here will always be run when rebooting the Instances. OS must be of iPXE type.
phoneHomeEnabledbooleanOptional
When set to true, the Instances will be enabled with the Phone Home service.
labelsmap from strings to stringsOptional

Key-value objects to be applied to all instances (shared across all instances)

interfaceslist of objectsOptional

Interface configuration shared across all Instances. At least one interface must be specified unless autoNetwork is true. Interfaces must all be Subnet-backed or all be VPC-backed; VPC-backed interfaces may use an explicit vpcPrefixId or ask the Controller to select a prefix using vpcId and ipFamilies. A non-primary VPC-backed Interface may select a same-Site Ready FNN VPC or VPC Prefix owned by another Tenant only with effective crossTenantInterfaceCreation; cross-Tenant Subnets are never supported. Each batch member is resolved independently and may use a different prefix. The primary physical Interface must select the primary VPC. Only one network can be attached over a physical interface. Interface ipAddress is not supported for batch instance creation requests. Mutually exclusive with autoNetwork: when autoNetwork is true this list MUST be empty.

autoNetworkbooleanOptional

When true, asks NICo to auto-resolve each Instance’s network interfaces from the host’s underlay (HostInband) network segments. Intended for instances on zero-DPU hosts (or hosts with their DPU in NIC mode). When true: (1) the target VPC’s networkVirtualizationType MUST be FLAT, (2) interfaces MUST be empty or omitted, and (3) secondaryVpcIds MUST be empty or omitted.

infinibandInterfaceslist of objectsOptional
InfiniBand interface configuration shared across all instances
spectrumXAttachmentslist of objectsOptional

SpectrumX Partition attachments shared across all Instances in the batch. Each device and deviceInstance pair may appear only once, irrespective of virtualFunctionId. Every selected Machine must satisfy the entire list using its individual persisted capabilities, not Instance Type capability summaries. Compatible capacity is checked before selecting an NVLink domain when topology optimization is enabled. Insufficient compatible capacity returns 409 without allocating any Machines. The response identifies SpectrumX when filtering reduces otherwise sufficient capacity below the requested count, and identifies both SpectrumX and topology constraints when filtering removes candidates and no single NVLink domain has enough compatible Machines. Final allocation remains authoritative because persisted inventory can lag behind the Site.

dpuExtensionServiceDeploymentslist of objectsOptional
DPU Extension Services to deploy to all instances in the batch
nvLinkInterfaceslist of objectsOptional

NVLink interface configuration shared across all instances. A subset of GPUs may be specified. Each item references one GPU index (deviceInstance) and one NVLink Logical Partition. Different interfaces may reference different NVLink Logical Partitions.

sshKeyGroupIdslist of stringsOptional
SSH Key Group IDs that will provide Serial over LAN access to all instances
topologyOptimizedbooleanOptionalDefaults to true

When true (default), all instances must be allocated on machines within the same NVLink domain. When false, instances can be spread across different NVLink domains.

Response

Created
networkSecurityGroupPropagationDetailsobject or null
Network Security Group propagation details. Null when no details are available, including when no Network Security Group is attached or inherited.
idstringOptionalRead-onlyformat: "uuid"
Unique identifier for the Instance
namestringOptional2-256 characters
Name for the Instance
descriptionstring or nullOptional
Description for the Instance
tenantIdstringOptionalformat: "uuid"
ID of the Tenant the Instance belongs to
infrastructureProviderIdstringOptionalformat: "uuid"
ID of the Infrastructure Provider that owns the Site where the Instance is located
siteIdstringOptionalformat: "uuid"
ID of the Site where the Instance is located
instanceTypeIdstring or nullOptionalformat: "uuid"
ID of the Instance Type
vpcIdstringOptionalformat: "uuid"
ID of the VPC
secondaryVpcIdslist of stringsOptional

IDs of VPCs attached to the Instance through non-primary interfaces

machineIdstring or nullOptional
ID of the Machine
operatingSystemIdstring or nullOptionalformat: "uuid"
ID of the Operating System
networkSecurityGroupIdstring or nullOptional
ID of the attached Network Security Group, if any
powerProfilestring or nullOptional
External power provisioning profile associated with the Instance.
networkSecurityGroupInheritedbooleanOptional
Indicates if the Network Security Group is inherited from VPC
controllerInstanceIdstring or nullOptionalformat: "uuid"
ID of the Instance in Site Controller
ipxeScriptstring or nullOptional
Attribute which is inherited from Operating System
alwaysBootWithCustomIpxebooleanOptional
Indicates whether the Instance should always execute custom iPXE script when rebooting
phoneHomeEnabledbooleanOptional
Indicates whether the Phone Home service should be enabled or disabled for the Instance
userDatastring or nullOptional
UserData is inherited from Operating System or specified by user if allowed
labelsmap from strings to stringsOptional

User-specified Instance labels

isUpdatePendingbooleanOptional
Indicates whether an update is available for the Instance. Updates can be applied on reboot
serialConsoleUrlstring or nullOptional

Serial Console URL for the Instance. Format: ssh://<id>@siteSerialConsoleHostname

autoNetworkbooleanOptional

True when this Instance uses NICo auto-resolved networking from the host’s underlay (HostInband) network segments. When true, the caller’s request interfaces list was empty, this interfaces field remains empty on readback, and the resolved per-interface details surface under status.network.interfaces.

interfaceslist of objectsOptional
Interfaces are list of the subnet associated with the Instance
infinibandInterfaceslist of objectsOptional
InfiniBandInterfaces are list of the InfiniBandInterface associated with the Instance
spectrumXAttachmentslist of objectsOptional
SpectrumXAttachments are list of the SpectrumXAttachment associated with the Instance
nvLinkInterfaceslist of objectsOptional
NVLinkInterfaces are list of the NVLinkInterface associated with the Instance
dpuExtensionServiceDeploymentslist of objectsOptional
DPU Extension Services deployed on DPUs of this Instance
sshKeyGroupIdslist of stringsOptional
IDs of SSH Key Groups associated with this Instance
sshKeyGroupslist of objectsOptional
SSH Key Groups associated with this Instance, in summary form
tpmEkCertificatestring or nullOptional
base64 encoded TPM EK Certificate associated with this Instance
statusenumOptional
Status of the Instance
statusHistorylist of objectsOptional
Chronological status history for the Instance
deprecationslist of objectsOptional
Deprecations active for this resource. Returned only if there are active deprecations.
createddatetimeOptionalRead-only

Date/time when the Instance was created

updateddatetimeOptionalRead-only

Date/time when the Instance was last updated

Errors

400
Bad Request Error
403
Forbidden Error
409
Conflict Error
412
Precondition Failed Error
429
Too Many Requests Error