You’ll need to ensure that you have access to a Salesforce user with permissions to access the Salesforce API.
Create a Salesforce sync
Connect Salesforce and your database to Sequin to start your sync.


Query your Salesforce data using SQL
Connect to your database via Sequin’s Postgres Proxy, which lets you write to your synced tables as well as read them. We’ll use psql as an example in this setup guide, but you can use any SQL client that works with Postgres. Step 1: Go to Connection Instructions on the Sequin console. Copy thepsql
command to connect to your database via the Proxy.
Step 2: Open your terminal, and paste the psql
command. Press Enter. This will open a connection to your database so you can write your first query:
\dt
:
_sync
tables which Sequin uses to manage your sync.
Step 4: Write your first query. You can start with a simple select
to get your bearings:
api_id
, first_name
, and last_name
for a specific customer to use in the next step:
api_id
in the last step of this setup guide.
Write back to Salesforce
To create, update, or delete objects in Salesforce, you caninsert
, update
, or delete
rows in your Postgres database.
When you’re connected to your database through the Sequin Proxy, the Proxy listens for changes. When you make a mutation, the Proxy applies the mutation to Salesforce’s API first. If the mutation succeeds, your database is updated as well. If it fails, your database mutation will be rolled back, and you’ll receive a Postgres error.
In this example, you’ll update the contact
in the prior step by giving them a new first and last name:
psql
and check the contact you just updated:
Next steps
Your Salesforce tables are now available as fully readable and writeable tables in your database. You can query for all your data using SQL, and mutate data thanks to Sequin’s Postgres Proxy. To build on this foundation, here are some next steps:- Setup your ORM to work with your synced tables.
- Edit the Salesforce objects and properties you’re syncing at any time.
- Create views on your Salesforce data to tailor your schema to your needs.
- Invite your team to your Sequin account and start building!