saastraffic-by-cust

The following shows how to generate the saastraffic-by-cust report using either the Reporting API's Generate a report POST operation or the Get a cacheable report GET operation. Details about each report's supported products, metrics, filters, and available data intervals are also available dynamically by running the API's Get a report type operation, also shown below. See also other available reports.

Report definition

Provides traffic data at a SaaS customer level. This report only produces daily data.

Business object: cpcode

Data available for: 90 days

Required products: SaaS Provider Option

Available metrics

MetricDescription
Data metrics
edgeBytesTotalThe total volume of edge traffic for given objects and filters.
edgeHitsTotalThe total number of edge requests for given objects and filters.
midgressBytesTotalThe total volume for the amount of internal API traffic exchanged between Akamai edge servers.Y
midgressHitsTotalAll hits with all response codes delivered from Akamai's Tiered Distribution network, that is bytes served from the Akamai Tiered Distribution infrastructure to edge servers.

Available filters

FilterTypeDescription
Optional filters
appidStringThe ID for a SaaS application that you have configured for a specific contract using the SaaS Definitions Property Manager Behavior. Limits results to a specific set of SaaS customers.
http_methodEnumerationA request method indicating the action performed on a resource.
incl_putpost: Includes data from PUT and POST requests.
download: Includes data from download requests.
upload: Includes data from upload requests.
excl_putpost_req: Excludes data from PUT and POST requests.
ip_versionEnumerationThe IP for which the report is shown.
ipv4: IP address in v4 format.
ipv6: IP address in v6 format.
traffic_typeEnumerationSupported array values are standard_secure and non_secure.
standard_secure: Standard secure delivery.
non_secure: Non secure delivery.

POST request

POST /reporting-api/v1/reports/saastraffic-by-cust/versions/1/report-data{?start,​end}

Sample: /reporting-api/v1/reports/saastraffic-by-cust/versions/1/report-data?start​=2020-05-01T00%3A00%3A00Z​&end​=2020-06-01T00%3A00%3A00Z

Query parameters

ParameterTypeSampleDescription
Required
startString2020-05-01T00:00:00ZSpecifies the start of the reported period as an ISO-8601 timestamp with optional time zone. The report includes data that matches the start value's timestamp.
endString2020-06-01T00:00:00ZSpecifies the end of the reported period as an ISO-8601 timestamp with optional time zone. The report excludes any data that matches the end value's timestamp.

JSON request members

MemberTypeDescription
objectIdsArraySpecifies the set of cpcode values you want to report on.
objectIdsEnumerationAs an alternative to an array of ID values, specify all as a string for unfiltered data. Either way, objectIds is required.
metricsArrayThe set of desired metrics. If omitted, the report includes all available metrics.
filtersMap of arraysSpecifies a set of custom filters, with each filter's name keying an array with each filter's set of values.

Request body:

{
    "objectIds": [
        "55232",
        "23433",
        "32433"
    ],
    "metrics": [
        "edgeBytesTotal",
        "edgeHitsTotal",
        "midgressBytesTotal",
        "midgressHitsTotal"
    ],
    "filters": {
        "appid": [
            "577597",
            "577596"
        ],
        "http_method": [
            "patch",
            "put"
        ],
        "ip_version": [
            "ipv4",
            "ipv6"
        ],
        "traffic_type": [
            "standard_secure",
            "non_secure"
        ]
    }
}

GET request

GET /reporting-api/v1/reports/saastraffic-by-cust/versions/1/report-data{?start,​end,​objectIds,​allObjectIds,​metrics,​filters}

Sample: /reporting-api/v1/reports/saastraffic-by-cust/versions/1/report-data?start​=2020-05-01T00%3A00%3A00Z​&end​=2020-06-01T00%3A00%3A00Z​&objectIds​=55232,​23433,​32433​&metrics​=edgeBytesTotal%2CedgeHitsTotal​&filters​=appid%3D577596%2Cappid%3D577597%2Chttp_method%3Ddelete%2Chttp_method%3Dpost

Query parameters

ParameterTypeSampleDescription
Required
startString2022-06-23T13:55:00ZSpecifies the start of the reported period as an ISO-8601 timestamp with optional time zone. The report includes data that matches the start value’s timestamp.
endString2022-06-23T14:15:00ZSpecifies the end of the reported period as an ISO-8601 timestamp with optional time zone. The report excludes any data that matches the end value’s timestamp.
Optional
allObjectIdsBooleantrueAs an alternative to objectIds, enabling this generates a report that includes all IDs available for the cpcode objectType. This parameter is ignored if the request also specifies a set of objectIds.
objectIdsString55232,​23433,​32433As an alternative to allObjectIds, specifies the set of unique IDs for the cpcode objectType you want to report on, formatted as a comma-delimited list.
metricsStringedgeBytesTotal,​edgeHitsTotalSpecifies a comma-separated list of metrics to include in the report, otherwise all metrics if omitted. The set of available metrics depends on the type of report. URL-encode the entire value in the GET request.
filtersStringappid=​577596,​appid=​577597,​http_method=​delete,​http_method=​postSpecifies criteria to filter the report's data. The set of available filters depends on the type of report. Separate each filter name and value with an equals (=) character, and separate various name/value pairs with commas (,). To specify more than one filter value, repeat the filter name. See the accompanying example for guidance. URL-encode the entire value in the GET request.

JSON response

Status 200 application/json

Response body:

{
    "metadata": {
        "name": "saastraffic-by-cust",
        "version": "1",
        "outputType": "FLAT",
        "groupBy": [
            "custid"
        ],
        "start": "2020-05-01T00:00:00Z",
        "end": "2020-06-01T00:00:00Z",
        "availableDataEnds": null,
        "suggestedRetryTime": null,
        "rowCount": 4,
        "filters": [
            {
                "name": "appid",
                "values": [
                    "577599",
                    "577596"
                ]
            },
            {
                "name": "http_method",
                "values": [
                    "post",
                    "get"
                ]
            },
            {
                "name": "ip_version",
                "values": [
                    "ipv4",
                    "ipv6"
                ]
            },
            {
                "name": "traffic_type",
                "values": [
                    "standard_secure",
                    "non_secure"
                ]
            }
        ],
        "columns": [
            {
                "name": "groupBy",
                "label": "custid"
            },
            {
                "name": "edgeBytesTotal",
                "label": "Edge Bytes"
            },
            {
                "name": "edgeHitsTotal",
                "label": "Edge Hits"
            },
            {
                "name": "midgressBytesTotal",
                "label": "Midgress Bytes"
            },
            {
                "name": "midgressHitsTotal",
                "label": "Midgress Hits"
            }
        ],
        "objectType": "cpcode",
        "objectIds": [
            "55232",
            "23433",
            "32433"
        ]
    },
    "data": [
        {
            "custid": "577595",
            "edgeBytesTotal": "596",
            "edgeHitsTotal": "2393",
            "midgressBytesTotal": "1218",
            "midgressHitsTotal": "4887"
        },
        {
            "custid": "577598",
            "edgeBytesTotal": "3927",
            "edgeHitsTotal": "2108",
            "midgressBytesTotal": "4040",
            "midgressHitsTotal": "3984"
        },
        {
            "custid": "577597",
            "edgeBytesTotal": "4750",
            "edgeHitsTotal": "2350",
            "midgressBytesTotal": "1786",
            "midgressHitsTotal": "2999"
        },
        {
            "custid": "577599",
            "edgeBytesTotal": "1480",
            "edgeHitsTotal": "254",
            "midgressBytesTotal": "3927",
            "midgressHitsTotal": "4294"
        }
    ],
    "summaryStatistics": {}
}

CSV response

Status 200 text/csv

Response Body:

#METADATA_START
name,​saastraffic-by-cust
version,​1
source,​saastraffic-by-cust/versions/1
groupBy,​custid
start,​2020-05-01T00:00:00Z
end,​2020-06-01T00:00:00Z
availableDataEnds,
suggestedRetryTime,
rowCount,​4
objectType,​cpcode
objectIds,​55232,​23433,​32433
appid,​577599,​577596
http_method,​post,​get
ip_version,​ipv4,​ipv6
traffic_type,​standard_secure,​non_secure
#METADATA_END

#SUMMARYSTATISTICS_START

#SUMMARYSTATISTICS_END

#COLUMNS_START
custid,​edgeBytesTotal,​edgeHitsTotal,​midgressBytesTotal,​midgressHitsTotal
#COLUMNS_END

#DATA_START
577595,​596,​2393,​1218,​4887
577598,​3927,​2108,​4040,​3984
577597,​4750,​2350,​1786,​2999
577599,​1480,​254,​3927,​4294
#DATA_END

Get report details

This sample Get a report type operation gets the same information you need to run the saastraffic-by-cust report as provided in this reference documentation, but available dynamically to your API client application.

GET /reporting-api/v1/reports/saastraffic-by-cust/versions/1

Status 200 application/json

Response body:

{
    "name": "saastraffic-by-cust",
    "description": "Provides traffic data at a SaaS customer level. This report only produces daily data.",
    "businessObjectName": "cpcode",
    "version": 1,
    "status": "PUBLISHED",
    "deprecated": false,
    "timeBased": false,
    "outputType": "FLAT",
    "requiredProducts": [
        "SaaS Provider Option"
    ],
    "requiredRoles": [
        "SaaS reports - View Only"
    ],
    "available": false,
    "metrics": [
        {
            "name": "midgressHitsTotal",
            "description": "All hits with all response codes delivered from Akamai's Tiered Distribution network, that is bytes served from the Akamai Tiered Distribution infrastructure to edge servers.",
            "label": "Midgress Hits",
            "unit": "COUNT",
            "summaryStatistic": false
        },
        {
            "name": "edgeHitsTotal",
            "description": "The total number of edge requests for given objects and filters.",
            "label": "Edge Hits",
            "unit": "COUNT",
            "summaryStatistic": false
        },
        {
            "name": "midgressBytesTotal",
            "description": "The total volume for the amount of internal API traffic exchanged between Akamai edge servers.Y",
            "label": "Midgress Bytes",
            "unit": "BYTE",
            "summaryStatistic": false
        },
        {
            "name": "edgeBytesTotal",
            "description": "The total volume of edge traffic for given objects and filters.",
            "label": "Edge Bytes",
            "unit": "BYTE",
            "summaryStatistic": false
        }
    ],
    "groupOutlyingValues": {
        "enabled": false
    },
    "groupBy": [
        "custid"
    ],
    "filters": [
        {
            "name": "appid",
            "type": "string",
            "description": "The ID for a SaaS application that you have configured for a specific contract using the SaaS Definitions Property Manager Behavior. Limits results to a specific set of SaaS customers.",
            "required": false
        },
        {
            "name": "ip_version",
            "type": "enum",
            "description": "The IP for which the report is shown.",
            "values": [
                {
                    "value": "ipv4",
                    "description": "IP address in v4 format."
                },
                {
                    "value": "ipv6",
                    "description": "IP address in v6 format."
                }
            ],
            "required": false
        },
        {
            "name": "traffic_type",
            "type": "enum",
            "description": "Supported array values are standard_secure and non_secure.",
            "values": [
                {
                    "value": "standard_secure",
                    "description": "Standard secure delivery."
                },
                {
                    "value": "non_secure",
                    "description": "Non secure delivery."
                }
            ],
            "required": false
        },
        {
            "name": "http_method",
            "type": "enum",
            "description": "A request method indicating the action performed on a resource. ",
            "values": [
                {
                    "value": "incl_putpost",
                    "description": "Includes data from PUT and POST requests."
                },
                {
                    "value": "download",
                    "description": "Includes data from download requests."
                },
                {
                    "value": "upload",
                    "description": "Includes data from upload requests."
                },
                {
                    "value": "excl_putpost_req",
                    "description": "Excludes data from PUT and POST requests."
                }
            ],
            "required": false
        }
    ],
    "intervals": [
        "MONTH",
        "WEEK",
        "DAY"
    ],
    "dataRetentionDays": 90,
    "links": [
        {
            "rel": "self",
            "href": "/reporting-api/v1/reports/saastraffic-by-cust/versions/1"
        },
        {
            "rel": "versions",
            "href": "/reporting-api/v1/reports/saastraffic-by-cust/versions"
        },
        {
            "rel": "all-reports",
            "href": "/reporting-api/v1/reports"
        },
        {
            "rel": "execute-report",
            "href": "/reporting-api/v1/reports/saastraffic-by-cust/versions/1/report-data"
        }
    ]
}