We recommend building your Airtable integration using a dev environment. This allows you to build and test your integration without potentially affecting your production data.
Airtable doesn't provide a sandbox or developer account for development. This guide will show you how you can easily duplicate your production Airtable base and use that as your dev environment.
You'll start by building and testing your feature in development. Then, you can copy the configuration of your dev sync to your production sync.
Creating a dev base
To create a dev base that replicates your production base, duplicate your production base:
- Open your production base in Airtable.
- Duplicate the base by clicking the down-arrow next to the title of the base, clicking the three dots, and selecting "Duplicate base":
- Name the base something like
My Base (Dev - YYYY-MM-DD). This will help you keep track of which base is which.
- With your development base duplicated, you can delete any records you don't need for development. This will help you keep your development base small and easy to work with.
With your development base created, you can now create your sync. To help you delineate between your production and development syncs, you can tag your sync as "dev" in the sync configuration.
From here, build your integration as you normally would. Working with development data will make it easier for you to create, update, and delete records without any possibility of breaking or corrupting production data. As you build, note down any new columns or tables you create, as you'll need to create these in your production base as well.
Move to production
Once your integration is built and tested, you can move your integration to production. To do this, you'll copy your dev sync's configuration to a new sync that points to your production Airtable base and production database:
- Open your production base in Airtable and create any new tables or columns you created in your development base.
- In Sequin, create a new Airtable sync that points to your production Airtable base and connects it to the database you'll use in production.
- When mapping your tables and columns in the Sequin console, you can copy the mapping from your development sync to your production sync by clicking the Copy config from button. This will ensure that your production sync is configured the same way as your development sync.
- Once your production sync is configured, Sequin will backfill your production database with data from your production Airtable base and keep it in sync.
- With your database migration complete, you can now merge and deploy your branch into production.
Over the course of your integration with Airtable, you'll likely make changes in the production Airtable base that are not reflected in your dev base. For example, you might add a new column to a table in production, but not in dev. Or, you might delete a table in production, but not in dev.
Sequin will handle these changes in production with production schema migrations. But when you return to development, you'll need to update your dev base to reflect the changes in production.
To do so, we recommend that you mark your old dev base as "stale" and create a new dev base by once again duplicating your production base. Then edit your dev sync to point to your new dev base.
You'll then repeat the process of building and testing your integration in development, copying your dev sync configuration to a new production sync, and merging your changes into production.