{"library":"mypy-boto3-sagemaker-edge","title":"mypy-boto3-sagemaker-edge Type Annotations","description":"mypy-boto3-sagemaker-edge provides type annotations for the boto3 SagemakerEdgeManager client, enhancing type checking capabilities for tools like MyPy, VSCode, and PyCharm. It is automatically generated by the `mypy-boto3-builder` and released frequently, typically in sync with `boto3` versions, to ensure up-to-date and accurate type hints. The current version is 1.42.3.","language":"python","status":"active","last_verified":"Thu May 14","install":{"commands":["pip install mypy-boto3-sagemaker-edge boto3"],"cli":null},"imports":["from typing import TYPE_CHECKING\nimport boto3\n\nif TYPE_CHECKING:\n    from mypy_boto3_sagemaker_edge.client import SagemakerEdgeManagerClient\n    from mypy_boto3_sagemaker_edge.type_defs import SendHeartbeatRequestRequestTypeDef\n\ndef get_client() -> SagemakerEdgeManagerClient:\n    return boto3.client(\"sagemaker-edge\")"],"auth":{"required":false,"env_vars":[]},"quickstart":{"code":"import boto3\nfrom typing import TYPE_CHECKING\nimport os\n\nif TYPE_CHECKING:\n    from mypy_boto3_sagemaker_edge.client import SagemakerEdgeManagerClient\n    from mypy_boto3_sagemaker_edge.type_defs import SendHeartbeatRequestRequestTypeDef\n\n# Configure AWS credentials and region (replace with your actual configuration)\n# For quickstart, using environment variables or placeholder for simplicity\nos.environ['AWS_ACCESS_KEY_ID'] = os.environ.get('AWS_ACCESS_KEY_ID', 'YOUR_ACCESS_KEY')\nos.environ['AWS_SECRET_ACCESS_KEY'] = os.environ.get('AWS_SECRET_ACCESS_KEY', 'YOUR_SECRET_KEY')\nos.environ['AWS_REGION_NAME'] = os.environ.get('AWS_REGION_NAME', 'us-east-1')\n\ndef main():\n    # Initialize the Sagemaker Edge Manager client with type hints\n    client: SagemakerEdgeManagerClient = boto3.client(\"sagemaker-edge\")\n\n    # Example: Prepare a request for sending heartbeat with type definition\n    heartbeat_request: SendHeartbeatRequestRequestTypeDef = {\n        \"AgentMetrics\": [],  # List of AgentMetricTypeDef\n        \"Models\": []        # List of ModelTypeDef\n    }\n\n    try:\n        # Call an operation on the client\n        response = client.send_heartbeat(**heartbeat_request)\n        print(\"Heartbeat sent successfully.\")\n        print(f\"Response Metadata: {response['ResponseMetadata']}\")\n    except client.exceptions.InternalServiceException as e:\n        print(f\"Error sending heartbeat: {e}\")\n    except Exception as e:\n        print(f\"An unexpected error occurred: {e}\")\n\nif __name__ == \"__main__\":\n    main()","lang":"python","description":"This quickstart demonstrates how to initialize a `boto3` SagemakerEdgeManager client with type annotations provided by `mypy-boto3-sagemaker-edge` and perform a basic operation like `send_heartbeat`. The `TYPE_CHECKING` block ensures that the stub types are only used during static analysis, preventing them from becoming a runtime dependency. Replace placeholder AWS credentials and region as needed.","tag":null,"tag_description":null,"last_tested":null,"results":[]},"compatibility":{"tag":null,"tag_description":null,"last_tested":"2026-05-14","installed_version":"1.43.0","pypi_latest":"1.43.0","is_stale":false,"summary":{"python_range":"3.10–3.9","success_rate":100,"avg_install_s":3.7,"avg_import_s":0.01,"wheel_type":"wheel"},"results":[{"runtime":"python:3.10-alpine","python_version":"3.10","os_libc":"alpine (musl)","variant":"mypy-boto3-sagemaker-edge","exit_code":0,"wheel_type":"wheel","failure_reason":null,"import_side_effects":"clean","install_time_s":null,"import_time_s":0.01,"mem_mb":0.5,"disk_size":"51.0M"},{"runtime":"python:3.10-alpine","python_version":"3.10","os_libc":"alpine (musl)","variant":"mypy-boto3-sagemaker-edge","exit_code":0,"wheel_type":null,"failure_reason":null,"import_side_effects":null,"install_time_s":null,"import_time_s":0.01,"mem_mb":0.5,"disk_size":"50.9M"},{"runtime":"python:3.10-slim","python_version":"3.10","os_libc":"slim (glibc)","variant":"mypy-boto3-sagemaker-edge","exit_code":0,"wheel_type":"wheel","failure_reason":null,"import_side_effects":"clean","install_time_s":3.9,"import_time_s":0,"mem_mb":0.5,"disk_size":"52M"},{"runtime":"python:3.10-slim","python_version":"3.10","os_libc":"slim (glibc)","variant":"mypy-boto3-sagemaker-edge","exit_code":0,"wheel_type":null,"failure_reason":null,"import_side_effects":null,"install_time_s":null,"import_time_s":0,"mem_mb":0.5,"disk_size":"51M"},{"runtime":"python:3.11-alpine","python_version":"3.11","os_libc":"alpine (musl)","variant":"mypy-boto3-sagemaker-edge","exit_code":0,"wheel_type":"wheel","failure_reason":null,"import_side_effects":"clean","install_time_s":null,"import_time_s":0.02,"mem_mb":0.6,"disk_size":"54.0M"},{"runtime":"python:3.11-alpine","python_version":"3.11","os_libc":"alpine (musl)","variant":"mypy-boto3-sagemaker-edge","exit_code":0,"wheel_type":null,"failure_reason":null,"import_side_effects":null,"install_time_s":null,"import_time_s":0.02,"mem_mb":0.6,"disk_size":"53.9M"},{"runtime":"python:3.11-slim","python_version":"3.11","os_libc":"slim (glibc)","variant":"mypy-boto3-sagemaker-edge","exit_code":0,"wheel_type":"wheel","failure_reason":null,"import_side_effects":"clean","install_time_s":3.8,"import_time_s":0.01,"mem_mb":0.6,"disk_size":"55M"},{"runtime":"python:3.11-slim","python_version":"3.11","os_libc":"slim (glibc)","variant":"mypy-boto3-sagemaker-edge","exit_code":0,"wheel_type":null,"failure_reason":null,"import_side_effects":null,"install_time_s":null,"import_time_s":0.01,"mem_mb":0.6,"disk_size":"54M"},{"runtime":"python:3.12-alpine","python_version":"3.12","os_libc":"alpine (musl)","variant":"mypy-boto3-sagemaker-edge","exit_code":0,"wheel_type":"wheel","failure_reason":null,"import_side_effects":"clean","install_time_s":null,"import_time_s":0.01,"mem_mb":0.6,"disk_size":"45.3M"},{"runtime":"python:3.12-alpine","python_version":"3.12","os_libc":"alpine (musl)","variant":"mypy-boto3-sagemaker-edge","exit_code":0,"wheel_type":null,"failure_reason":null,"import_side_effects":null,"install_time_s":null,"import_time_s":0.02,"mem_mb":0.6,"disk_size":"45.2M"},{"runtime":"python:3.12-slim","python_version":"3.12","os_libc":"slim (glibc)","variant":"mypy-boto3-sagemaker-edge","exit_code":0,"wheel_type":"wheel","failure_reason":null,"import_side_effects":"clean","install_time_s":3.2,"import_time_s":0.01,"mem_mb":0.6,"disk_size":"46M"},{"runtime":"python:3.12-slim","python_version":"3.12","os_libc":"slim (glibc)","variant":"mypy-boto3-sagemaker-edge","exit_code":0,"wheel_type":null,"failure_reason":null,"import_side_effects":null,"install_time_s":null,"import_time_s":0.02,"mem_mb":0.6,"disk_size":"46M"},{"runtime":"python:3.13-alpine","python_version":"3.13","os_libc":"alpine (musl)","variant":"mypy-boto3-sagemaker-edge","exit_code":0,"wheel_type":"wheel","failure_reason":null,"import_side_effects":"clean","install_time_s":null,"import_time_s":0.01,"mem_mb":0.7,"disk_size":"45.0M"},{"runtime":"python:3.13-alpine","python_version":"3.13","os_libc":"alpine (musl)","variant":"mypy-boto3-sagemaker-edge","exit_code":0,"wheel_type":null,"failure_reason":null,"import_side_effects":null,"install_time_s":null,"import_time_s":0.01,"mem_mb":0.7,"disk_size":"44.8M"},{"runtime":"python:3.13-slim","python_version":"3.13","os_libc":"slim (glibc)","variant":"mypy-boto3-sagemaker-edge","exit_code":0,"wheel_type":"wheel","failure_reason":null,"import_side_effects":"clean","install_time_s":3,"import_time_s":0.01,"mem_mb":0.5,"disk_size":"46M"},{"runtime":"python:3.13-slim","python_version":"3.13","os_libc":"slim (glibc)","variant":"mypy-boto3-sagemaker-edge","exit_code":0,"wheel_type":null,"failure_reason":null,"import_side_effects":null,"install_time_s":null,"import_time_s":0.01,"mem_mb":0.5,"disk_size":"45M"},{"runtime":"python:3.9-alpine","python_version":"3.9","os_libc":"alpine (musl)","variant":"mypy-boto3-sagemaker-edge","exit_code":0,"wheel_type":"wheel","failure_reason":null,"import_side_effects":"clean","install_time_s":null,"import_time_s":0,"mem_mb":0.4,"disk_size":"50.4M"},{"runtime":"python:3.9-alpine","python_version":"3.9","os_libc":"alpine (musl)","variant":"mypy-boto3-sagemaker-edge","exit_code":0,"wheel_type":null,"failure_reason":null,"import_side_effects":null,"install_time_s":null,"import_time_s":0.01,"mem_mb":0.4,"disk_size":"50.4M"},{"runtime":"python:3.9-slim","python_version":"3.9","os_libc":"slim (glibc)","variant":"mypy-boto3-sagemaker-edge","exit_code":0,"wheel_type":"wheel","failure_reason":null,"import_side_effects":"clean","install_time_s":4.6,"import_time_s":0,"mem_mb":0.4,"disk_size":"51M"},{"runtime":"python:3.9-slim","python_version":"3.9","os_libc":"slim (glibc)","variant":"mypy-boto3-sagemaker-edge","exit_code":0,"wheel_type":null,"failure_reason":null,"import_side_effects":null,"install_time_s":null,"import_time_s":0,"mem_mb":0.4,"disk_size":"51M"}]}}