Registry / type-stubs / mypy-boto3-ssm-incidents

mypy-boto3-ssm-incidents

JSON →
library1.43.0pypypi✓ verified 24d ago

mypy-boto3-ssm-incidents provides official type annotations (stubs) for the boto3 AWS SSM Incidents service client. It allows users to leverage static type checking with tools like MyPy, improving code quality and catching errors early. This library is automatically generated by the `mypy-boto3-builder` and its version typically aligns with the corresponding `boto3` service version. The current version is 1.42.3, reflecting the boto3 API version, and updates frequently alongside new boto3 releases.

pip install mypy-boto3-ssm-incidents boto3
INSTALL
IMPORT
SIG · MYPY-BOTO3-SSM-INC
M
mypy-boto3-ssm-incidents
type-stubspythonv1.43.0
Install
3.8s avg
Import
580ms
Disk
50MB
Pass rate
10/ 10
Env Coverage10 / 10
glibc
3.93.13
musl
3.93.13
Install & Compatibility
Where this runs
tested against v1.43.0 · 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
musl
py 3.103.95 runs
installs and imports cleanly · install 0.0s · import 0.606s · 52MB
glibc
py 3.103.95 runs
installs and imports cleanly · install 3.8s · import 0.554s · 52MB
50MB installed
● package 50MB
Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

SSMIncidentsClient
from mypy_boto3_ssm_incidents import SSMIncidentsClient
GetIncidentRecordOutputTypeDef
from mypy_boto3_ssm_incidents.type_defs import GetIncidentRecordOutputTypeDef

This quickstart demonstrates how to use `mypy-boto3-ssm-incidents` for type-hinting a boto3 SSM Incidents client. It shows the use of `TYPE_CHECKING` to guard stub imports and provides an example API call with inferred types.

import os import boto3 from typing import TYPE_CHECKING # These imports are only for type checking purposes. # They are ignored at runtime if TYPE_CHECKING is False. if TYPE_CHECKING: from mypy_boto3_ssm_incidents import SSMIncidentsClient from mypy_boto3_ssm_incidents.type_defs import GetIncidentRecordOutputTypeDef # Initialize the boto3 client at runtime # Ensure AWS credentials are configured (e.g., via environment variables or ~/.aws/credentials) client: 'SSMIncidentsClient' = boto3.client( "ssm-incidents", region_name=os.environ.get("AWS_REGION", "us-east-1") ) # Example API call with type hints try: # Use a dummy ARN for demonstration; replace with a valid one if you have it incident_arn = "arn:aws:ssm-incidents::123456789012:incident-record/example-incident" response: 'GetIncidentRecordOutputTypeDef' = client.get_incident_record( incidentRecordArn=incident_arn ) print(f"Incident found: {response['incidentRecord']['title']}") except client.exceptions.ResourceNotFoundException: print(f"Incident record '{incident_arn}' not found (as expected for example ARN).") except Exception as e: print(f"An error occurred: {e}") print("Type checking setup successful!")
Debug
Known issues
breakingPython 3.8 is no longer supported by `mypy-boto3-builder` and consequently by `mypy-boto3` packages generated with it.
fix
Upgrade your Python environment to version 3.9 or newer.
affects: mypy-boto3-builder >= 8.12.0 (and generated `mypy-boto3` packages like `mypy-boto3-ssm-incidents` >= 1.42.3)
breaking`mypy-boto3` packages migrated to PEP 561. This change affects how MyPy locates and uses the stubs.
fix
Ensure your `mypy` configuration is up-to-date and compatible with PEP 561 packages. Update MyPy if necessary.
affects: mypy-boto3-builder >= 8.12.0 (and generated `mypy-boto3` packages)
gotchaType stub imports (`from mypy_boto3_ssm_incidents import ...`) should always be wrapped in an `if TYPE_CHECKING:` block.
fix
Wrap all `mypy-boto3` specific imports within `if TYPE_CHECKING: ...` to prevent runtime import errors if the stub package is not installed as a direct runtime dependency.
affects: All versions
gotcha`mypy-boto3-ssm-incidents` provides *only* type annotations. The actual `boto3` library must be installed separately for your code to run.
fix
Always ensure `boto3` is included in your project's runtime dependencies (`pip install boto3`).
affects: All versions
breakingTypeDef naming conventions changed in earlier `mypy-boto3-builder` versions, impacting how some specific TypeDefs are named (e.g., `CreateDistributionRequestRequestTypeDef` became `CreateDistributionRequestTypeDef`).
fix
When upgrading `mypy-boto3` packages across major builder versions, review your code for explicit `from ...type_defs import ...` imports and adjust TypeDef names if they no longer match the generated stubs.
affects: mypy-boto3-builder >= 8.9.0 (and generated `mypy-boto3` packages)
Upgrade
Version history
1.43.0latest on PyPI · released Apr 29, 2026
Audit
Dependencies
boto3requiredThis package provides type stubs for boto3. boto3 itself must be installed to run the code.
mypyoptionalmypy is required to perform static type checking on your code using these stubs.
Agent activity
28 hits · last 30 days
node
24
OpenAI (training)
1
Resources
mypy-boto3-ssm-incidents — pip install mypy-boto3-ssm-incidents · libregistry