# Add UK8S Node Pool - AddUK8SNodeGroup

## Overview

Add UK8S Node Pool






## Definition

### Public Parameters

| Parameter Name | Type | Description Information | Required |
|:---|:---|:---|:---|
| **Action**     | string  | Corresponding API command name, the current API is `AddUK8SNodeGroup`.                      | **Yes** |
| **PublicKey**  | string  | The user's public key can be obtained from [Console](https://console.ziguang.unicloud.com/uaccount/api_manage)                                             | **Yes** |
| **Signature**  | string  | User signature generated based on public key and API command, see [Signature Algorithm](/docs/api/summary/signature.md)  | **Yes** |

### Request Parameters

| Parameter Name | Type | Description Information | Required |
|:---|:---|:---|:---|
| **Region** | string | Region. See [List of Regions and Availability Zones](/docs/api/summary/regionlist) |**Yes**|
| **Zone** | string | Availability Zone. See [Availability Zone List](/docs/api/summary/regionlist) |No|
| **ProjectId** | string | Project ID. If not filled in, the default project is used, sub-accounts must be filled in. Please refer to the [GetProjectList interface](/docs/api/summary/get_project_list). |No|
| **NodeGroupName** | string | Node Pool Name |**Yes**|
| **ClusterId** | string | Cluster ID |**Yes**|
| **ImageId** | string | Image ID |**Yes**|
| **MachineType** | string | Cloud host machine type. Enumeration values ["N", "C", "G", "O", "OS"]. Refer to [Cloud host machine type description](api/uhost-api/uhost_type). |**Yes**|
| **CPU** | int | Number of CPU cores |**Yes**|
| **Mem** | int | Memory size. Unit: MB |**Yes**|
| **BootDiskType** | string | Disk Type |**Yes**|
| **BootDiskSize** | int | System disk size, in GB. Default is 40. Range: [40, 500]. Please note that SSD local disk cannot be adjusted. |**Yes**|
| **SubnetId** | string | Subnet ID. The default is the subnet ID filled in when the cluster is created, or you can fill in the subnet ID within the same VPC as the cluster. |**Yes**|
| **MinimalCpuPlatform** | string | Lowest CPU platform, enumeration values ["Intel/Auto", "Intel/IvyBridge", "Intel/Haswell", "Intel/Broadwell", "Intel/Skylake", "Intel/Cascadelake", "Intel/CascadelakeR", “Amd/Epyc2”, "Amd/Auto"], the default value is "Intel/Auto". |No|
| **GpuType** | string | GPU Type |No|
| **GPU** | int | Number of GPU card cores. Only GPU models support this field (optional range related to MachineType+GpuType). |No|
| **DataDiskSize** | int | Data Disk Size |No|
| **DataDiskType** | string | Disk Type |No|
| **Tag** | string | Business Group |No|
| **ChargeType** | string | Billing Mode |No|
| **UHostFamily** | string | UHost Family |No|
| **SecurityMode** | string | Host Security Mode. Firewall: Firewall; SecGroup: Security Group; Default Value: Firewall. |No|
| **NodeNamePrefix** | string | The custom Uhost instance name prefix. The full custom Uhost instance name should be {NodeNamePrefix}-{NodeIP}. |No|
| **ZoneBaned** | string | Availability Zone. See [Availability Zone List](/docs/api/summary/regionlist) |No|
| **IsolationGroupId** | string | Hardware isolation group ID. It can be obtained through DescribeIsolationGroup. |No|
| **MaxPods** | string | Default is 110, it is recommended to be less than or equal to 110 in a production environment. |No|
| **UserData** | string | User-defined data. This field can be filled in when the image supports the Cloud-init Feature. Note: 1. The total data size should not exceed 16K; 2. Use base64 encoding. |No|
| **InitScript** | string | User-defined Shell scripts. The difference from UserData is that InitScript is executed after the node initialization is complete, while UserData is executed during the initialization of the UHost. |No|
| **Taints** | string | Node taint, in the format key=value:effect, multiple taints are separated by ",", supporting up to five groups. |No|
| **Labels** | string | Node label. In the form of key=value, multiple groups are separated by "," with a maximum of 5 groups. For example, env=pro,type=game |No|
| **NetCapability** | string | Network enhancement features. Enumeration values: Normal, not enabled; Super, enable Network Enhancement 1.0; Ultra, enable Network Enhancement 2.0; Extreme, enable Network Enhancement 3.0; Infiniband, enable Network Enhancement 4.0 (for details, refer to the official website documentation). |No|
| **UNIFeature** | boolean | Elastic NIC Feature. This feature is effective only when the Elastic NIC permission bit is enabled. By default, it is false (disabled), true (enabled). |No|
| **SecGroupId.N.Id** | string | Security Group ID. Up to 5 security groups can be bound at the same time. |No|
| **SecGroupId.N.Priority** | string | Security Group Priority. Value range [1, 5] |No|
| **SecGroupId.N.Name** | string | Security Group Name. |No|
| **SecurityGroupId** | string | Firewall ID, default: Web recommended firewall. For how to query SecurityGroupId, please refer to [DescribeFirewall](api/unet-api/describe_firewall.html). |No|
| **NetworkInterface.N.EIP.Bandwidth** | int | [If EIP is bound, this parameter is required] The bandwidth of the Elastic IP in the public network, in Mbps. Shared bandwidth mode must specify 0M bandwidth, non-shared bandwidth mode must specify non-0Mbps bandwidth. The bandwidth range of non-shared bandwidth in various regions is as follows: Traffic billing [1-300], Bandwidth billing [1-800] |No|
| **NetworkInterface.N.EIP.PayMode** | string | Billing mode of Elastic IP. Enumerated values: "Traffic", traffic billing; "Bandwidth", bandwidth billing; "ShareBandwidth", shared bandwidth mode. "Free": Free bandwidth mode, default is "Bandwidth". |No|
| **NetworkInterface.N.EIP.ShareBandwidthId** | string | The ID of the bound shared bandwidth, effective only when PayMode is set to ShareBandwidth. |No|
| **NetworkInterface.N.EIP.OperatorName** | string | [If EIP is bound, this parameter is required] The line of the Elastic IP. Enumeration value: International: International BGP: Bgp. The line parameters allowed in each region are as follows: cn-sh1: Bgp cn-sh2: Bgp cn-gd: Bgp cn-bj1: Bgp cn-bj2: Bgp hk: International us-ca: International th-bkk: International kr-seoul: International us-ws: International ge-fra: International sg: International tw-kh: International. All other overseas lines are International |No|
| **NetworkInterface.N.EIP.CouponId** | string | The current EIP coupon id. Please query through the DescribeCoupon interface, or log in to the user center to view. |No|
| **KubeletConfiguration.ContainerLogMaxFiles** | int | The maximum number of log files for the container, must be greater than or equal to 2. |No|
| **KubeletConfiguration.ContainerLogMaxSize** | string | The maximum threshold for container log file rotation to generate a new file, must end with 'Mi'. |No|
| **KubeletConfiguration.ImageGCHighThresholdPercent** | int | Configure the disk usage percentage threshold for images. Once the image usage exceeds this threshold, image garbage collection will continue to run.<br />​​Valid range:​​ [1, 100], and the value must be greater than ImageGCLowThresholdPercent. |No|
| **KubeletConfiguration.ImageGCLowThresholdPercent** | int | Configure the disk usage percentage threshold for images. Image garbage collection will not be triggered when the image usage falls below this threshold.<br />​​Valid range:​​ [1, 100], and the value must be less than the value of imageGCHighThresholdPercent. |No|
| **KubeletConfiguration.MaxPods** | int | ​​The maximum number of pods that can run on a node. The value must be greater than 0.​​ |No|
| **KubeletConfiguration.EvictionHard.MemoryAvailable** | string | Memory usage threshold for triggering pod eviction: must end with 'Mi' or 'Gi'. |No|
| **KubeletConfiguration.EvictionHard.ImagefsAvailable** | string | The free space threshold for container images that triggers pod eviction: must end with '%'. |No|
| **KubeletConfiguration.EvictionHard.NodefsAvailable** | string | The nodefs free space threshold for triggering pod eviction: must end with '%'. |No|
| **KubeletConfiguration.EvictionHard.NodefsInodesFree** | string | The nodefs inodes free threshold for triggering pod eviction: must end with '%'. |No|
| **KubeletConfiguration.EvictionSoft.MemoryAvailable** | string | Memory usage soft threshold for triggering pod eviction: must end with 'Mi' or 'Gi'. Must be configured together with EvictionSoftGracePeriod.MemoryAvailable. |No|
| **KubeletConfiguration.EvictionSoft.ImagefsAvailable** | string | The imagefs available soft threshold for triggering pod eviction: must end with '%'. This value must be configured together with EvictionSoftGracePeriod.ImagefsAvailable. |No|
| **KubeletConfiguration.EvictionSoft.NodefsAvailable** | string | The nodefs available soft threshold for triggering pod eviction: must end with '%'. This value must be configured together with EvictionSoftGracePeriod.NodefsAvailable. |No|
| **KubeletConfiguration.EvictionSoft.NodefsInodesFree** | string | The nodefs inodes free soft threshold for triggering pod eviction: must end with '%'. This value must be configured together with EvictionSoftGracePeriod.NodefsInodesFree. |No|
| **KubeletConfiguration.EvictionSoftGracePeriod.MemoryAvailable** | string | ​​The grace period for MemoryAvailable soft eviction thresholds must end with 's'.​​ |No|
| **KubeletConfiguration.EvictionSoftGracePeriod.ImagefsAvailable** | string | ​​The grace period for ImagefsAvailable soft eviction thresholds must end with 's'.​​ |No|
| **KubeletConfiguration.EvictionSoftGracePeriod.NodefsAvailable** | string | ​​The grace period for NodefsAvailable soft eviction thresholds must end with 's'.​​ |No|
| **KubeletConfiguration.EvictionSoftGracePeriod.NodefsInodesFree** | string | ​​The grace period for NodefsInodesFree soft eviction thresholds must end with 's'.​​ |No|
| **KubeletConfiguration.KubeReserved.CPU** | string | Kubelet reserved CPU resources must end with 'm'. |No|
| **KubeletConfiguration.KubeReserved.Memory** | string | Kubelet reserved memory resources must end with 'Mi'. |No|
| **KubeletConfiguration.KubeReserved.EphemeralStorage** | string | Kubelet reserved storage resources must end with 'Gi'. |No|
| **KubeletConfiguration.KubeReserved.Pid** | string | Kubelet reserved pids, must be greater than 499 |No|
| **KubeletConfiguration.SystemReserved.CPU** | string | System reserved CPU resources must end with 'm'. |No|
| **KubeletConfiguration.SystemReserved.Memory** | string | System reserved memory resources must end with 'Mi'. |No|
| **KubeletConfiguration.SystemReserved.EphemeralStorage** | string | System reserved storage resources must end with 'Gi'. |No|
| **KubeletConfiguration.SystemReserved.Pid** | string | System reserved pids, must be greater than 499 |No|

### Response Field

| Field Name | Type | Description Information | Required |
|:---|:---|:---|:---|
| **RetCode** | int | Return status code. If it is 0, it means successful return. If it is not 0, it means failure. |**Yes**|
| **Action** | string | Operation command name. |**Yes**|
| **Message** | string | Returns an error message, providing detailed description when `RetCode` is non-zero. |No|
| **NodeGroupId** | string | Node Pool ID |**Yes**|




## Example

### Request Example
    
```
https://api.ziguang.unicloud.com/?Action=AddUK8SNodeGroup
&Region=cn-zj
&Zone=cn-zj-01
&ProjectId=erWPRmTL
&NodeGroupName=sDJQamTw
&ImageId=SErYualz
&MachineType=ulkHtgvq
&MinimalCpuPlatform=llOxqZiy
&CPU=2
&Mem=9
&GpuType=VHPlqtNm
&GPU=7
&BootDiskType=KLbRaYoT
&DataDiskSize=vNWywYIK
&DataDiskType=zdhEnXgA
&Tag=gsZPoUZG
&ChargeType=yhQCTlsM
&ClusterId=tzEjlYyc
&OrgId=8
&TopOrgId=2
&AzGroupId=6
&BootDiskSize=8
&SubnetId=ZASbmHVG
&IsolationGroupId=rVPVzcuA
&MaxPods=IlFXQKpi
&Zone=BQVngVNW
&UserData=YdYsclDf
&InitScript=njpfkDoa
&Taints=JlvPCRQI
&Labels=KeZvvDqr
&NetCapability=ToNrUpTZ
&UNIFeature=true
&SecGroupId=SISNBXEt
&NodeNamePrefix=YsEvGYJy
&NodeNamePrefix=NLzvyZwn
&SecGroupId.N.Priority=hvfZZDWv
&SecGroupId.N.Name=Xskxfpsi
&SecurityMode=ISGiIbEq
&SecurityGroupId=uqsPnEZP
&NetworkInterface.N.EIP.Bandwidth=IJWLkNmH
&NetworkInterface.N.EIP.PayMode=mEgQvaaF
&NetworkInterface.N.EIP.ShareBandwidthId=nUrrbnuU
&NetworkInterface.N.EIP.OperatorName=YqGYAQqd
&NetworkInterface.N.EIP.CouponId=qhIrtbVL
&KubeletConfiguration.ContainerLogMaxFiles=2
&KubeletConfiguration.ContainerLogMaxSize=pQzokxuL
&KubeletConfiguration.ImageGCHighThresholdPercent=1
&KubeletConfiguration.ImageGCLowThresholdPercent=2
&KubeletConfiguration.MaxPods=2
&KubeletConfiguration.ContainerLogMaxFiles=7
&KubeletConfiguration.ContainerLogMaxSize=aGRRIizA
&KubeletConfiguration.ImageGCHighThresholdPercent=2
&KubeletConfiguration.ImageGCLowThresholdPercent=1
&KubeletConfiguration.MaxPods=6
&KubeletConfiguration.EvictionHard.MemoryAvailable=QgsrWvRw
&KubeletConfiguration.EvictionHard.ImagefsAvailable=lsLRZbTm
&KubeletConfiguration.EvictionHard.NodefsAvailable=DMqtzlZh
&KubeletConfiguration.EvictionHard.NodefsInodesFree=IcMWVlJk
&KubeletConfiguration.EvictionSoft.MemoryAvailable=ikYQuqNi
&KubeletConfiguration.EvictionSoft.ImagefsAvailable=rDnxGKDg
&KubeletConfiguration.EvictionSoft.NodefsAvailable=GdGMKqop
&KubeletConfiguration.EvictionSoft.NodefsInodesFree=myCpyBJt
&KubeletConfiguration.EvictionSoft.MemoryAvailable=acNhYicF
&KubeletConfiguration.EvictionSoft.ImagefsAvailable=MAxMTeQI
&KubeletConfiguration.EvictionSoft.NodefsAvailable=EGgCtjiQ
&KubeletConfiguration.EvictionSoft.NodefsInodesFree=TswzCxaT
&KubeletConfiguration.EvictionSoft.MemoryAvailable=AKziQgxI
&KubeletConfiguration.EvictionSoft.ImagefsAvailable=nRujUJRW
&KubeletConfiguration.EvictionSoft.NodefsAvailable=IQvGNHmz
&KubeletConfiguration.EvictionSoft.NodefsInodesFree=EPoRhdQt
&KubeletConfiguration.KubeletConfiguration.MemoryAvailable=EhCrBBAT
&KubeletConfiguration.KubeletConfiguration.ImagefsAvailable=YuKNPiFk
&KubeletConfiguration.KubeletConfiguration.NodefsAvailable=gjFqCMfB
&KubeletConfiguration.KubeletConfiguration.NodefsInodesFree=qPGbvYKW
&KubeletConfiguration.KubeReserved.CPU=AjDXLoCd
&KubeletConfiguration.KubeReserved.Memory=qIajlWXF
&KubeletConfiguration.KubeReserved.EphemeralStorage=wdjSwEdL
&KubeletConfiguration.KubeReserved.Pid=6
&KubeletConfiguration.SystemReserved.CPU=cejkMvfh
&KubeletConfiguration.SystemReserved.Memory=RCpMnKmi
&KubeletConfiguration.SystemReserved.EphemeralStorage=SkCWOsjl
&KubeletConfiguration.SystemReserved.Pid=3
&UHostFamily=oCLJuJjs
```

### Response Example
    
```json
{
  "Action": "AddUK8SNodeGroupResponse",
  "Message": "DMJPRigX",
  "NodeGroupId": "jXKZQgSU",
  "RetCode": 0
}
```





