--- id: aiomoto version: "0.5.3" license: MIT license_treatment: permissive maintenance: active --- # aiomoto — Moto-style AWS service mocks for aiobotocore License: permissive · Maintenance: active · Downloads: 100.3K/mo ## What it is and what it does aiomoto is a testing library that extends Moto's AWS service mocking to work with async code. It lets you write tests that use both synchronous botocore clients and asynchronous aiobotocore clients against the same in-memory mock backend in a single process. This solves the problem of testing async AWS code without either spinning up a real AWS environment or running a separate Moto server. The library wraps Moto's stubber to make it work with async contexts and decorators. It actively supports S3 (CRUD, listings, streaming), DynamoDB, Secrets Manager, SES, SNS, SQS, KMS, STS, Lambda, Events, and Kafka/MSK, with many other Moto services often working out of the box. It depends on aiobotocore, moto, and platformdirs, and targets Python 3.11 or later. Use it for: - Test async code that calls S3 or DynamoDB without mocking infrastructure or a separate server. - Write integration tests for applications using aiobotocore across multiple AWS services. - Validate data pipelines that read from and write to mock S3 buckets using async clients. - Test SQS/SNS event handling in async code without deploying to AWS. - Develop and debug async code locally with deterministic, in-process mocks. ## Worth the install? AI-flagged interpretation of the facts above — verify before relying. Provides async-compatible AWS service mocks for aiobotocore that share a backend with synchronous botocore clients, letting you test async and sync code against the same in-memory mock services. Yes, if you test async AWS code with aiobotocore. It solves a real gap—Moto does not natively support async clients—and offers low install friction with active maintenance. Pre-alpha status and narrow version constraints mean you should pin versions and monitor releases, but the library is exercised in tests across multiple services and carries no known vulnerabilities. ## Install pip install aiomoto uv add aiomoto poetry add aiomoto ## Installing aiomoto Before you install: Low friction: pure Python wheel with three runtime dependencies (aiobotocore, moto, platformdirs). Actively maintained with a recent release; marked pre-alpha but exercised in tests across multiple AWS services. License in practice: MIT license permits commercial and private use with minimal restrictions; suitable for most projects. Quickstart: pip install aiomoto from aiobotocore.session import AioSession from aiomoto import mock_aws async def demo(): async with mock_aws(): session = AioSession() async with session.create_client("s3", region_name="us-east-1") as s3: result = await s3.list_buckets() Requires Python 3.11 or later; aiobotocore and moto must be installed as runtime dependencies. Verify before relying: - Whether free-threaded CPython support is production-ready or still experimental. - Performance characteristics when mocking large datasets or high-concurrency workloads. - Stability guarantees given pre-alpha status and narrow version ranges. - Whether sync and async clients can truly share state in all tested service scenarios. ## Package facts - License: MIT (permissive) - Python support: supports_current - Install friction: low - Maintenance: active - Downloads: 100.3K/month (top 15,000 on PyPI) - Known vulnerabilities: none known ## Tags async AWS mocking, aiobotocore testing, mock AWS services async, aiobotocore moto, async S3 DynamoDB testing, moto aiobotocore, in-memory AWS mocks, async-testing, aws-mocking, aiobotocore [View on SkillFed](https://skillfed.io/packages/aiomoto) · [View on PyPI](https://pypi.org/project/aiomoto/)