Enables the flow log feature.

Usage notes

  • You cannot repeatedly call the OpenFlowLogService operation within the specified period of time by using an Alibaba Cloud account.
  • You can call the GetFlowLogServiceStatus operation to query the status of the flow log feature.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request parameters

Parameter Type Required Example Description
Action String Yes OpenFlowLogService

The operation that you want to perform. Set the value to OpenFlowLogService.

ClientToken String No 123e4567-e89b-12d3-a456-426655440000

The client token that is used to ensure the idempotence of the request.

You can use the client to generate the token, but you must make sure that the token is unique among different requests. The token can contain only ASCII characters.

Note If you do not set this parameter, the system automatically set ClientToken to the value of RequestId. The value of RequestId for each API request is different.
RegionId String Yes cn-hangzhou

The region ID of the flow log.

You can call the DescribeRegions operation to query the most recent region list.

Response parameters

Parameter Type Example Description
RequestId String 28CF47AB-B6C0-5FA2-80C7-2B28826A92CB

The ID of the request.

Code String 200

The HTTP status code.

Message String successful

The information returned after the flow log feature is enabled.

Examples

Sample requests

http(s)://[Endpoint]/?Action=OpenFlowLogService
&ClientToken=123e4567-e89b-12d3-a456-426655440000
&RegionId=cn-hangzhou
&Common request parameters

Sample success responses

XML format

HTTP/1.1 200 OK
Content-Type:application/xml

<OpenFlowLogServiceResponse>
    <RequestId>28CF47AB-B6C0-5FA2-80C7-2B28826A92CB</RequestId>
    <Code>200</Code>
    <Message>successful</Message>
</OpenFlowLogServiceResponse>

JSON format

HTTP/1.1 200 OK
Content-Type:application/json

{
  "RequestId" : "28CF47AB-B6C0-5FA2-80C7-2B28826A92CB",
  "Code" : "200",
  "Message" : "successful"
}

Error codes

HttpCode Error code Error message Description
400 OperationFailed.ExceedPurchaseLimit You have reached the limit of purchase quantity. The error message returned because the maximum quantity for purchase is reached.
400 OperationFailed.AliGroupUserCanNotBuyInnerCommodity Vpc_flowlog_public has no group cloud product label, and users within the group are not allowed to purchase. The error message returned because vpc_flowlog_public does not have a merchandise tag and cannot be purchased by an internal group user.
400 Forbidden.RAM User not authorized to operate on the specified resource The error message returned because the Resource Access Management (RAM) user is unauthorized to perform the operation.
400 OperationFailed.QuotaNotEnough Your quota is insufficient. Please contact your channel partner to increase your quota The error message returned because the quota is insufficient. You can contact your channel partner to request a quota increase.
400 Order.NoRealNameAuthentication Real-name verification has not been completed for the account. The error message returned because you have not completed real-name verification. Go to User Center to complete real-name verification.

For a list of error codes, visit the API Error Center.