Inspector2 / Client / list_usage_totals
list_usage_totals¶
- Inspector2.Client.list_usage_totals(**kwargs)¶
Lists the Amazon Inspector usage totals over the last 30 days.
See also: AWS API Documentation
Request Syntax
response = client.list_usage_totals( maxResults=123, nextToken='string', accountIds=[ 'string', ] )
- Parameters:
maxResults (integer) – The maximum number of results the response can return. If your request would return more than the maximum the response will return a
nextToken
value, use this value when you call the action again to get the remaining results.nextToken (string) – A token to use for paginating results that are returned in the response. Set the value of this parameter to null for the first request to a list action. If your response returns more than the
maxResults
maximum value it will also return anextToken
value. For subsequent calls, use thenextToken
value returned from the previous request to continue listing results after the first page.accountIds (list) –
The Amazon Web Services account IDs to retrieve usage totals for.
(string) –
- Return type:
dict
- Returns:
Response Syntax
{ 'nextToken': 'string', 'totals': [ { 'accountId': 'string', 'usage': [ { 'type': 'EC2_INSTANCE_HOURS'|'ECR_INITIAL_SCAN'|'ECR_RESCAN'|'LAMBDA_FUNCTION_HOURS'|'LAMBDA_FUNCTION_CODE_HOURS'|'CODE_REPOSITORY_SAST'|'CODE_REPOSITORY_IAC'|'CODE_REPOSITORY_SCA'|'EC2_AGENTLESS_INSTANCE_HOURS', 'total': 123.0, 'estimatedMonthlyCost': 123.0, 'currency': 'USD' }, ] }, ] }
Response Structure
(dict) –
nextToken (string) –
The pagination parameter to be used on the next list operation to retrieve more items.
totals (list) –
An object with details on the total usage for the requested account.
(dict) –
The total of usage for an account ID.
accountId (string) –
The account ID of the account that usage data was retrieved for.
usage (list) –
An object representing the total usage for an account.
(dict) –
Contains usage information about the cost of Amazon Inspector operation.
type (string) –
The type scan.
total (float) –
The total of usage.
estimatedMonthlyCost (float) –
The estimated monthly cost of Amazon Inspector.
currency (string) –
The currency type used when calculating usage data.
Exceptions