GuardDutyClient#
Auto-generated documentation for GuardDuty type annotations stubs module mypy-boto3-guardduty.
GuardDutyClient#
Type annotations and code completion for boto3.client("guardduty")
.
boto3 documentation
# GuardDutyClient usage example
from boto3.session import Session
from mypy_boto3_guardduty.client import GuardDutyClient
def get_guardduty_client() -> GuardDutyClient:
return Session().client("guardduty")
Exceptions#
boto3
client exceptions are generated in runtime.
This class provides code completion for boto3.client("guardduty").exceptions
structure.
# Exceptions.exceptions usage example
client = boto3.client("guardduty")
try:
do_something(client)
except (
client.exceptions.AccessDeniedException,
client.exceptions.BadRequestException,
client.exceptions.ClientError,
client.exceptions.ConflictException,
client.exceptions.InternalServerErrorException,
) as e:
print(e)
# Exceptions.exceptions type checking example
from mypy_boto3_guardduty.client import Exceptions
def handle_error(exc: Exceptions.AccessDeniedException) -> None:
...
Methods#
accept_administrator_invitation#
Accepts the invitation to be a member account and get monitored by a GuardDuty administrator account that sent the invitation.
Type annotations and code completion for boto3.client("guardduty").accept_administrator_invitation
method.
boto3 documentation
# accept_administrator_invitation method definition
def accept_administrator_invitation(
self,
*,
DetectorId: str,
AdministratorId: str,
InvitationId: str,
) -> Dict[str, Any]:
...
# accept_administrator_invitation method usage example with argument unpacking
kwargs: AcceptAdministratorInvitationRequestRequestTypeDef = { # (1)
"DetectorId": ...,
"AdministratorId": ...,
"InvitationId": ...,
}
parent.accept_administrator_invitation(**kwargs)
accept_invitation#
Accepts the invitation to be monitored by a GuardDuty administrator account.
Type annotations and code completion for boto3.client("guardduty").accept_invitation
method.
boto3 documentation
# accept_invitation method definition
def accept_invitation(
self,
*,
DetectorId: str,
MasterId: str,
InvitationId: str,
) -> Dict[str, Any]:
...
# accept_invitation method usage example with argument unpacking
kwargs: AcceptInvitationRequestRequestTypeDef = { # (1)
"DetectorId": ...,
"MasterId": ...,
"InvitationId": ...,
}
parent.accept_invitation(**kwargs)
archive_findings#
Archives GuardDuty findings that are specified by the list of finding IDs.
Type annotations and code completion for boto3.client("guardduty").archive_findings
method.
boto3 documentation
# archive_findings method definition
def archive_findings(
self,
*,
DetectorId: str,
FindingIds: Sequence[str],
) -> Dict[str, Any]:
...
# archive_findings method usage example with argument unpacking
kwargs: ArchiveFindingsRequestRequestTypeDef = { # (1)
"DetectorId": ...,
"FindingIds": ...,
}
parent.archive_findings(**kwargs)
can_paginate#
Check if an operation can be paginated.
Type annotations and code completion for boto3.client("guardduty").can_paginate
method.
boto3 documentation
# can_paginate method definition
def can_paginate(
self,
operation_name: str,
) -> bool:
...
close#
Closes underlying endpoint connections.
Type annotations and code completion for boto3.client("guardduty").close
method.
boto3 documentation
# close method definition
def close(
self,
) -> None:
...
create_detector#
Creates a single Amazon GuardDuty detector.
Type annotations and code completion for boto3.client("guardduty").create_detector
method.
boto3 documentation
# create_detector method definition
def create_detector(
self,
*,
Enable: bool,
ClientToken: str = ...,
FindingPublishingFrequency: FindingPublishingFrequencyType = ..., # (1)
DataSources: DataSourceConfigurationsTypeDef = ..., # (2)
Tags: Mapping[str, str] = ...,
Features: Sequence[DetectorFeatureConfigurationTypeDef] = ..., # (3)
) -> CreateDetectorResponseTypeDef: # (4)
...
- See FindingPublishingFrequencyType
- See DataSourceConfigurationsTypeDef
- See DetectorFeatureConfigurationTypeDef
- See CreateDetectorResponseTypeDef
# create_detector method usage example with argument unpacking
kwargs: CreateDetectorRequestRequestTypeDef = { # (1)
"Enable": ...,
}
parent.create_detector(**kwargs)
create_filter#
Creates a filter using the specified finding criteria.
Type annotations and code completion for boto3.client("guardduty").create_filter
method.
boto3 documentation
# create_filter method definition
def create_filter(
self,
*,
DetectorId: str,
Name: str,
FindingCriteria: FindingCriteriaTypeDef, # (1)
Description: str = ...,
Action: FilterActionType = ..., # (2)
Rank: int = ...,
ClientToken: str = ...,
Tags: Mapping[str, str] = ...,
) -> CreateFilterResponseTypeDef: # (3)
...
# create_filter method usage example with argument unpacking
kwargs: CreateFilterRequestRequestTypeDef = { # (1)
"DetectorId": ...,
"Name": ...,
"FindingCriteria": ...,
}
parent.create_filter(**kwargs)
create_ip_set#
Creates a new IPSet, which is called a trusted IP list in the console user interface.
Type annotations and code completion for boto3.client("guardduty").create_ip_set
method.
boto3 documentation
# create_ip_set method definition
def create_ip_set(
self,
*,
DetectorId: str,
Name: str,
Format: IpSetFormatType, # (1)
Location: str,
Activate: bool,
ClientToken: str = ...,
Tags: Mapping[str, str] = ...,
) -> CreateIPSetResponseTypeDef: # (2)
...
# create_ip_set method usage example with argument unpacking
kwargs: CreateIPSetRequestRequestTypeDef = { # (1)
"DetectorId": ...,
"Name": ...,
"Format": ...,
"Location": ...,
"Activate": ...,
}
parent.create_ip_set(**kwargs)
create_members#
Creates member accounts of the current Amazon Web Services account by specifying a list of Amazon Web Services account IDs.
Type annotations and code completion for boto3.client("guardduty").create_members
method.
boto3 documentation
# create_members method definition
def create_members(
self,
*,
DetectorId: str,
AccountDetails: Sequence[AccountDetailTypeDef], # (1)
) -> CreateMembersResponseTypeDef: # (2)
...
# create_members method usage example with argument unpacking
kwargs: CreateMembersRequestRequestTypeDef = { # (1)
"DetectorId": ...,
"AccountDetails": ...,
}
parent.create_members(**kwargs)
create_publishing_destination#
Creates a publishing destination to export findings to.
Type annotations and code completion for boto3.client("guardduty").create_publishing_destination
method.
boto3 documentation
# create_publishing_destination method definition
def create_publishing_destination(
self,
*,
DetectorId: str,
DestinationType: DestinationTypeType, # (1)
DestinationProperties: DestinationPropertiesTypeDef, # (2)
ClientToken: str = ...,
) -> CreatePublishingDestinationResponseTypeDef: # (3)
...
- See DestinationTypeType
- See DestinationPropertiesTypeDef
- See CreatePublishingDestinationResponseTypeDef
# create_publishing_destination method usage example with argument unpacking
kwargs: CreatePublishingDestinationRequestRequestTypeDef = { # (1)
"DetectorId": ...,
"DestinationType": ...,
"DestinationProperties": ...,
}
parent.create_publishing_destination(**kwargs)
create_sample_findings#
Generates sample findings of types specified by the list of finding types.
Type annotations and code completion for boto3.client("guardduty").create_sample_findings
method.
boto3 documentation
# create_sample_findings method definition
def create_sample_findings(
self,
*,
DetectorId: str,
FindingTypes: Sequence[str] = ...,
) -> Dict[str, Any]:
...
# create_sample_findings method usage example with argument unpacking
kwargs: CreateSampleFindingsRequestRequestTypeDef = { # (1)
"DetectorId": ...,
}
parent.create_sample_findings(**kwargs)
create_threat_intel_set#
Creates a new ThreatIntelSet.
Type annotations and code completion for boto3.client("guardduty").create_threat_intel_set
method.
boto3 documentation
# create_threat_intel_set method definition
def create_threat_intel_set(
self,
*,
DetectorId: str,
Name: str,
Format: ThreatIntelSetFormatType, # (1)
Location: str,
Activate: bool,
ClientToken: str = ...,
Tags: Mapping[str, str] = ...,
) -> CreateThreatIntelSetResponseTypeDef: # (2)
...
# create_threat_intel_set method usage example with argument unpacking
kwargs: CreateThreatIntelSetRequestRequestTypeDef = { # (1)
"DetectorId": ...,
"Name": ...,
"Format": ...,
"Location": ...,
"Activate": ...,
}
parent.create_threat_intel_set(**kwargs)
decline_invitations#
Declines invitations sent to the current member account by Amazon Web Services accounts specified by their account IDs.
Type annotations and code completion for boto3.client("guardduty").decline_invitations
method.
boto3 documentation
# decline_invitations method definition
def decline_invitations(
self,
*,
AccountIds: Sequence[str],
) -> DeclineInvitationsResponseTypeDef: # (1)
...
# decline_invitations method usage example with argument unpacking
kwargs: DeclineInvitationsRequestRequestTypeDef = { # (1)
"AccountIds": ...,
}
parent.decline_invitations(**kwargs)
delete_detector#
Deletes an Amazon GuardDuty detector that is specified by the detector ID.
Type annotations and code completion for boto3.client("guardduty").delete_detector
method.
boto3 documentation
# delete_detector method definition
def delete_detector(
self,
*,
DetectorId: str,
) -> Dict[str, Any]:
...
# delete_detector method usage example with argument unpacking
kwargs: DeleteDetectorRequestRequestTypeDef = { # (1)
"DetectorId": ...,
}
parent.delete_detector(**kwargs)
delete_filter#
Deletes the filter specified by the filter name.
Type annotations and code completion for boto3.client("guardduty").delete_filter
method.
boto3 documentation
# delete_filter method definition
def delete_filter(
self,
*,
DetectorId: str,
FilterName: str,
) -> Dict[str, Any]:
...
# delete_filter method usage example with argument unpacking
kwargs: DeleteFilterRequestRequestTypeDef = { # (1)
"DetectorId": ...,
"FilterName": ...,
}
parent.delete_filter(**kwargs)
delete_invitations#
Deletes invitations sent to the current member account by Amazon Web Services accounts specified by their account IDs.
Type annotations and code completion for boto3.client("guardduty").delete_invitations
method.
boto3 documentation
# delete_invitations method definition
def delete_invitations(
self,
*,
AccountIds: Sequence[str],
) -> DeleteInvitationsResponseTypeDef: # (1)
...
# delete_invitations method usage example with argument unpacking
kwargs: DeleteInvitationsRequestRequestTypeDef = { # (1)
"AccountIds": ...,
}
parent.delete_invitations(**kwargs)
delete_ip_set#
Deletes the IPSet specified by the ipSetId
.
Type annotations and code completion for boto3.client("guardduty").delete_ip_set
method.
boto3 documentation
# delete_ip_set method definition
def delete_ip_set(
self,
*,
DetectorId: str,
IpSetId: str,
) -> Dict[str, Any]:
...
# delete_ip_set method usage example with argument unpacking
kwargs: DeleteIPSetRequestRequestTypeDef = { # (1)
"DetectorId": ...,
"IpSetId": ...,
}
parent.delete_ip_set(**kwargs)
delete_members#
Deletes GuardDuty member accounts (to the current GuardDuty administrator account) specified by the account IDs.
Type annotations and code completion for boto3.client("guardduty").delete_members
method.
boto3 documentation
# delete_members method definition
def delete_members(
self,
*,
DetectorId: str,
AccountIds: Sequence[str],
) -> DeleteMembersResponseTypeDef: # (1)
...
# delete_members method usage example with argument unpacking
kwargs: DeleteMembersRequestRequestTypeDef = { # (1)
"DetectorId": ...,
"AccountIds": ...,
}
parent.delete_members(**kwargs)
delete_publishing_destination#
Deletes the publishing definition with the specified destinationId
.
Type annotations and code completion for boto3.client("guardduty").delete_publishing_destination
method.
boto3 documentation
# delete_publishing_destination method definition
def delete_publishing_destination(
self,
*,
DetectorId: str,
DestinationId: str,
) -> Dict[str, Any]:
...
# delete_publishing_destination method usage example with argument unpacking
kwargs: DeletePublishingDestinationRequestRequestTypeDef = { # (1)
"DetectorId": ...,
"DestinationId": ...,
}
parent.delete_publishing_destination(**kwargs)
delete_threat_intel_set#
Deletes the ThreatIntelSet specified by the ThreatIntelSet ID.
Type annotations and code completion for boto3.client("guardduty").delete_threat_intel_set
method.
boto3 documentation
# delete_threat_intel_set method definition
def delete_threat_intel_set(
self,
*,
DetectorId: str,
ThreatIntelSetId: str,
) -> Dict[str, Any]:
...
# delete_threat_intel_set method usage example with argument unpacking
kwargs: DeleteThreatIntelSetRequestRequestTypeDef = { # (1)
"DetectorId": ...,
"ThreatIntelSetId": ...,
}
parent.delete_threat_intel_set(**kwargs)
describe_malware_scans#
Returns a list of malware scans.
Type annotations and code completion for boto3.client("guardduty").describe_malware_scans
method.
boto3 documentation
# describe_malware_scans method definition
def describe_malware_scans(
self,
*,
DetectorId: str,
NextToken: str = ...,
MaxResults: int = ...,
FilterCriteria: FilterCriteriaTypeDef = ..., # (1)
SortCriteria: SortCriteriaTypeDef = ..., # (2)
) -> DescribeMalwareScansResponseTypeDef: # (3)
...
# describe_malware_scans method usage example with argument unpacking
kwargs: DescribeMalwareScansRequestRequestTypeDef = { # (1)
"DetectorId": ...,
}
parent.describe_malware_scans(**kwargs)
describe_organization_configuration#
Returns information about the account selected as the delegated administrator for GuardDuty.
Type annotations and code completion for boto3.client("guardduty").describe_organization_configuration
method.
boto3 documentation
# describe_organization_configuration method definition
def describe_organization_configuration(
self,
*,
DetectorId: str,
MaxResults: int = ...,
NextToken: str = ...,
) -> DescribeOrganizationConfigurationResponseTypeDef: # (1)
...
# describe_organization_configuration method usage example with argument unpacking
kwargs: DescribeOrganizationConfigurationRequestRequestTypeDef = { # (1)
"DetectorId": ...,
}
parent.describe_organization_configuration(**kwargs)
describe_publishing_destination#
Returns information about the publishing destination specified by the provided
destinationId
.
Type annotations and code completion for boto3.client("guardduty").describe_publishing_destination
method.
boto3 documentation
# describe_publishing_destination method definition
def describe_publishing_destination(
self,
*,
DetectorId: str,
DestinationId: str,
) -> DescribePublishingDestinationResponseTypeDef: # (1)
...
# describe_publishing_destination method usage example with argument unpacking
kwargs: DescribePublishingDestinationRequestRequestTypeDef = { # (1)
"DetectorId": ...,
"DestinationId": ...,
}
parent.describe_publishing_destination(**kwargs)
disable_organization_admin_account#
Removes the existing GuardDuty delegated administrator of the organization.
Type annotations and code completion for boto3.client("guardduty").disable_organization_admin_account
method.
boto3 documentation
# disable_organization_admin_account method definition
def disable_organization_admin_account(
self,
*,
AdminAccountId: str,
) -> Dict[str, Any]:
...
# disable_organization_admin_account method usage example with argument unpacking
kwargs: DisableOrganizationAdminAccountRequestRequestTypeDef = { # (1)
"AdminAccountId": ...,
}
parent.disable_organization_admin_account(**kwargs)
disassociate_from_administrator_account#
Disassociates the current GuardDuty member account from its administrator account.
Type annotations and code completion for boto3.client("guardduty").disassociate_from_administrator_account
method.
boto3 documentation
# disassociate_from_administrator_account method definition
def disassociate_from_administrator_account(
self,
*,
DetectorId: str,
) -> Dict[str, Any]:
...
# disassociate_from_administrator_account method usage example with argument unpacking
kwargs: DisassociateFromAdministratorAccountRequestRequestTypeDef = { # (1)
"DetectorId": ...,
}
parent.disassociate_from_administrator_account(**kwargs)
disassociate_from_master_account#
Disassociates the current GuardDuty member account from its administrator account.
Type annotations and code completion for boto3.client("guardduty").disassociate_from_master_account
method.
boto3 documentation
# disassociate_from_master_account method definition
def disassociate_from_master_account(
self,
*,
DetectorId: str,
) -> Dict[str, Any]:
...
# disassociate_from_master_account method usage example with argument unpacking
kwargs: DisassociateFromMasterAccountRequestRequestTypeDef = { # (1)
"DetectorId": ...,
}
parent.disassociate_from_master_account(**kwargs)
disassociate_members#
Disassociates GuardDuty member accounts (from the current administrator account) specified by the account IDs.
Type annotations and code completion for boto3.client("guardduty").disassociate_members
method.
boto3 documentation
# disassociate_members method definition
def disassociate_members(
self,
*,
DetectorId: str,
AccountIds: Sequence[str],
) -> DisassociateMembersResponseTypeDef: # (1)
...
# disassociate_members method usage example with argument unpacking
kwargs: DisassociateMembersRequestRequestTypeDef = { # (1)
"DetectorId": ...,
"AccountIds": ...,
}
parent.disassociate_members(**kwargs)
enable_organization_admin_account#
Designates an Amazon Web Services account within the organization as your GuardDuty delegated administrator.
Type annotations and code completion for boto3.client("guardduty").enable_organization_admin_account
method.