Developer: Build an API

Step 1: Navigate to create an API with SQL

Once you open the Query Builder, your next step will be to choose which tables you want to use for your analysis. If you’re not sure what is included in each table, you can preview the content of each table, instead of running any SQL.

Step 2: Write the Query, run it and view the results

Step 3: Create a GraphQL API

Step 4: Choose refresh rate and the indexing fields.

Choose the frequency at which your GraphQL API should update its data from the database (e.g. every 5 minutes, every hour). Select the fields that should be indexed.

(Optional) Step 5: Choose Incremental Refresh

If you want to index using less compute units, choose Incremental refresh, which is a method used to update a portion of a dataset, while preserving the existing data. It involves running two SQL statements: a transformation SQL statement to back-fill all historical data, and an incremental SQL statement to incrementally refresh the latest data.

For a detailed tutorial on how to set up incremental refresh, visit this document.

And that’s it! Your API is ready to be connected to your platform.

Check out API Details for a more detailed guide.