Whilst attempting to find a way to sync local monitoring tool forms to kobocollect as part of #132, it became apparent that this would not be possible directly from the app, and instead we would need to add an additional server api to handle communication between the app and kobo
We have some development infrastructure in place for running a backend server based on Parse Platform, however it does not work well for our use case and is better replaced by Supabase
This PR adds support for Supabase as a backend and creates
[x] Add support for Supabase backend implementation
[x] Create example api functions to interact with app form submissions and kobotoolbox
[x] Add utility scripts to generate type definitions from database
Next Steps
[ ] Fully integrate supabase backend with work on monitoring tool data submissions
[ ] Create backend staging deployment for use in local development
[ ] Create backend production deployment
[ ] Add documentation
[ ] Add scripts to sync local development instance with staging/production servers
Discussion
As this work is mostly technical there is not much to discuss, however a few things to generally be aware of:
This server will also form the backend for interaction with the climate api and any other 3rd party data sources we plan to include
It will also eventually replace our reliance on firebase for syncing user data (e.g. budgets). This is useful/important as supabase is an open source platform and aligns more closely with our project ethos
Description
Whilst attempting to find a way to sync local monitoring tool forms to kobocollect as part of #132, it became apparent that this would not be possible directly from the app, and instead we would need to add an additional server api to handle communication between the app and kobo
We have some development infrastructure in place for running a backend server based on Parse Platform, however it does not work well for our use case and is better replaced by Supabase
This PR adds support for Supabase as a backend and creates
Next Steps
Discussion
As this work is mostly technical there is not much to discuss, however a few things to generally be aware of:
Preview
Link to app preview if relevant https://picsa.app
Screenshots / Videos
Example submitted form stored on local server db and synced to kobo toolbox