Skip to content

EventBridgeClient#

Index > EventBridge > EventBridgeClient

Auto-generated documentation for EventBridge type annotations stubs module mypy-boto3-events.

EventBridgeClient#

Type annotations and code completion for boto3.client("events"). boto3 documentation

# EventBridgeClient usage example

from boto3.session import Session
from mypy_boto3_events.client import EventBridgeClient

def get_events_client() -> EventBridgeClient:
    return Session().client("events")

Exceptions#

boto3 client exceptions are generated in runtime. This class provides code completion for boto3.client("events").exceptions structure.

# Exceptions.exceptions usage example

client = boto3.client("events")

try:
    do_something(client)
except (
    client.exceptions.ClientError,
    client.exceptions.ConcurrentModificationException,
    client.exceptions.IllegalStatusException,
    client.exceptions.InternalException,
    client.exceptions.InvalidEventPatternException,
    client.exceptions.InvalidStateException,
    client.exceptions.LimitExceededException,
    client.exceptions.ManagedRuleException,
    client.exceptions.OperationDisabledException,
    client.exceptions.PolicyLengthExceededException,
    client.exceptions.ResourceAlreadyExistsException,
    client.exceptions.ResourceNotFoundException,
) as e:
    print(e)
# Exceptions.exceptions type checking example

from mypy_boto3_events.client import Exceptions

def handle_error(exc: Exceptions.ClientError) -> None:
    ...

Methods#

activate_event_source#

Activates a partner event source that has been deactivated.

Type annotations and code completion for boto3.client("events").activate_event_source method. boto3 documentation

# activate_event_source method definition

def activate_event_source(
    self,
    *,
    Name: str,
) -> EmptyResponseMetadataTypeDef:  # (1)
    ...
  1. See EmptyResponseMetadataTypeDef
# activate_event_source method usage example with argument unpacking

kwargs: ActivateEventSourceRequestRequestTypeDef = {  # (1)
    "Name": ...,
}

parent.activate_event_source(**kwargs)
  1. See ActivateEventSourceRequestRequestTypeDef

can_paginate#

Check if an operation can be paginated.

Type annotations and code completion for boto3.client("events").can_paginate method. boto3 documentation

# can_paginate method definition

def can_paginate(
    self,
    operation_name: str,
) -> bool:
    ...

cancel_replay#

Cancels the specified replay.

Type annotations and code completion for boto3.client("events").cancel_replay method. boto3 documentation

# cancel_replay method definition

def cancel_replay(
    self,
    *,
    ReplayName: str,
) -> CancelReplayResponseTypeDef:  # (1)
    ...
  1. See CancelReplayResponseTypeDef
# cancel_replay method usage example with argument unpacking

kwargs: CancelReplayRequestRequestTypeDef = {  # (1)
    "ReplayName": ...,
}

parent.cancel_replay(**kwargs)
  1. See CancelReplayRequestRequestTypeDef

close#

Closes underlying endpoint connections.

Type annotations and code completion for boto3.client("events").close method. boto3 documentation

# close method definition

def close(
    self,
) -> None:
    ...

create_api_destination#

Creates an API destination, which is an HTTP invocation endpoint configured as a target for events.

Type annotations and code completion for boto3.client("events").create_api_destination method. boto3 documentation

# create_api_destination method definition

def create_api_destination(
    self,
    *,
    Name: str,
    ConnectionArn: str,
    InvocationEndpoint: str,
    HttpMethod: ApiDestinationHttpMethodType,  # (1)
    Description: str = ...,
    InvocationRateLimitPerSecond: int = ...,
) -> CreateApiDestinationResponseTypeDef:  # (2)
    ...
  1. See ApiDestinationHttpMethodType
  2. See CreateApiDestinationResponseTypeDef
# create_api_destination method usage example with argument unpacking

kwargs: CreateApiDestinationRequestRequestTypeDef = {  # (1)
    "Name": ...,
    "ConnectionArn": ...,
    "InvocationEndpoint": ...,
    "HttpMethod": ...,
}

parent.create_api_destination(**kwargs)
  1. See CreateApiDestinationRequestRequestTypeDef

create_archive#

Creates an archive of events with the specified settings.

Type annotations and code completion for boto3.client("events").create_archive method. boto3 documentation

# create_archive method definition

def create_archive(
    self,
    *,
    ArchiveName: str,
    EventSourceArn: str,
    Description: str = ...,
    EventPattern: str = ...,
    RetentionDays: int = ...,
) -> CreateArchiveResponseTypeDef:  # (1)
    ...
  1. See CreateArchiveResponseTypeDef
# create_archive method usage example with argument unpacking

kwargs: CreateArchiveRequestRequestTypeDef = {  # (1)
    "ArchiveName": ...,
    "EventSourceArn": ...,
}

parent.create_archive(**kwargs)
  1. See CreateArchiveRequestRequestTypeDef

create_connection#

Creates a connection.

Type annotations and code completion for boto3.client("events").create_connection method. boto3 documentation

# create_connection method definition

def create_connection(
    self,
    *,
    Name: str,
    AuthorizationType: ConnectionAuthorizationTypeType,  # (1)
    AuthParameters: CreateConnectionAuthRequestParametersTypeDef,  # (2)
    Description: str = ...,
) -> CreateConnectionResponseTypeDef:  # (3)
    ...
  1. See ConnectionAuthorizationTypeType
  2. See CreateConnectionAuthRequestParametersTypeDef
  3. See CreateConnectionResponseTypeDef
# create_connection method usage example with argument unpacking

kwargs: CreateConnectionRequestRequestTypeDef = {  # (1)
    "Name": ...,
    "AuthorizationType": ...,
    "AuthParameters": ...,
}

parent.create_connection(**kwargs)
  1. See CreateConnectionRequestRequestTypeDef

create_endpoint#

Creates a global endpoint.

Type annotations and code completion for boto3.client("events").create_endpoint method. boto3 documentation

# create_endpoint method definition

def create_endpoint(
    self,
    *,
    Name: str,
    RoutingConfig: RoutingConfigTypeDef,  # (1)
    EventBuses: Sequence[EndpointEventBusTypeDef],  # (2)
    Description: str = ...,
    ReplicationConfig: ReplicationConfigTypeDef = ...,  # (3)
    RoleArn: str = ...,
) -> CreateEndpointResponseTypeDef:  # (4)
    ...
  1. See RoutingConfigTypeDef
  2. See EndpointEventBusTypeDef
  3. See ReplicationConfigTypeDef
  4. See CreateEndpointResponseTypeDef
# create_endpoint method usage example with argument unpacking

kwargs: CreateEndpointRequestRequestTypeDef = {  # (1)
    "Name": ...,
    "RoutingConfig": ...,
    "EventBuses": ...,
}

parent.create_endpoint(**kwargs)
  1. See CreateEndpointRequestRequestTypeDef

create_event_bus#

Creates a new event bus within your account.

Type annotations and code completion for boto3.client("events").create_event_bus method. boto3 documentation

# create_event_bus method definition

def create_event_bus(
    self,
    *,
    Name: str,
    EventSourceName: str = ...,
    Description: str = ...,
    KmsKeyIdentifier: str = ...,
    DeadLetterConfig: DeadLetterConfigTypeDef = ...,  # (1)
    Tags: Sequence[TagTypeDef] = ...,  # (2)
) -> CreateEventBusResponseTypeDef:  # (3)
    ...
  1. See DeadLetterConfigTypeDef
  2. See TagTypeDef
  3. See CreateEventBusResponseTypeDef
# create_event_bus method usage example with argument unpacking

kwargs: CreateEventBusRequestRequestTypeDef = {  # (1)
    "Name": ...,
}

parent.create_event_bus(**kwargs)