All Products
Search
Document Center

Smart Access Gateway:ModifyFlowLogAttribute

Last Updated:Mar 24, 2026

Updates the settings of a flow log.

Try it now

Try this API in OpenAPI Explorer, no manual signing needed. Successful calls auto-generate SDK code matching your parameters. Download it with built-in credential security for local usage.

Test

RAM authorization

The table below describes the authorization required to call this API. You can define it in a Resource Access Management (RAM) policy. The table's columns are detailed below:

  • Action: The actions can be used in the Action element of RAM permission policy statements to grant permissions to perform the operation.

  • API: The API that you can call to perform the action.

  • Access level: The predefined level of access granted for each API. Valid values: create, list, get, update, and delete.

  • Resource type: The type of the resource that supports authorization to perform the action. It indicates if the action supports resource-level permission. The specified resource must be compatible with the action. Otherwise, the policy will be ineffective.

    • For APIs with resource-level permissions, required resource types are marked with an asterisk (*). Specify the corresponding Alibaba Cloud Resource Name (ARN) in the Resource element of the policy.

    • For APIs without resource-level permissions, it is shown as All Resources. Use an asterisk (*) in the Resource element of the policy.

  • Condition key: The condition keys defined by the service. The key allows for granular control, applying to either actions alone or actions associated with specific resources. In addition to service-specific condition keys, Alibaba Cloud provides a set of common condition keys applicable across all RAM-supported services.

  • Dependent action: The dependent actions required to run the action. To complete the action, the RAM user or the RAM role must have the permissions to perform all dependent actions.

Action

Access level

Resource type

Condition key

Dependent action

smartag:ModifyFlowLogAttribute

update

*All Resource

*

None None

Request parameters

Parameter

Type

Required

Description

Example

RegionId

string

Yes

The ID of the region where the flow log is deployed.

cn-shanghai

Description

string

No

The description of the flow log.

流日志实例1

Name

string

No

The name of the flow log.

DDE

ActiveAging

integer

No

The interval at which log data of active network connections is collected. Default value: 300. Unit: seconds.

300

InactiveAging

integer

No

The interval at which log data of inactive network connections is collected. Default value: 15. Unit: seconds.

15

OutputType

string

No

The location where the flow log is stored. Valid values:

  • sls: The flow log is stored in Log Service.

  • netflow: The flow log is stored on a NetFlow collector.

  • all: The flow log is stored both in Log Service and on a NetFlow collector.

sls

SlsRegionId

string

No

The ID of the region where Log Service is deployed. This parameter is required when OutputType is set to sls.

cn-shanghai

ProjectName

string

No

The project to which the Logstore of Log Service belongs. This parameter is required when OutputType is set to sls.

ddrrgt

LogstoreName

string

No

The Logstore of Log Service. This parameter is required when OutputType is set to sls.

ssfghgh

NetflowServerIp

string

No

The IP address of the NetFlow collector where the flow log is stored. This parameter is required when OutputType is set to netflow.

192.168.0.2

NetflowServerPort

integer

No

The port of the NetFlow collector. Default value: 9995. This parameter is required when OutputType is set to netflow.

9995

NetflowVersion

string

No

The NetFlow version. Valid values: V5, V9, and V10. Default value: V9. This parameter is required when OutputType is set to netflow.

V9

FlowLogId

string

Yes

The ID of the flow log.

fl-7a56mar1kfw9vj****

Response elements

Element

Type

Description

Example

object

RequestId

string

The ID of the request.

AAC70A63-1A2E-4857-9CA3-5DE5B4041D1E

Examples

Success response

JSON format

{
  "RequestId": "AAC70A63-1A2E-4857-9CA3-5DE5B4041D1E"
}

Error codes

HTTP status code

Error code

Error message

Description

400 DependencyViolation.FlowLog This FlowLog instance is bound to an SAG instance. This flow log associated with a resource.
400 IncorrectStatus.FlowLog The current FlowLog instance status does not support this operation. The status of the flow log is invalid.
400 InvalidFlowLogId.NotFound The specified FlowLogId does not exist. The specified FlowLogId does not exist.
400 MissingParam.FlowLogId Specify the FlowLogId parameter. You must set the FlowLogId parameter.
400 OperationFailed.AssociateFlowLog The operation failed. The specified SAG instance has already been associated with another FlowLog instance. The operation failed. The specified SAG instance has already been associated with another flow log.
400 OperationUnsupported.AssociateFlowLog You cannot bind the SAG device of the current version or model to a FlowLog instance. The version or model of the SAG device does not allow you to associate it with a flow log.
400 QuotaExceeded.Flowlog The maximum number of FlowLog instances is exceeded. The number of flow logs has reached the upper limit.
400 IllegalParam.ActiveAging The specified ActiveAging is invalid. The ActiveAging parameter is set to an invalid value.
400 IllegalParam.InactiveAging The specified InactiveAging is invalid. The InactiveAging parameter is set to an invalid value.
400 IllegalParam.OutputType The specified OutputType is invalid. The OutputType parameter is set to an invalid value.
400 IllegalParam.NetflowServerIp The specified NetflowServerIp is invalid. The NetflowServerIp parameter is set to an invalid value.
400 IllegalParam.NetflowServerPort The specified NetflowServerPort is invalid. The NetflowServerPort parameter is set to an invalid value.
400 IllegalParam.NetflowVersion The specified NetflowVersion is invalid. The NetflowVersion parameter is set to an invalid value.
400 MissingParam.NetflowServerIp Specify the NetflowServerIp parameter. You must set the NetflowServerIp parameter.
400 MissingParam.NetflowServerPort Specify the NetflowServerPort parameter. You must set the NetflowServerPort parameter.
400 MissingParam.NetflowVersion Specify the NetflowVersion parameter. You must set the NetflowVersion parameter.
400 IllegalParam.SlsRegionId The specified SlsRegionId is invalid. The SlsRegionId parameter is set to an invalid value.
400 MissingParam.SlsRegionId Specify the SlsRegionId parameter. You must set the SlsRegionId parameter.
400 IllegalParam.RegionId The specified RegionId is invalid. The RegionId parameter is set to an invalid value.
400 IllegalParam.Status The specified Status parameter is invalid. The Status parameter is set to an invalid value.
400 InvalidSmartAGId.NotFound The specified SmartAGId does not exist. The specified SmartAGId does not exist.
403 FeatureNotSupport The current edition of the smart access gateway does not support this feature. The current version of Smart Access Gateway does not support this feature.

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.