GuardDuty / Client / get_organization_statistics

get_organization_statistics#

GuardDuty.Client.get_organization_statistics()#

Retrieves how many active member accounts have each feature enabled within GuardDuty. Only a delegated GuardDuty administrator of an organization can run this API.

When you create a new organization, it might take up to 24 hours to generate the statistics for the entire organization.

See also: AWS API Documentation

Request Syntax

response = client.get_organization_statistics()
Return type:

dict

Returns:

Response Syntax

{
    'OrganizationDetails': {
        'UpdatedAt': datetime(2015, 1, 1),
        'OrganizationStatistics': {
            'TotalAccountsCount': 123,
            'MemberAccountsCount': 123,
            'ActiveAccountsCount': 123,
            'EnabledAccountsCount': 123,
            'CountByFeature': [
                {
                    'Name': 'S3_DATA_EVENTS'|'EKS_AUDIT_LOGS'|'EBS_MALWARE_PROTECTION'|'RDS_LOGIN_EVENTS'|'EKS_RUNTIME_MONITORING'|'LAMBDA_NETWORK_LOGS'|'RUNTIME_MONITORING',
                    'EnabledAccountsCount': 123,
                    'AdditionalConfiguration': [
                        {
                            'Name': 'EKS_ADDON_MANAGEMENT'|'ECS_FARGATE_AGENT_MANAGEMENT'|'EC2_AGENT_MANAGEMENT',
                            'EnabledAccountsCount': 123
                        },
                    ]
                },
            ]
        }
    }
}

Response Structure

  • (dict) –

    • OrganizationDetails (dict) –

      Information about the statistics report for your organization.

      • UpdatedAt (datetime) –

        The timestamp at which the organization statistics was last updated. This is in UTC format.

      • OrganizationStatistics (dict) –

        Information about the GuardDuty coverage statistics for members in your Amazon Web Services organization.

        • TotalAccountsCount (integer) –

          Total number of accounts in your Amazon Web Services organization.

        • MemberAccountsCount (integer) –

          Total number of accounts in your Amazon Web Services organization that are associated with GuardDuty.

        • ActiveAccountsCount (integer) –

          Total number of active accounts in your Amazon Web Services organization that are associated with GuardDuty.

        • EnabledAccountsCount (integer) –

          Total number of accounts that have enabled GuardDuty.

        • CountByFeature (list) –

          Retrieves the coverage statistics for each feature.

          • (dict) –

            Information about the number of accounts that have enabled a specific feature.

            • Name (string) –

              Name of the feature.

            • EnabledAccountsCount (integer) –

              Total number of accounts that have enabled a specific feature.

            • AdditionalConfiguration (list) –

              Name of the additional configuration.

              • (dict) –

                Information about the coverage statistic for the additional configuration of the feature.

                • Name (string) –

                  Name of the additional configuration within a feature.

                • EnabledAccountsCount (integer) –

                  Total number of accounts that have enabled the additional configuration.

Exceptions