Examples#
Index > LaunchWizard > Examples
Auto-generated documentation for LaunchWizard type annotations stubs module types-boto3-launch-wizard.
Client#
Implicit type annotations#
Can be used with types-boto3[launch-wizard]
package installed.
Write your LaunchWizard
code as usual,
type checking and code completion should work out of the box.
# LaunchWizardClient usage example
from boto3.session import Session
session = Session()
client = session.client("launch-wizard") # (1)
result = client.create_deployment() # (2)
- client: LaunchWizardClient
- result: CreateDeploymentOutputTypeDef
# ListDeploymentEventsPaginator usage example
from boto3.session import Session
session = Session()
client = session.client("launch-wizard") # (1)
paginator = client.get_paginator("list_deployment_events") # (2)
for item in paginator.paginate(...):
print(item) # (3)
- client: LaunchWizardClient
- paginator: ListDeploymentEventsPaginator
- item: ListDeploymentEventsOutputTypeDef
Explicit type annotations#
With types-boto3-lite[launch-wizard]
or a standalone types_boto3_launch_wizard
package, you have to explicitly specify client: LaunchWizardClient
type annotation.
All other type annotations are optional, as types should be discovered automatically. However, these type annotations can be helpful in your functions and methods.
# LaunchWizardClient usage example with type annotations
from boto3.session import Session
from types_boto3_launch_wizard.client import LaunchWizardClient
from types_boto3_launch_wizard.type_defs import CreateDeploymentOutputTypeDef
from types_boto3_launch_wizard.type_defs import CreateDeploymentInputRequestTypeDef
session = Session()
client: LaunchWizardClient = session.client("launch-wizard")
kwargs: CreateDeploymentInputRequestTypeDef = {...}
result: CreateDeploymentOutputTypeDef = client.create_deployment(**kwargs)
# ListDeploymentEventsPaginator usage example with type annotations
from boto3.session import Session
from types_boto3_launch_wizard.client import LaunchWizardClient
from types_boto3_launch_wizard.paginator import ListDeploymentEventsPaginator
from types_boto3_launch_wizard.type_defs import ListDeploymentEventsOutputTypeDef
session = Session()
client: LaunchWizardClient = session.client("launch-wizard")
paginator: ListDeploymentEventsPaginator = client.get_paginator("list_deployment_events")
for item in paginator.paginate(...):
item: ListDeploymentEventsOutputTypeDef
print(item)