All Products
Search
Document Center

Cloud Enterprise Network:DescribeFlowlogs

Last Updated:Mar 01, 2024

Queries flow logs.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer.

Authorization information

The following table shows the authorization information corresponding to the API. The authorization information can be used in the Action policy element to grant a RAM user or RAM role the permissions to call this API operation. Description:

  • Operation: the value that you can use in the Action element to specify the operation on a resource.
  • Access level: the access level of each operation. The levels are read, write, and list.
  • Resource type: the type of the resource on which you can authorize the RAM user or the RAM role to perform the operation. Take note of the following items:
    • The required resource types are displayed in bold characters.
    • If the permissions cannot be granted at the resource level, All Resources is used in the Resource type column of the operation.
  • Condition Key: the condition key that is defined by the cloud service.
  • Associated operation: other operations that the RAM user or the RAM role must have permissions to perform to complete the operation. To complete the operation, the RAM user or the RAM role must have the permissions to perform the associated operations.
OperationAccess levelResource typeCondition keyAssociated operation
cen:DescribeFlowlogsRead
  • Flowlog
    acs:cbn:{#regionId}:{#accountId}:flowlog/*
  • Flowlog
    acs:cbn:{#regionId}:{#accountId}:flowlog/{#FlowLogId}
    none
none

Request parameters

ParameterTypeRequiredDescriptionExample
ClientTokenstringNo

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

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

Note If you do not set this parameter, ClientToken is set to the value of RequestId. The value of RequestId for each API request may be different.
123e4567-e89b-12d3-a456-42665544****
RegionIdstringNo

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

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

cn-hangzhou
FlowLogNamestringNo

The name of the flow log.

The name must be 2 to 128 characters in length, and can contain letters, digits, periods (.), underscores (_), and hyphens (-). The name must start with a letter but cannot start with http:// or https://.

myFlowlog
FlowLogIdstringNo

The ID of the flow log.

flowlog-m5evbtbpt****
DescriptionstringNo

The description of the flow log.

The description must be 2 to 256 characters in length. It must start with a letter but cannot start with http:// or https://.

myFlowlog
CenIdstringNo

The ID of the Cloud Enterprise Network (CEN) instance.

cen-7qthudw0ll6jmc****
ProjectNamestringNo

The name of the project where the flow log is stored.

The name must be 3 to 63 characters in length, and can contain lowercase letters, digits, and hyphens (-). It must start or end with a lowercase letter or a digit.

FlowLogProject
LogStoreNamestringNo

The name of the Logstore where the flow log is stored.

The name must be 3 to 63 characters in length, and can contain lowercase letters, digits, underscores (_), and hyphens (-). It must start or end with a lowercase letter or a digit.

FlowLogStore
StatusstringNo

The status of the flow log. Valid values:

  • Active: The flow log is enabled.
  • Inactive: The flow log is disabled.
Active
PageNumberintegerNo

The page number. Default value: 1.

1
PageSizeintegerNo

The number of entries per page. Minimum value: 1. Default value: 20.

20
Tagobject []No

The information about the tags.

You can specify at most 20 tags in each call.

KeystringNo

The tag key.

The tag key cannot be an empty string. The tag key can be up to 64 characters in length and cannot start with acs: or aliyun. It cannot contain http:// or https://.

You can specify at most 20 tag keys.

TagKey
ValuestringNo

The tag value.

The tag value can be 0 to 128 characters in length, and cannot start with aliyun or acs:. It cannot contain http:// or https://.

Each tag key must have a unique tag value. You can specify at most 20 tag values in each call.

TagValue
TransitRouterAttachmentIdstringNo

The ID of the network instance connection.

tr-attach-qieks13jnt1cchy****

Response parameters

ParameterTypeDescriptionExample
object

The response.

PageSizestring

The number of entries returned per page.

20
PageNumberstring

The page number of the returned page.

1
RequestIdstring

The ID of the request.

F7DDDC17-FA06-4AC2-8F35-59D2470FCFC1
TotalCountstring

The total number of entries returned.

1
Successstring

Indicates whether the call is successful. Valid values:

  • true: yes
  • false: no
true
FlowLogsobject []

A list of flow logs.

Statusstring

The status of the flow log. Valid values:

  • Active: The flow log is enabled.
  • Inactive: The flow log is disabled.
Active
CreationTimestring

The time when the flow log was created.

The time follows the ISO 8601 standard in the YYYY-MM-DDThh:mm:ssZ format. The time is displayed in UTC.

2021-07-24T13:00:52Z
FlowLogNamestring

The name of the flow log.

myFlowlog
Descriptionstring

The description of the flow log.

myFlowlog
ProjectNamestring

The name of the project where the flow log is stored.

FlowLogProject
CenIdstring

The ID of the CEN instance.

cen-7qthudw0ll6jmc****
LogStoreNamestring

The name of the Logstore where the flow log is stored.

FlowLogStore
RegionIdstring

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

cn-hangzhou
FlowLogIdstring

The ID of the flow log.

flowlog-m5evbtbpt****
TransitRouterAttachmentIdstring

The ID of the network instance connection.

tr-attach-5x4o4ynzuqbv6g****
Intervallong

The time window for collecting log data. Unit: seconds. Valid values: 60 and 600. Default value: 600.

60
Tagsobject []

A list of tags.

Keystring

The tag key.

TagKey
Valuestring

The tag value.

TagValue

Examples

Sample success responses

JSONformat

{
  "PageSize": "20",
  "PageNumber": "1",
  "RequestId": "F7DDDC17-FA06-4AC2-8F35-59D2470FCFC1",
  "TotalCount": "1",
  "Success": "true",
  "FlowLogs": {
    "FlowLog": [
      {
        "Status": "Active",
        "CreationTime": "2021-07-24T13:00:52Z",
        "FlowLogName": "myFlowlog",
        "Description": "myFlowlog",
        "ProjectName": "FlowLogProject",
        "CenId": "cen-7qthudw0ll6jmc****",
        "LogStoreName": "FlowLogStore",
        "RegionId": "cn-hangzhou",
        "FlowLogId": "flowlog-m5evbtbpt****",
        "TransitRouterAttachmentId": "tr-attach-5x4o4ynzuqbv6g****",
        "Interval": 60,
        "Tags": {
          "Tag": [
            {
              "Key": "TagKey",
              "Value": "TagValue"
            }
          ]
        }
      }
    ]
  }
}

Error codes

HTTP status codeError codeError messageDescription
400OperationUnsupported.actionThis action is not support.The error message returned because this operation is not supported in the specified region.
400InvalidFlowlogId.NotFoundThe specified flowlog id does not exist or does not match the cen Id.The error message returned because the specified flow log does not exist.
400IllegalParam.TagValueThe tag values are not valid.The error message returned because the specified tag value is invalid.
400IllegalParam.TagKeyThe tag keys are not valid.The error message returned because the specified tag key is invalid.
400InvalidDescriptionDescription is invalid.The error message returned because the description is invalid.
400InvalidNameName is invalid.The error message returned because the specified name is invalid.
400InvalidParameterInvalid parameter.The error message returned because the parameter is set to an invalid value.
400UnauthorizedThe AccessKeyId is unauthorized.The error message returned because you do not have the permissions to perform this operation.

For a list of error codes, visit the Service error codes.

Change history

Change timeSummary of changesOperation
2023-12-13The Error code has changedsee changesets
Change itemChange content
Error CodesThe Error code has changed.
    Error Codes 400 change
2023-01-09The Error code has changed. The response structure of the API has changedsee changesets
Change itemChange content
Error CodesThe Error code has changed.
    delete Error Codes: 400
Output ParametersThe response structure of the API has changed.
2022-12-02The Error code has changed. The request parameters of the API has changedsee changesets
Change itemChange content
Error CodesThe Error code has changed.
    delete Error Codes: 400
Input ParametersThe request parameters of the API has changed.
    Added Input Parameters: TransitRouterAttachmentId
2022-09-14The Error code has changedsee changesets
Change itemChange content
Error CodesThe Error code has changed.
    delete Error Codes: 400
2022-09-14The Error code has changedsee changesets
Change itemChange content
Error CodesThe Error code has changed.
    delete Error Codes: 400