JSON serialization of Google App Engine models

后端 未结 14 2120
不知归路
不知归路 2020-12-04 04:59

I\'ve been searching for quite a while with no success. My project isn\'t using Django, is there a simple way to serialize App Engine models (google.appengine.ext.db.Model)

14条回答
  •  一向
    一向 (楼主)
    2020-12-04 05:53

    In the latest (1.5.2) release of the App Engine SDK, a to_dict() function that converts model instances to dictionaries was introduced in db.py. See the release notes.

    There is no reference to this function in the documentation as of yet, but I have tried it myself and it works as expected.

提交回复
热议问题