Registry / type-stubs / mypy-boto3-ivs-realtime

mypy-boto3-ivs-realtime

JSON →
library1.43.0pypypi✓ verified 23d ago

mypy-boto3-ivs-realtime provides comprehensive type annotations for the AWS IVS Realtime service within the boto3 library. Currently at version 1.42.86, it is part of the mypy-boto3-builder ecosystem, which generates and releases type stubs frequently, often in sync with new boto3 releases, ensuring up-to-date type checking for AWS services.

pip install mypy-boto3-ivs-realtime boto3
INSTALL
IMPORT
SIG · MYPY-BOTO3-IVS-REA
M
mypy-boto3-ivs-realtime
type-stubspythonv1.43.0
Install
3.7s avg
Import
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.000s · 52MB
glibc
py 3.103.95 runs
installs and imports cleanly · install 3.7s · import 0.000s · 53MB
50MB installed
● package 50MB
Code
Verified usage

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

IVSRealTimeClient
from mypy_boto3_ivs_realtime.client import IVSRealTimeClient
from boto3.client import IVSRealTimeClient
Type stubs are imported from the mypy_boto3_* package, not directly from boto3.
IVSRealTimeClient
client: IVSRealTimeClient = boto3.client('ivs-realtime')
client = boto3.client('ivs-realtime')
Explicit type annotation on the client creation is highly recommended for full type-checking benefits, especially with boto3-stubs-lite or older IDE versions.

This quickstart demonstrates how to set up an IVS Real-time client with type annotations and generate a participant token. It uses `TYPE_CHECKING` for conditional import of stubs, ensuring they are only used during type checking. The client is explicitly typed to leverage the full capabilities of `mypy-boto3-ivs-realtime`. Replace placeholder values with actual AWS credentials and a valid IVS Real-time channel ARN.

import boto3 import os from typing import TYPE_CHECKING # Only import type stubs when type checking if TYPE_CHECKING: from mypy_boto3_ivs_realtime.client import IVSRealTimeClient from mypy_boto3_ivs_realtime.type_defs import CreateParticipantTokenResponseTypeDef def get_participant_token(channel_arn: str, user_id: str) -> dict: """Generates a participant token for an IVS Real-time channel.""" # Explicitly type the client for mypy to provide full benefits client: 'IVSRealTimeClient' = boto3.client( 'ivs-realtime', aws_access_key_id=os.environ.get('AWS_ACCESS_KEY_ID', ''), aws_secret_access_key=os.environ.get('AWS_SECRET_ACCESS_KEY', ''), region_name=os.environ.get('AWS_REGION', 'us-east-1') ) response: 'CreateParticipantTokenResponseTypeDef' = client.create_participant_token( channelArn=channel_arn, userId=user_id ) return response # Example usage (will not run without AWS credentials and a valid channel ARN) if __name__ == "__main__": EXAMPLE_CHANNEL_ARN = os.environ.get('IVS_REALTIME_CHANNEL_ARN', 'arn:aws:ivs:us-east-1:123456789012:channel/abcdefghijkL') EXAMPLE_USER_ID = 'test-user-123' print(f"Attempting to get participant token for channel: {EXAMPLE_CHANNEL_ARN}, user: {EXAMPLE_USER_ID}") try: # This call will fail without actual AWS credentials and a valid ARN token_info = get_participant_token(EXAMPLE_CHANNEL_ARN, EXAMPLE_USER_ID) print("Successfully received token info (type-checked):") print(token_info) except Exception as e: print(f"Error generating token: {e}") print("Please ensure AWS credentials and a valid IVS Real-time channel ARN are set as environment variables.")
Debug
Known issues
breakingPython 3.8 support has been removed since `mypy-boto3-builder 8.12.0`. All generated `mypy-boto3-*` packages, including `mypy-boto3-ivs-realtime`, now require Python 3.9 or newer.
fix
Upgrade your Python environment to 3.9 or later.
affects: mypy-boto3-builder >= 8.12.0
breakingTypeDef naming conventions changed in `mypy-boto3-builder 8.9.0`. Argument TypeDefs for packed method arguments now use shorter names (e.g., `CreateDistributionRequestRequestTypeDef` became `CreateDistributionRequestTypeDef`). Conflicting `Extra` postfixes were also moved to the end (e.g., `CreateDistributionExtraRequestTypeDef` to `CreateDistributionRequestExtraTypeDef`).
fix
Update explicit TypeDef imports and annotations in your code to reflect the new, shorter naming conventions.
affects: mypy-boto3-builder >= 8.9.0
gotchaThis package provides *type stubs* for `boto3`. It does not include the `boto3` library itself. You must install `boto3` separately (e.g., `pip install boto3`) for your code to run at runtime.
fix
Ensure `boto3` is installed in your project environment alongside `mypy-boto3-ivs-realtime`.
affects: All
gotchaExplicit type annotations for `boto3.client()` calls are recommended (`client: IVSRealTimeClient = boto3.client('ivs-realtime')`). While some IDEs and `mypy` might infer types, explicit annotation ensures full type-checking benefits, especially when using `boto3-stubs-lite` or standalone service packages, and can mitigate performance issues in IDEs like PyCharm with Literal overloads.
fix
Add explicit type hints to your `boto3.client()` and `boto3.resource()` calls, using the client/resource types imported from the `mypy_boto3_*` package.
affects: All
Upgrade
Version history
1.43.0latest on PyPI · released Apr 29, 2026
Audit
Dependencies
boto3requiredThis package provides type stubs for the boto3 library; boto3 must be installed for runtime execution.
pythonrequiredRequires Python 3.9 or newer.
Agent activity
20 hits · last 30 days
node
18
OpenAI (training)
1
Resources