# Update ACL rules - UpdateNetworkAclEntry

## Overview

Update ACL rules






## Definition

### Public Parameters

| Parameter Name | Type | Description Information | Required |
|:---|:---|:---|:---|
| **Action**     | string  | Corresponding API command name, the current API is `UpdateNetworkAclEntry`.                      | **Yes** |
| **PublicKey**  | string  | The user's public key can be obtained from [Console](https://console.nubexcloud.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**|
| **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|
| **AclId** | string | ACL's ID |**Yes**|
| **EntryId** | string | Entry Id that needs to be updated |**Yes**|
| **Priority** | int | The priority of the Entry, for the same Direction, cannot be repeated. |**Yes**|
| **Direction** | string | Outbound or Inbound ("Ingress", "Egress") |**Yes**|
| **IpProtocol** | string | Targeted Protocol Rules |**Yes**|
| **CidrBlock** | string | CIDR representation of IPv4 segment |**Yes**|
| **PortRange** | string | Targeted Port Range |**Yes**|
| **EntryAction** | string | Behavior of the rule ("Accept", "Reject") |**Yes**|
| **Description** | string | Description |No|
| **TargetType** | int | Application target type. 0 represents 'All resources within the subnet', 1 represents 'Specified resources within the subnet'. The default is 0. |No|
| **TargetResourceIds.N** | string | Application target resource list. It is effective for all resources by default. This value does not need to be filled in when TargetType is 0. |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|




## Example

### Request Example
    
```
https://api.nubexcloud.com/?Action=UpdateNetworkAclEntry
&Region=cn-bj
&AclId=netacl-xxxxxx
&EntryId=netaclentry_xxxxxx
&Priority=4
&Direction=Ingress
&IpProtocol=TCP
&CidrBlock=0.0.0.0/0
&PortRange=1-65535
&EntryAction=WefbebUQ
&Description=kazGjdPZ
&TargetType=4
&TargetResourceIds.n=JNflNaTv
```

### Response Example
    
```json
{
  "Action": "UpdateNetworkAclEntryResponse",
  "RetCode": 0
}
```





