iko

Iko is an asynchronous micro-framework for converting data into different structures.


Keywords
asynchronous, deserialization, hacktoberfest, marshaling, python, schema, serialization
License
MIT
Install
pip install iko==0.4.0

Documentation

iko

Code coverage Status https://travis-ci.org/MyGodIsHe/iko.svg?branch=master

Iko is an asynchronous micro-framework for converting data into different structures.

Inspired marshmallow.

Typical usage

The main use-case of this framework is web service’s request and response data marshaling.

Example:

@swagger.schema('UserRequest', 'UserResponse')
async def handler(request):
    body = await request.json()
    data = await UserSchema.load(body)
    await mongodb.users.insert_one(data)
    data = await mongodb.users.find_one({'_id': data['id']})
    return Response(await UserSchema.dump(data))