{"id":3377,"library":"mypy-boto3-ssm-sap","title":"Type Annotations for Boto3 SsmSap","description":"mypy-boto3-ssm-sap provides type annotations for the AWS Boto3 SsmSap (Systems Manager for SAP) service. It allows static type checkers like Mypy and IDEs to provide accurate auto-completion, error detection, and type hints for Boto3 calls related to SsmSap. This library is generated by mypy-boto3-builder and is updated regularly to reflect the latest Boto3 versions, currently at 1.42.13.","status":"active","version":"1.42.13","language":"en","source_language":"en","source_url":"https://github.com/youtype/mypy_boto3_builder","tags":["mypy","boto3","aws","type-hinting","static-analysis","ssm-sap","type-stubs"],"install":[{"cmd":"pip install mypy-boto3-ssm-sap boto3","lang":"bash","label":"Install standalone stubs and Boto3 runtime"},{"cmd":"pip install 'boto3-stubs[ssm-sap]' boto3","lang":"bash","label":"Install stubs via boto3-stubs extras"}],"dependencies":[{"reason":"These are type stubs for the boto3 library; boto3 itself must be installed for runtime execution.","package":"boto3"},{"reason":"The primary static type checker for which these stubs are designed.","package":"mypy","optional":true}],"imports":[{"symbol":"SsmSapClient","correct":"from mypy_boto3_ssm_sap.client import SsmSapClient"},{"symbol":"ListApplicationsPaginator","correct":"from mypy_boto3_ssm_sap.paginator import ListApplicationsPaginator"},{"note":"Not all services have a ServiceResource, but if they do, this is the pattern.","symbol":"SsmSapServiceResource","correct":"from mypy_boto3_ssm_sap.service_resource import SsmSapServiceResource"},{"note":"Literals provide type-safe string values for various service parameters.","symbol":"ApplicationStatusType","correct":"from mypy_boto3_ssm_sap.literals import ApplicationStatusType"},{"note":"TypeDefs provide explicit type annotations for input/output dictionary structures.","symbol":"ListApplicationsOutputTypeDef","correct":"from mypy_boto3_ssm_sap.type_defs import ListApplicationsOutputTypeDef"}],"quickstart":{"code":"import boto3\nfrom typing import TYPE_CHECKING\n\nif TYPE_CHECKING:\n    from mypy_boto3_ssm_sap.client import SsmSapClient\n    from mypy_boto3_ssm_sap.paginator import ListApplicationsPaginator\n\ndef get_ssm_sap_client() -> 'SsmSapClient':\n    \"\"\"Returns a type-hinted Boto3 SsmSap client.\"\"\"\n    # Boto3 client is implicitly typed by mypy-boto3-ssm-sap\n    return boto3.client(\"ssm-sap\")\n\ndef list_all_applications(client: 'SsmSapClient'):\n    \"\"\"Lists all SsmSap applications using a paginator.\"\"\"\n    paginator: 'ListApplicationsPaginator' = client.get_paginator(\"list_applications\")\n    for page in paginator.paginate():\n        for app in page.get(\"Applications\", []):\n            print(f\"Application ID: {app.get('ApplicationId')}, Status: {app.get('Status')}\")\n\n# Example usage (requires AWS credentials configured for boto3)\nif __name__ == \"__main__\":\n    ssm_sap_client = get_ssm_sap_client()\n    list_all_applications(ssm_sap_client)\n","lang":"python","description":"This example demonstrates how to get a type-hinted `SsmSapClient` and use a paginator for `list_applications`, leveraging the type annotations provided by `mypy-boto3-ssm-sap`. The `TYPE_CHECKING` block ensures that the code runs without issues even if `mypy-boto3-ssm-sap` is not installed at runtime, while still providing type hints for static analysis."},"warnings":[{"fix":"Always install `boto3` alongside `mypy-boto3-ssm-sap` (e.g., `pip install mypy-boto3-ssm-sap boto3`).","message":"This package provides only type annotations, not the `boto3` runtime itself. You must install `boto3` (e.g., `pip install boto3`) for the code to execute at runtime. Without `boto3` installed, this package is effectively useless.","severity":"gotcha","affected_versions":"all"},{"fix":"Upgrade your Python environment to 3.9 or newer.","message":"Support for Python 3.8 was removed starting with `mypy-boto3-builder` version 8.12.0. Packages generated with this builder version (including `mypy-boto3-ssm-sap` 1.42.13 and newer) will not work with Python 3.8.","severity":"breaking","affected_versions":">=8.12.0 of builder (corresponds to mypy-boto3-ssm-sap >=1.42.13)"},{"fix":"Review and update your `TypeDef` imports and usage to align with the new naming conventions. Consult the specific service's documentation for exact `TypeDef` names.","message":"In `mypy-boto3-builder` version 8.9.0, `TypeDef` naming conventions changed. This includes shortening packed method argument names (e.g., `CreateDistributionRequestRequestTypeDef` -> `CreateDistributionRequestTypeDef`) and moving `Extra` postfixes (e.g., `CreateDistributionExtraRequestTypeDef` -> `CreateDistributionRequestExtraTypeDef`). This can break existing type hint usage.","severity":"breaking","affected_versions":">=8.9.0 of builder (check your `mypy-boto3-ssm-sap` version's builder version)"},{"fix":"For `lite` versions, explicitly add type annotations: `client: SsmSapClient = session.client(\"ssm-sap\")`. For standard packages, this is usually optional but good practice.","message":"If using `mypy-boto3-builder` to generate custom stubs or installing `boto3-stubs-lite`, explicit type annotations for `boto3.session.client()` and `boto3.session.resource()` calls might be required. The standalone `mypy-boto3-ssm-sap` package generally provides implicit typing, but `lite` versions do not.","severity":"gotcha","affected_versions":"All versions, specifically when using lite variants or custom builds."},{"fix":"Use a `TYPE_CHECKING` block with runtime fallbacks (`ClassName = object`) or configure Pylint to ignore these specific warnings (e.g., `# pylint: disable=no-name-in-module`).","message":"When using Pylint, it might complain about undefined variables if `mypy-boto3` imports are conditional on `TYPE_CHECKING` and Pylint is not configured to understand these. This is a Pylint limitation, not a bug in the stubs.","severity":"gotcha","affected_versions":"All versions when using Pylint."}],"env_vars":null,"last_verified":"2026-04-11T00:00:00.000Z","next_check":"2026-07-10T00:00:00.000Z"}