Skip to content

对 FastApi 进行二次封装的简易 HTTP Web 服务 SDK

License

Notifications You must be signed in to change notification settings

AmiyaBot/Amiya-HTTP

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

AmiyaHttp

PyPI

FastAPI 进行二次封装的简易 HTTP Web 服务 SDK

import asyncio
from amiyahttp import HttpServer

server = HttpServer(host='0.0.0.0', port=8088)


@server.controller
class Bot:
    @server.route(method='get')
    async def get_name(self):
        return 'AmiyaBot'

    @server.route(method='post')
    async def say_hello(self):
        return server.response(message='hello')


asyncio.run(server.serve())

About

对 FastApi 进行二次封装的简易 HTTP Web 服务 SDK

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages