Skip to content

nowayhecodes/fastapi_kafka_example

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

FastAPI Kafka Example

This is an example of how to integrate FastAPI with Kafka.

To run this example, just clone the repo, run docker-compose -f docker-compose.yml up e after the Kafka & Zookeeper images were pulled e the containers were created, you must install the python dependencies.

Then you run the app with uvicorn api.main:app --reload.

After that just POST request to localhost:8000/produce/fastapi_kafka with the payload:

{
    "name": "some message"
}

Or, modify the models to suite your needs.

About

An example of how to integrate FastAPI with Kafka

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages