Skip to main content
POST
/
network_flow_reports
Create network flow report
curl --request POST \
  --url https://api.vantage.sh/v2/network_flow_reports \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "workspace_token": "<string>",
  "title": "<string>",
  "filter": "<string>",
  "start_date": "2023-12-25",
  "end_date": "2023-12-25",
  "date_interval": "last_3_days",
  "groupings": [
    "account_id"
  ],
  "flow_direction": "ingress",
  "flow_weight": "costs"
}
'
{
  "token": "ntflw_lg_rprt_c6107e302cb8723e",
  "title": "title",
  "default": false,
  "created_at": "2025-01-31T20:40:46Z",
  "workspace_token": "wrkspc_0aa4a5d5a5fc2608",
  "created_by_token": "team_ed7fb90535f87b9f",
  "start_date": "2025-01-24",
  "end_date": "2025-01-30",
  "date_interval": "last_7_days",
  "groupings": "resource_uuid,traffic_category,peer_resource_uuid",
  "flow_direction": null,
  "flow_weight": "costs",
  "filter": "network_flow_logs.traffic_category = 'cross_az'"
}

Authorizations

Authorization
string
header
required

The access token received from the authorization server in the OAuth 2.0 flow.

Body

application/json

Create a NetworkFlowReport.

workspace_token
string
required

The Workspace in which the NetworkFlowReport will be created.

title
string
required

The title of the NetworkFlowReport.

filter
string

The filter query language to apply to the NetworkFlowReport. Additional documentation available at https://docs.vantage.sh/vql.

start_date
string<date>

The start date of the NetworkFlowReport. YYYY-MM-DD formatted. Incompatible with 'date_interval' parameter.

end_date
string<date>

The end date of the NetworkFlowReport. YYYY-MM-DD formatted. Incompatible with 'date_interval' parameter.

date_interval
enum<string>

The date interval of the NetworkFlowReport. Unless 'custom' is used, this is incompatible with 'start_date' and 'end_date' parameters. Defaults to 'last_7_days'.

Available options:
last_3_days,
last_7_days,
custom
groupings
enum<string>[]

Grouping values for aggregating data on the NetworkFlowReport. Valid groupings: account_id, az_id, dstaddr, dsthostname, flow_direction, interface_id, instance_id, peer_resource_uuid, peer_account_id, peer_vpc_id, peer_region, peer_az_id, peer_subnet_id, peer_interface_id, peer_instance_id, region, resource_uuid, srcaddr, srchostname, subnet_id, traffic_category, traffic_path, vpc_id.

Available options:
account_id,
az_id,
dstaddr,
dsthostname,
flow_direction,
interface_id,
instance_id,
peer_resource_uuid,
peer_account_id,
peer_vpc_id,
peer_region,
peer_az_id,
peer_subnet_id,
peer_interface_id,
peer_instance_id,
region,
resource_uuid,
srcaddr,
srchostname,
subnet_id,
traffic_category,
traffic_path,
vpc_id
flow_direction
enum<string>

The flow direction of the NetworkFlowReport.

Available options:
ingress,
egress
flow_weight
enum<string>

The dimension by which the logs in the report are sorted. Defaults to costs.

Available options:
costs,
bytes

Response

NetworkFlowReport model

token
string
title
string

The title of the NetworkFlowReport.

Example:

"Public Traffic Destinations"

default
boolean

Indicates whether the NetworkFlowReport is the default report.

created_at
string

The date and time, in UTC, the report was created. ISO 8601 Formatted.

Example:

"2024-03-19T00:00:00Z"

workspace_token
string

The token for the Workspace the NetworkFlowReport is a part of.

created_by_token
string

The token for the User or Team that created this NetworkFlowReport.

start_date
string

The start date for the NetworkFlowReport. Only set for custom date ranges. ISO 8601 Formatted.

Example:

"2024-03-01"

end_date
string

The end date for the NetworkFlowReport. Only set for custom date ranges. ISO 8601 Formatted.

Example:

"2024-03-20"

date_interval
string

The date range for the NetworkFlowReport. Only present if a custom date range is not specified.

Example:

"last_month"

groupings
string

The grouping aggregations applied to the filtered data.

Example:

"cost_type, tag:account"

flow_direction
string

The flow weight of the NetworkFlowReport. Possible values: costs, bytes.

Example:

"ingress"

flow_weight
string

The flow weight of the NetworkFlowReport. Possible values: costs, bytes.

Example:

"costs"

filter
string

The filter applied to the NetworkFlowReport. Additional documentation available at https://docs.vantage.sh/vql.