How to connect Stepzen Graphql queries to supabase(Postgres database)?

How to connect Stepzen Graphql queries to supabase(Postgres database)?

·

2 min read

Hi 👋 friends, in this blog, you gonna learn how to set up graphql queries with the help of Stepzen.

Tools needed:

  1. Nextjs

  2. Supabase Account

  3. Stepzen Account

If you don’t know how to set up Supabase Account then you can read this 👇 How to connect Supabase and Nextjs

Now comes, how to setup stepzen account.

Go to stepzen.com and click on the start for free button.

After signing up, click on my stepzen:

After that you would see this page:

I have hidden the admin key and API key so that I can prevent my account from being hacked.

Now make a nextjs project and go there:

In the root directory, make a folder name stepzen:

Then type this command in terminal

npm install -g stepzen

-g means that package would be installed globally.

Then type stepzen login but remember to be in the stepzen folder

You can find the username WHICH is written as Account here and admin key here:

You can enter any endpoint name or you can just hit enter.

Now, let's go to supabase

Remember that you should have a password:

  1. Password should not contain any symbols like (#$#@!!$) else it can give an error

This error came. But why 🤔?

If you faced any error other than it saying ‘user not found or something else’, then you may have put wrong password

After talking with the stepzen team at discord, https://discord.gg/xCxgan262w.

The error came because we haven’t made any table in the database.

After saving the table.

Retry the command

Then type stepzen start

Then, you can follow this tutorial:

youtube.com/watch?v=O0AhmAVzOo4

Did you find this article valuable?

Support Next Dev's Blog by becoming a sponsor. Any amount is appreciated!

Â