Skip to content

Examples#

Index > MarketplaceReportingService > Examples

Auto-generated documentation for MarketplaceReportingService type annotations stubs module mypy-boto3-marketplace-reporting.

Client#

Implicit type annotations#

Can be used with boto3-stubs[marketplace-reporting] package installed.

Write your MarketplaceReportingService code as usual, type checking and code completion should work out of the box.

# MarketplaceReportingServiceClient usage example

from boto3.session import Session


session = Session()

client = session.client("marketplace-reporting")  # (1)
result = client.get_buyer_dashboard()  # (2)
  1. client: MarketplaceReportingServiceClient
  2. result: GetBuyerDashboardOutputTypeDef

Explicit type annotations#

With boto3-stubs-lite[marketplace-reporting] or a standalone mypy_boto3_marketplace_reporting package, you have to explicitly specify client: MarketplaceReportingServiceClient 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.

# MarketplaceReportingServiceClient usage example with type annotations

from boto3.session import Session

from mypy_boto3_marketplace_reporting.client import MarketplaceReportingServiceClient
from mypy_boto3_marketplace_reporting.type_defs import GetBuyerDashboardOutputTypeDef
from mypy_boto3_marketplace_reporting.type_defs import GetBuyerDashboardInputRequestTypeDef


session = Session()

client: MarketplaceReportingServiceClient = session.client("marketplace-reporting")

kwargs: GetBuyerDashboardInputRequestTypeDef = {...}
result: GetBuyerDashboardOutputTypeDef = client.get_buyer_dashboard(**kwargs)