Bubble Docs
Search…
API Basics
The Bubble API is a way to let other services make requests to and connect with your Bubble app. This is different from accessing data from or making requests to other services, which is done via plugins or the API Connector.

The API vs the API Connector

As soon as you want the external world to do something with your app (run workflows or read data), the Bubble API is the right tool. On the other hand, If you want your app to read external data or trigger some action in another system (like fetching a Facebook profile picture or sending a SMS with Twilio), the Bubble API is not the right tool. Instead, you should use a plugin or the API connector, or build a new plugin to add this new service.

The Data API vs Workflow API

The POST/Workflow API lets you access a new page in your app that lets you edit workflows that can be triggered by another service, or that can be used for scheduling purposes. If you need to schedule some workflows in the future in your app, or run a workflow on a weekly or monthly basis, or let another service/server programmatically trigger some workflows in your app, the Workflow API is the right tool for this.
The GET/Data API is the way you expose data to the outside world. If you need to let another service/server programmatically read or write data to your Bubble app's database, build yourself another system that should share the same database, or expose data to other developers, the Data API is the right tool for this.

Specific use cases

Here are is a small list of ways you can use it:
  • You want to send an email whenever a credit card fails for a subscription with Stripe. You can define an API workflow that does this in the Bubble editor, and get Stripe to trigger this workflow via the Workflow API when a charge fails.
  • You want to get the new things created in the database every week. You can write a script that fetches the new things via the Data API.
  • You want to handcode a native iOS app (or an iWatch app) in Swift. You can use both the Workflow and the Data API to fetch data, login users, run workflows from your app coded in Swift.
  • The API workflow is also the tool you'll use to set up scheduled workflows in your app. Scheduled and recurring workflows do not involve external services, but will require you set up some API workflows that will be triggered in the background by your app.
  • Lastly, an option that the API offers is to open your app to other developers. You can start having other developers build apps that connect with your app, read data, or that let users authenticate with your app's credentials, as Facebook lets developers use a 'Login with Facebook' button.
Last modified 8mo ago