async def create_cast(payload: CastIn):
    cast_id = await service.create_cast(payload)

    response = {'id': cast_id, **payload.dict()}

    debug(response)
    return response
Beispiel #2
0
async def create_cast(payload: CastIn):
    cast_id = await db_manager.add_cast(payload)

    response = {
        'id': cast_id,
        **payload.dict()
    }

    return response
async def post(payload: CastIn):
    query = casts.insert().values(**payload.dict())
    return await database.execute(query=query)