A CSV Middleware for FastAPI
Project description
FastAPI CSV Middleware
This is a simple middleware for FastAPI that allows you to upload CSV files and parse them into a list of dictionaries.
I've explained a bit more in this blog post here.
Installation
pip install fast-csv-middleware
Usage
from fastapi import FastAPI
from fastapicsv import CSVMiddleware
app = FastAPI()
app.add_middleware(CSVMiddleware)
Testing
Request Body
Use Content-Type=text/csv
in request headers when sending csv
text in request body.
Response Body
Use Accept=text/csv
in request headers to receive csv
text in response body.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Close
Hashes for fast-csv-middleware-0.1.3.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4486456a34a5bc9cc9679d88c290bee0f3ca36cff5986534beb1c302408a9c32 |
|
MD5 | 231577d2b603fd4eeea323957f42b86a |
|
BLAKE2b-256 | 006e611c09a3ed831915b16a9572350a68c49a156216afd577ba181ebf1810c3 |