Categories
Uncategorized

Using Bubble-made Plugin APIs 3

Bubble provides a myriad of plugins that you can use to expand your app’s functionality beyond the already-powerful capabilities that Bubble provides. Using plugins, your app can connect with payment services, external databases, and other apps to allow it to become part of the greater app ecosystem and an indispensable part of your users’ digital world. 

Along with other third-party apps, services, and users, Bubble has also created its own official plugins for use by its developers that provide some rather vital functionality, adding some extra components or connecting your apps with social media platforms or other useful services. 

Remember that all these plugins and more can be accessed via Bubble’s Plugins Tab. Simply open the tab and click on the “Add Plugins” button to get started with your journey into the world of Bubble app API assistance. 

SQL Database Connector 

The SQL Database Connector Plugin allows developers to connect their apps with SQL databases and run queries from Bubble.  

For those not in the know, SQL (pronounced by the letter, or as “sequel) is a framework and programming language for building databases from code. Databases built using SQL are hosted in the cloud by services like Amazon Web Services and Microsoft Azure, much like how Bubble hosts its own databases. You can set up databases with these services by creating an account and setting up your database in line with your needs. 

While using it will be much more technical than just using Bubble’s built-in database, SQL allows you to use external database hosting options which might give you and your app better capacity and flexibility, or it might just be better for your app’s use cases. 

The plugin supports connecting to PostGres, MySQL, and Microsoft SQL.  

Setting up the plugin will require you to connect using a string that looks like this: 

mysql://username:password@my-db-instance.endpoint.us-east-1.rds.amazonaws.com:PORT/db_name 

The connection string will also have special requirements for special characters that need to be URL-encoded, and you will also have to modify it in the event that your database setup needs an encrypted connection. In these cases, it’d be best to refer to your database hosting service for further guidance. 

Take note that in order to pass certain special characters to your SQL database like emojis and other characters unsupported by mySQL’s default UTF8 encoding, you need to add the string ?charset=UTF8MB4_GENERAL_CI to the connection string. 

Once you’ve set up the connection, you’ll be able to make use of any SQL statement to interact with your database.  

This can be done by integrating the connector plugin to Bubble workflows, such as by having a workflow to send inputted text data directly to the database once the user has finished entering it, or has pressed a submit button. 

reCAPTCHA 

CAPTCHA (“Completely Automated Public Turing test to tell Computers and Humans Apart”) is a system used on the modern internet to protect websites from access by bots.  

You’ve probably encountered them yourself in the form of the image tests that asked you to identify certain features in blurry or distorted images. These are put in place in order to serve as a block for possibly malicious bots and botnets, which could be used to do anything from create fraudulent transactions or bring down entire websites by overloading their servers. 

reCAPTCHA is a free CAPTCHA service that Google provides for web app support and protecting your site from spam and abuse. Older versions made use of the aforementioned text and image tests, but the latest versions have prioritized avoiding direct interference with the user’s experience on websites. Thus, since version 3, reCAPTCHA never interrupts its users and runs automatically once they click on a link. Instead of using visual tests, reCAPTCHA analyzes the user’s browsing data and behavior to predict whether they are an actual human or a bot. 

Returning to Bubble, once you’ve installed the plugin you can set it up by verifying the API keys in the settings. These API keys can be obtained from your Google developer console and registering a new site and accepting the terms of service. From this same console you can select what version of CAPTCHA you’ll be using. As mentioned before, v3 minimizes disruption of the user experience with the use of the user’s browser data, while v2 still makes use of a challenge prompt to verify human users. 

Note that when you register your Bubble domain initially, you’re only registering the development version of your site and as such you should enter the API keys Google gives you in the appropriate “- dev” fields. Likewise, once you’ve published your site into production, you’ll need to register your new domain with Google again and enter the API keys into the appropriate fields. 

Once you’ve set up your keys, you can also change a few more customization options in the plugin settings. You can change visual themes between light and dark, element size, and verification type. 

With all that set up, you can integrate CAPTCHA challenges into your workflows. A new element will be added to your toolset, a reCAPTCHA form that adds a reCAPTCHA textbox to your application. Simply add a condition to workflow triggers or events to only run when the user passes the reCAPTCHA form. 

Now, with your CAPTCHA fully set up, any workflows that integrate the forms you create won’t move forward without the appropriate CAPTCHA form being verified.  

The Bubble App framework provides you with myriad tools to design and develop your app, all without making use of code or overly technical programming knowledge. Your app can be extremely powerful with the use of these tools and can provide a lot of functionality to its users fitting their needs. 

Plugins can allow you to make use of powerful third-party services, connect with outside platforms, or even add some basic but useful elements to your Bubble app. The masterful and creative integration of these functionalities into your app is just as important as the plugins themselves. These skills; however, can’t be taught in simple text-based tutorials and how-to articles. You’ll need hands-on practice and support along with answers to your Bubble FAQs, all of which can be provided by our team here at Bubblehelpers. So feel more than free to avail of our technical services and aid for your app.