REST API in Google App Engine + Python?

前端 未结 3 1133
时光说笑
时光说笑 2020-12-23 22:28

How create a RESTful API using Google App Engine with Python? I\'ve tried using Cloud Endpoints, but the documentation does not focus on a RESTful API. Is there something si

3条回答
  •  挽巷
    挽巷 (楼主)
    2020-12-23 23:12

    https://github.com/mevinbabuc/Restify

    It's a lightweight module that i made, which acts like a ReST interface for appengine. All you would have to do is just define the models in ReSTify/models.py .

    You can also add in authentication to it easily without tweaking much.

    To get started al you have to do is

    import webapp2
    
    import ReSTify
    
    application = webapp2.WSGIApplication(
        [
            ('/api/.*', ReSTify.ReST),
            ],
        debug=True)
    

提交回复
热议问题