flask-base-api
flask-base-api copied to clipboard
Device and Event Model Question
I really like this project and have been using my variation of it as the base for my projects. Until now I never gave Device and Event models thought since I thought I had no use for them before and usually have just commented out those sections. But now I want to know what their intended use cases were and how to use them as you intended.
For the Device model it seems to be for sending messages to a device via an external service? But how do you collect this device information that is in the request headers? Is there an example of a frontend app that fingerprints a device or whatever and sends that with its request to register a device to a user? Or do I have this all wrong?
Then the Event model is used in your boilerplate is only seen in manage.py
but then never referenced again so I'm not sure what the use case was. I can only assume I should define more app level events
in the api.common.utils.constants
and use those to register a history of events in the app such as "User did X", or "Scheduled Celery Task Completed" or something??? Could you elaborate a bit more on that as well? I was thinking of using something like Flask-Bitmapist for this use case until I remembered the Event
model and perhaps if they have the same use cases I would just use the Event model you defined.
Again thanks for this boilerplate.