Examples#
Auto-generated documentation for AppRunner type annotations stubs module types-boto3-apprunner.
Client#
Implicit type annotations#
Can be used with types-boto3[apprunner]
package installed.
Write your AppRunner
code as usual,
type checking and code completion should work out of the box.
# AppRunnerClient usage example
from boto3.session import Session
session = Session()
client = session.client("apprunner") # (1)
result = client.associate_custom_domain() # (2)
- client: AppRunnerClient
- result: AssociateCustomDomainResponseTypeDef
Explicit type annotations#
With types-boto3-lite[apprunner]
or a standalone types_boto3_apprunner
package, you have to explicitly specify client: AppRunnerClient
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.
# AppRunnerClient usage example with type annotations
from boto3.session import Session
from types_boto3_apprunner.client import AppRunnerClient
from types_boto3_apprunner.type_defs import AssociateCustomDomainResponseTypeDef
from types_boto3_apprunner.type_defs import AssociateCustomDomainRequestRequestTypeDef
session = Session()
client: AppRunnerClient = session.client("apprunner")
kwargs: AssociateCustomDomainRequestRequestTypeDef = {...}
result: AssociateCustomDomainResponseTypeDef = client.associate_custom_domain(**kwargs)