I have what I think is a very basic use case. Say you establish a ReTool app that manages a single table in Postgres.
Is there a way in any of the ReTool API's to perform read/write operations on that table? If so, how would we do it and how is it secured?
Thanks for any advice!
I've used workflows with a webhook trigger for this type of use-case before. For updates, you can post the data you want to update/insert to the webhook, and configure the workflow to insert the data from the payload into your postgres table. There's a template that is similar to this, called "Sync API to Retool DB Postgres Database" you can use as a starting point.
You can also use webhook-triggered workflows for reading data, by sending an ID, or something of the row you want to pull and configuring a Response Block. They have an "API Endpoint" Template (screenshot below) to use as a starting point for this.
In terms of security, each webhook-trigger on a workflow comes with a corresponding "workflowAPIKey" which is passed as a URL parameter.