AWS SignerDataPlane Type Stubs for boto3

1.42.54 · active · verified Wed Apr 15

mypy-boto3-signer-data provides static type annotations for the `boto3` AWS SDK's SignerDataPlane service. It enhances developer experience by enabling comprehensive type checking, improved IDE auto-completion, and early error detection for `boto3` code interacting with AWS SignerDataPlane. The current version is 1.42.54, generated with `mypy-boto3-builder` 8.12.0, with active development following `boto3` updates and new AWS service releases.

Warnings

Install

Imports

Quickstart

This quickstart demonstrates how to use `mypy-boto3-signer-data` for type-hinting a `boto3` SignerDataPlane client and its response. The `TYPE_CHECKING` guard ensures that `mypy-boto3` is only a development dependency. It retrieves and prints a list of signing jobs.

import boto3
from typing import TYPE_CHECKING
import os

if TYPE_CHECKING:
    from mypy_boto3_signer_data.client import SignerDataPlaneClient
    from mypy_boto3_signer_data.type_defs import ListSigningJobsResponseTypeDef


def list_signer_jobs() -> ListSigningJobsResponseTypeDef:
    """Lists AWS Signer Data Plane signing jobs."""
    # Ensure AWS credentials are configured (e.g., via environment variables, ~/.aws/credentials)
    # This example uses placeholder region and credentials for demonstration.
    # In a real application, boto3 automatically picks up credentials.
    region_name = os.environ.get('AWS_DEFAULT_REGION', 'us-east-1')
    
    client: SignerDataPlaneClient = boto3.client("signer-data", region_name=region_name)
    response = client.list_signing_jobs(
        maxResults=10  # Limit results for example
    )
    print("Successfully listed Signer Data Plane jobs.")
    for job in response.get("jobs", []):
        print(f"  Job ID: {job.get('jobId')}, Status: {job.get('status')}")
    return response

if __name__ == "__main__":
    try:
        list_signer_jobs()
    except Exception as e:
        print(f"An error occurred: {e}")
        print("Please ensure 'boto3' is installed and AWS credentials are configured.")

view raw JSON →