$npx skillfedfor your agent

taskiq-fastapi

FastAPI integration for taskiq

With conditionsPyPI NetworkingReleased Apr 2026225.3K downloads / moMITPure Python

Decision gist · record as of 2026-08-14

pure-Python wheel — taskiq_fastapi-0.5.0-py3-none-any.whl
v0.5.0 · released 2026-04-18 · Python >=3.10 · 2 runtime deps: taskiq, fastapi

Yes, if you are already using both FastAPI and taskiq and want to share dependency injection logic between them. The low install friction, permissive license, and active maintenance make it a reasonable choice. Be aware it is classified as Alpha, so expect potential API changes. Verify that the synthetic Request object meets your dependency needs before committing to production use.AI-flagged interpretation of the facts on this page — verify before relying

Before you install

  • Requires Python 3.10 or later.
  • Requires a running taskiq broker (e.g., ZeroMQ, Redis) and FastAPI application instance.
  • Low install friction with only two runtime dependencies (taskiq and fastapi).

License · maintenance · safety

MIT (permissive) — MIT license permits free use, modification, and distribution with minimal restrictions—suitable for both open-source and commercial projects.

last release 2026-04-18 (118 days)

0 known vulnerabilities (OSV.dev, 2026-08-14) · 225,315 downloads/mo, #9,222 on PyPI

Verify before relying

pip install taskiq-fastapi

import taskiq_fastapi
from taskiq import ZeroMQBroker
from fastapi import FastAPI

broker = ZeroMQBroker()
app = FastAPI()
taskiq_fastapi.init(broker, "myapp:app")
  • Whether the synthetic Request object created by init() is sufficient for all FastAPI dependency patterns in production workloads.
  • Performance characteristics when dependency context is large or frequently updated.
  • Compatibility with FastAPI versions beyond those tested during development.
Same gist for agents: .md · .json

What it is and what it does

taskiq-fastapi bridges FastAPI's dependency injection system with taskiq's distributed task queue. It allows task functions to depend on FastAPI Request objects and access application state (like database pools or configuration) that would normally only be available in HTTP handlers. The library works by injecting a worker-wide Request object at task startup, letting you reuse the same dependency functions across both FastAPI endpoints and taskiq tasks.

The package is designed for scenarios where you want to share business logic between synchronous HTTP handlers and asynchronous background tasks without duplicating dependency resolution. It requires explicit use of TaskiqDepends (rather than FastAPI's Depends) in task signatures so the taskiq resolver knows to inject dependencies. The documentation warns that the injected Request is a synthetic object created at worker startup, not tied to any actual HTTP request, and requires careful handling of broker startup/shutdown to avoid infinite recursion.

Use it for

  • Share a database connection pool or Redis client between FastAPI endpoints and background tasks using the same dependency function.
  • Inject application configuration or secrets into task functions without passing them as explicit parameters.
  • Reuse FastAPI middleware-like logic (authentication, logging, tracing) in distributed task workers.
  • Set up integration tests with InMemoryBroker by manually populating the dependency context for both FastAPI and taskiq.
  • Build microservices where FastAPI handles HTTP requests and taskiq handles async work, both accessing the same application state.

Worth the install?

AI-flagged interpretation of the facts on this page. Verify before relying on it.

With conditions

Yes, if you are already using both FastAPI and taskiq and want to share dependency injection logic between them.

The low install friction, permissive license, and active maintenance make it a reasonable choice. Be aware it is classified as Alpha, so expect potential API changes. Verify that the synthetic Request object meets your dependency needs before committing to production use.

Install

taskiq-fastapi on PyPI

Before you install

Low install friction with only two runtime dependencies (taskiq and fastapi). Active maintenance as of 2026-04-18. Classified as Alpha, so expect API surface changes.

Requires Python 3.10 or later. Requires a running taskiq broker (e.g., ZeroMQ, Redis) and FastAPI application instance.

License in practice

MIT license permits free use, modification, and distribution with minimal restrictions—suitable for both open-source and commercial projects.

Quickstart

pip install taskiq-fastapi

import taskiq_fastapi
from taskiq import ZeroMQBroker
from fastapi import FastAPI

broker = ZeroMQBroker()
app = FastAPI()
taskiq_fastapi.init(broker, "myapp:app")

Verify before relying

  • Whether the synthetic Request object created by init() is sufficient for all FastAPI dependency patterns in production workloads.
  • Performance characteristics when dependency context is large or frequently updated.
  • Compatibility with FastAPI versions beyond those tested during development.

Package facts

LicenseMIT permissive
Python supportSupports the current Python release >=3.10
Install frictionLow. Pure-Python wheel
Runtime dependencies
2 packages
taskiqfastapi
MaintenanceActively maintained 118 days since the last release
First released
Downloads225,315 / month, #9,222 on PyPI 30-day window, as of 2026-08-14
Known vulnerabilitiesNone known OSV.dev, checked 2026-08-14
Classifiers
Development Status :: 3 - AlphaIntended Audience :: DevelopersOperating System :: OS IndependentProgramming Language :: PythonProgramming Language :: Python :: 3Programming Language :: Python :: 3 :: OnlyProgramming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.13Topic :: System :: NetworkingTyping :: Typed

Evidence: taskiq_fastapi-0.5.0-py3-none-any.whl

Tags

Capabilities
fastapi taskiq integrationfastapi dependency injection tasksdistributed tasks with fastapitaskiq fastapi request contextasync task queue fastapi
Topics
fastapi-integrationtask-queuedependency-injection
PyPI keywords
taskiqtasksdistributedasyncfastapi

Let your AI agent find packages like this

Example. Real query, live index.

You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.

wish › “fastapi taskiq integration”

  • taskiq-fastapiIntegrates FastAPI request and dependency injection into taskiq…
  • taskiqTaskiq is an asynchronous distributed task queue that lets you send…
  • taskiq-aio-pikaProvides a RabbitMQ broker implementation for taskiq, enabling…

Give your agent the search over MCP, or paste the wish link into any chat.

More Networking packages

h11 With conditions
PyPI · WWW/HTTP · released Apr 2025

h11 is a pure-Python HTTP/1.1 protocol implementation that handles parsing and serializing HTTP messages without any built-in I/O, letting you integrate it with any network layer you choose.

MITpure Python · 3.8+aging
894.9Mdownloads / mo
psutil Worth it
PyPI · Libraries · released Jan 2026

psutil retrieves real-time information about running processes and system resources (CPU, memory, disks, network, sensors) across multiple operating systems, enabling system monitoring, process profiling, and resource management.

permissive licensecompiled wheel · 3.6+
387.6Mdownloads / mo
pyOpenSSL With conditions
PyPI · Python Modules · released Aug 2026

pyOpenSSL wraps OpenSSL's SSL/TLS functionality for Python, providing high-level connection objects and certificate handling through a Python-friendly interface around OpenSSL's cryptographic operations.

Apache-2.0pure Python · 3.9+
294.2Mdownloads / mo
uvloop With conditions
PyPI · Networking · released Oct 2025

uvloop is a drop-in replacement for Python's built-in asyncio event loop, implemented in Cython and using libuv, that accelerates async I/O operations.

Apache-2.0compiled wheel · 3.8.1+
257.9Mdownloads / mo
execnet With conditions
PyPI · Libraries · released Nov 2025

execnet lets you spawn and communicate with Python interpreters across local processes, remote hosts, and different platforms, using a simple API for task distribution and inter-process messaging.

However, the aging maintenance status (275 days since last release) means you should verify it meets your concurrency and performance needs before committing to a…

MITpure Python · 3.8+aging
172.1Mdownloads / mo
pyzmq Worth it
PyPI · Networking · released Sep 2025

PyZMQ provides Python bindings for ZeroMQ (ØMQ), a lightweight messaging library that enables fast, asynchronous communication between distributed processes and applications.

BSD-3-Clausecompiled wheel · 3.8+
109.5Mdownloads / mo

See also taskiq · taskiq-dependencies · taskiq-redis · taskiq-aio-pika · fast-depends · fastapi-injectable · fasta2a · codewords-client · fastapi-utilities · fastapi-decorators