Important:
When developing websites or building apps with Blocks, use Velo service plugins.
As an external database provider, you can integrate with Wix to allow Wix sites to access and manage data stored anywhere, as if it were hosted natively on Wix.
By implementing this service plugin, you can design your app to:
The integration is done via an app in the Wix App Market and by implementing the External Database service plugin. After the app is installed on a site, Wix triggers a call to your service whenever the site needs to access and interact with the external database.
Wix offers a variety of data management solutions to accommodate common user needs at different scales. This includes support for internal databases hosted directly on Wix, as well as external databases hosted outside the Wix ecosystem.
You can store and manage data directly on Wix using the Wix Data API. Wix also supports managing data hosted on external databases. The External Database Connections API allows Wix Data to communicate with an external database as if it were hosted directly on Wix. Wix offers several out-of-the-box external database integrations for common platforms such as Google Cloud Platform (GCP), Amazon Web Services (AWS), or Microsoft Azure. These integrations translate Wix Data requests into the external database's protocol, and translate the response back into a format that Wix APIs can read.
To allow Wix Data to communicate with any other data source, implement the External Database service plugin.
Your service can accommodate many scenarios that require Wix Data to communicate with external databases. These might include:
It's important to note the following before starting to code:
The External Database service plugin defines methods you can implement to integrate an external database with Wix. Wix Data calls these methods to access and manage the items and collections in the external database. The method descriptions specify the type of request Wix Data sends to each method, and what type of response each method is expected to return.
When the methods are implemented, you can either:
connectionType
set to WIX_SERVICE_PLUGIN
to integrate your service with a single site.While you aren't required to implement all the methods in this service plugin, make sure to implement at least the following methods to provide basic functionality:
Note: Instead of creating an app, you can connect your service directly to a single site using the External Database Connections API.
To make your service available for integration with multiple sites, create and configure a Wix app:
Create an app in your Wix Studio workspace.
Go to Extensions in your app's dashboard.
Click Create Extension.
Find and select External Database Provider and click Create.
If it has not been set before, set up an app namespace. This is a unique identifier for your app that, once set, can't be changed. It is added as a prefix to the user's external collection names.
Use the built-in JSON editor to provide your extension’s configuration details. Make sure to include all the required fields as they appear in the table below. Once you're done, click Save.
Name | Type | Description |
---|---|---|
namespace | String | Required. A prefix for all the collections your application retrieves. It must be identical to your app namespace. |
uriConfig | Object | The URI configuration object. |
uriConfig.baseUri | String | Required. Base URI where your service is deployed. Wix Data uses this URI to call your service's methods. |
componentName | String | A unique name for this component. This is an internal name that appears in the app dashboard only. |
For example: