Registry /
type-stubs / mypy-boto3-payment-cryptography-data
Install & Compatibility
Where this runs
tested against v1.43.49 · pip install
no network on importno background threads
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
muslpy 3.10–3.95 runs
installs and imports cleanly · install 0.0s · import 0.624s · 51.9MB
glibcpy 3.10–3.95 runs
installs and imports cleanly · install 4.0s · import 0.574s · 52MB
50MB installed
● package 50MB
Code
Verified usage
Verified import paths — ran on the pinned version, not inferred.
PaymentCryptographyDataPlaneClient
✓ from mypy_boto3_payment_cryptography_data.client import PaymentCryptographyDataPlaneClient
ListKeysOutputTypeDef
✓ from mypy_boto3_payment_cryptography_data.type_defs import ListKeysOutputTypeDef
This quickstart demonstrates how to get a type-hinted `boto3` client for Payment Cryptography Data Plane and perform a basic operation, `list_keys`. Remember that `mypy-boto3-*` packages provide only type stubs, so `boto3` must be installed alongside for runtime functionality. Ensure AWS credentials are configured for successful execution.
import boto3
from mypy_boto3_payment_cryptography_data.client import PaymentCryptographyDataPlaneClient
from mypy_boto3_payment_cryptography_data.type_defs import (
ListKeysInputRequestTypeDef,
ListKeysOutputTypeDef
)
import os # For accessing environment variables for auth, if needed
# This package provides type stubs for boto3, not the actual client.
# Ensure boto3 is installed: pip install boto3
# AWS credentials and region should be configured (e.g., via ~/.aws/credentials, environment variables)
# For example, ensure AWS_ACCESS_KEY_ID, AWS_SECRET_ACCESS_KEY, AWS_SESSION_TOKEN, AWS_REGION are set or a profile is configured.
def get_payment_crypto_client() -> PaymentCryptographyDataPlaneClient:
"""Returns a type-hinted PaymentCryptographyDataPlane client."""
# boto3.client will automatically pick up credentials from environment variables or ~/.aws/credentials
return boto3.client(
"payment-cryptography-data",
region_name=os.environ.get("AWS_REGION", "us-east-1") # Example: use env var for region
)
client: PaymentCryptographyDataPlaneClient = get_payment_crypto_client()
# Example: List keys (replace with actual logic if needed)
# This operation requires appropriate IAM permissions (e.g., payment-cryptography:ListKeys)
try:
request: ListKeysInputRequestTypeDef = {"MaxResults": 5}
response: ListKeysOutputTypeDef = client.list_keys(**request)
print(f"Successfully called list_keys. Found {len(response.get('Keys', []))} keys.")
if response.get('Keys'):
print(f"First key ARN: {response['Keys'][0]['KeyArn']}")
except Exception as e:
print(f"Error listing keys: {e}")
print("\n--- Troubleshooting ---")
print("1. Ensure you have AWS credentials configured (environment variables or ~/.aws/credentials).")
print("2. Verify your IAM user/role has 'payment-cryptography:ListKeys' permission.")
print("3. Check the AWS region (e.g., 'us-east-1') is correct for your resources.")
print("\nThis quickstart primarily demonstrates type hinting; actual API calls require a valid AWS setup.")
Debug
Known issues
breakingStarting with `mypy-boto3-builder` version 8.12.0 (which generated this package), Python 3.8 is no longer supported. Projects using this package must upgrade to Python 3.9 or newer.fixUpgrade your Python environment to 3.9 or a later version.
affects: >=8.12.0 (builder)
breakingThe `mypy-boto3-builder` migrated to PEP 561 packages in version 8.12.0. This change primarily affects packaging and how type checkers locate stubs. While generally backward compatible, some custom build systems or older `mypy` versions might need configuration adjustments.fixEnsure your `mypy` configuration (e.g., `mypy.ini`) is up-to-date and that your build system correctly recognizes PEP 561 compliant packages.
affects: >=8.12.0 (builder)
gotchaThese packages (`mypy-boto3-*`) provide *only* type definitions for static analysis. They do not contain any runtime code and must be installed alongside the actual `boto3` library to function correctly.fixAlways install `boto3` (e.g., `pip install boto3 mypy-boto3-payment-cryptography-data`).
affects: all
breakingThe `mypy-boto3-builder` version 8.9.0 introduced breaking changes to `TypeDef` naming conventions, simplifying long names (e.g., `CreateDistributionRequestRequestTypeDef` to `CreateDistributionRequestTypeDef`). While this package is for 'payment-cryptography-data', similar changes may apply to its `TypeDef` structures.fixReview your code for `import` statements and usage of `*_TypeDef` classes after upgrading to ensure they match the new, potentially shorter names. Refer to the specific package's generated `type_defs.pyi` for exact names.
affects: >=8.9.0 (builder)
gotchaWhen instantiating the client with `boto3.client()`, the service name string `payment-cryptography-data` must be exact. Typographical errors will lead to `UnknownServiceError` at runtime and untyped clients.fixAlways use the correct service identifier string: `boto3.client("payment-cryptography-data")`. affects: all
Upgrade
Version history
1.43.49latest on PyPI · released Jul 15, 2026
Audit
Dependencies
boto3requiredThese are type stubs for boto3; boto3 itself is required for runtime functionality.