Connect to Webflow Data in RazorSQL
The CData JDBC Driver for Webflow enables standards-based access from third-party tools, from wizards in IDEs to data management and analysis tools. This article shows how to connect to Webflow using wizards in RazorSQL.
Create a JDBC Data Source for Webflow Data
- Open the RazorSQL application and, in the Connections menu, select Add Connection Profile -> Other -> JDBC.
- In the Connection Wizard that appears, set the following properties:
- Driver Location: Set this property to the path to the lib subfolder in the installation directory.
- Driver Class: Set the driver class to cdata.jdbc.api.APIDriver.
- Username: Enter the username. (This property can also be set in the JDBC URL.)
- Password: Enter the password. (This property can also be set in the JDBC URL.)
JDBC URL: Enter connection parameters. The JDBC URL begins with jdbc:api: and is followed by a semicolon-separated list of connection properties.
Authentication
Webflow uses OAuth 2.0 authentication to ensure secure access to sites, CMS collections, e-commerce data, and other resources. This authentication method allows you to securely connect to your Webflow workspace and manage resources with proper authorization.
OAuth 2.0 Setup and Configuration
Step 1: Create a Webflow OAuth Application
To set up OAuth authentication:
- Visit the Webflow Developer Portal
- Navigate to "Apps & Integrations" in your Webflow account
- Click "Register an App" to create a new OAuth application
- Configure the application name, description, and redirect URI (CallbackURL)
- Copy the Client ID and Client Secret for use in your connection
Required Connection Properties
- AuthScheme: Set this to OAuth (required)
- OAuthClientId: Client ID from your Webflow OAuth application (required)
- OAuthClientSecret: Client secret from your Webflow OAuth application (required)
- CallbackURL: Redirect URI specified in your OAuth application (required)
- InitiateOAuth: Set to GETANDREFRESH for automatic token management (recommended)
Required OAuth Scopes
The Webflow API Profile requires the following OAuth scopes:
- sites:read - Read access to site information and configuration
- pages:read - Read access to site pages
- cms:read - Read access to CMS collections and items
- forms:read - Read access to forms and form submissions
- assets:read - Read access to media assets and folders
- ecommerce:read - Read access to products, orders, and inventory
- authorized_user:read - Read access to the authorized user
Built-in Connection String Designer
For assistance in constructing the JDBC URL, use the connection string designer built into the Webflow JDBC Driver. Either double-click the JAR file or execute the jar file from the command-line.
java -jar cdata.jdbc.api.jar
Fill in the connection properties and copy the connection string to the clipboard.
A typical JDBC URL is the following:
jdbc:api:Profile=C:\profiles\Webflow.apip;AuthScheme=OAuth;InitiateOAuth=GETANDREFRESH;OAuthClientId=your_client_id;OAuthClientSecret=your_client_secret;CallbackUrl=your_callback_url;
Query Webflow Data and Select Tables
After establishing a connection, the wizard will close and the connection will be available in the connections panel. You can then query the tables.