Integrate Supabase DB with BuildShip

BuildShip offers a powerful integration with Supabase allowing you to perform Create, Read, Update, and Delete (CRUD) operations on your data with ease. This integration is achieved through the Supabase Realtime API.

Supabase Integration

Prerequisites ✅

Your Supabase Table

A Supabase Table you want to integrate with BuildShip. If you don't have a Supabase project, you can create one at supabase.io (opens in a new tab).

API Key and URL

Supabase API Key and URL Supabase API Key and URL

Before you begin, make sure you have your Supabase API key and Table URL ready. You can obtain these keys from your Supabase project dashboard settings:

  • Log in to your Supabase account.
  • Navigate to your project's dashboard.
  • In the dashboard settings, find and copy your API key and Table URL. These keys will be used to connect BuildShip with your Supabase project.

API Endpoints (Optional - For creating your own custom nodes)

You can get access to API endpoints directly from your table by clicking on the "API" button located at the top right corner of the Supabase table view. This is useful if you wish to create your own custom nodes for specific endpoints.

💡

To perform CRUD operations on your Supabase database, you'll be required to create a custom RLS Policy (Row Level Security). By default, Supabase RLS is enabled to restrict all access using the anon key, this will prevent any operation and might result in an empty array.

Supabase RLS

Note: You can also disable the RLS, but its not recommended. You can securely store your Supabase API key using BuildShip's secret manager, learn more here.

Creating Data

Supabase Create Node

With BuildShip's integration, you can easily create new records in your Supabase PostgreSQL database. Follow these steps:

  • In your BuildShip Workflow, add a Supabase Create Node from the Node Explorer. You can find the Supabase Create Node under the "Supabase" integration category or you could simply enter Supabase on the search bar.
  • Configure the node by providing your Supabase API Key, Bearer Token, Table URL, and Table Name.
  • Open the Node Editor to test your node.
  • Add the data you want to create in the "Data" field in the form of a JSON object. Here's an example of a JSON object you can use to create a new record in your Supabase table:
{
  "breed_name": "Birman",
  "country_of_origin": "Burma"
}
  • Test your node by clicking on the "Test" button. If the node is configured correctly, you should see a new record in your Supabase table.
  • Optionally, you could modify and customize the node according to your needs. Once you're done, click on the "Save" button to save your node.
  • Add more nodes or simply add a Return node to complete your workflow.
💡

BuildShip offers two versions of Supabase nodes, with and without Authorization Token. The with Token nodes are a slightly adapted version to support an Authorization token being passed in from your client. This allows Supabase Row Level Security to be utilised as a passthrough with Buildship.

This is useful for users using BuildShip along with FlutterFlow or other no-code frontend tools, and authenticating with Supabase using their out-of-the-box functionality.

Note: If you do not have an Access Token, use the Supabase "Create Row" node instead.

Reading Data

Supabase Read Node

To retrieve data from your Supabase database, use the Read Node:

  • In your BuildShip workflow, add a Supabase Read Node from the Node Explorer. You can find the Supabase Create Node under the "Supabase" integration category or you could simply enter Supabase on the search bar.
  • Configure the node by providing your Supabase API Key, Bearer Token, Table URL, and Table Name.
  • Specify the columns you want to retrieve from your table in the "Columns" field. You can also leave it empty which will by default retrieve all columns.
  • Optionally you could customize, test and save the node.
  • Execute the workflow, and BuildShip will fetch the data from your Supabase database in real-time.
  • Now you can use this data anywhere in your workflow via the Expressions menu.

Updating Data

Supabase Update Node

Updating records in your Supabase database is straightforward with the Update Node:

  • In your BuildShip workflow, add a Supabase Update Node from the Node Explorer.
  • Configure the node by providing your Supabase API Key, Bearer Token, Table URL, and Table Name.
  • You need to add conditions to specify which records should be updated using filters like eq, lt, and is.
💡

Refer to the Filters section below for more information on how to use filters.

  • You can optionally customize, test and save the node.
  • Deploy your workflow, and everytime your workflow triggers, your data will be updated in your Supabase database in real-time.

Deleting Data

Supabase Delete Node

To delete records from your Supabase database, use the Delete Node:

  • In your BuildShip workflow, add a Supabase Delete Node from the Node Explorer.
  • Configure the node by providing your Supabase API Key, Bearer Token, Table URL, and Table Name.
  • Add filters to specify which records should be deleted using filters like eq, lt, and is.
    💡

    Refer to the Filters section below for more information on how to use filters.

  • Deploy your workflow and the specified records will be deleted from your Supabase database in real-time.

Filters

Filters are used to specify which records should be retrieved, updated, or deleted. You can add multiple filters to a node. Here's a list of all the filters you can use:

  • eq (Equal): This operator is used to filter records where a specific field is equal to a given value. For example, name=eq.siamese would match records where the name field is equal to "siamese." neq (Not Equal): This operator filters records where a specific field is not equal to a given value. For example, age=neq.5 would match records where the age field is not equal to 5.

  • gt (Greater Than): Use this operator to filter records where a specific field is greater than a given value. For instance, age=gt.30 would match records where the age field is greater than 30.

  • lt (Less Than): This operator filters records where a specific field is less than a given value. For example, price=lt.10 would match records where the price field is less than 10.

  • gte (Greater Than or Equal To): This operator filters records where a specific field is greater than or equal to a given value. For example, quantity=gte.100 would match records where the quantity field is greater than or equal to 100.

  • lte (Less Than or Equal To): Use this operator to filter records where a specific field is less than or equal to a given value. For instance, rating=lte.4.5 would match records where the rating field is less than or equal to 4.5.

  • is (IS): This operator is used for comparing fields with specific values or conditions, such as checking if a field is null. For example, email=is.null would match records where the email field is null.

  • like (LIKE): This operator allows you to perform partial string matching. For example, name=like.%John% would match records where the name field contains "John" anywhere in the string.

Need Help?

  • 💬
    Join BuildShip Community

    An active and large community of no-code / low-code builders. Ask questions, share feedback, showcase your project and connect with other BuildShip enthusiasts.

  • 🙋
    Hire a BuildShip Expert

    Need personalized help to build your product fast? Browse and hire from a range of independent freelancers, agencies and builders - all well versed with BuildShip.

  • 🛟
    Send a Support Request

    Got a specific question on your workflows / project or want to report a bug? Send a us a request using the "Support" button directly from your BuildShip Dashboard.

  • ⭐️
    Feature Request

    Something missing in BuildShip for you? Share on the #FeatureRequest channel on Discord. Also browse and cast your votes on other feature requests.