Python SDK

Prefer python to a UI? You're in the right place.

1. Create an Account or Login to Rasgo

Head over to to signup and get an API key.
Once your account is confirmed and you have logged in, you can copy your API key by clicking 'API KEY' in the top-right corner any page in the Rasgo UI. This will copy the key to your clipboard.

2. Install PyRasgo

Use pip to install PyRasgo:
pip install "pyrasgo[snowflake]"
pip install "pyrasgo[bigquery]"
Then, authenticate with your API key:
Snowflake (default)
!pip install "pyrasgo[snowflake]"
import pyrasgo
api_key = '' #paste your API key here from the UI
rasgo = pyrasgo.connect(api_key)
!pip install "pyrasgo[bigquery]"
import pyrasgo
api_key = '' #paste your API key here from the UI
rasgo = pyrasgo.connect(api_key)

3. Register a Dataset

To register a new dataset with Rasgo, you have 2 options:
Pandas Dataframe
DataWarehouse Table
To publish a pandas dataframe, use:
rasgo.publish.df(df=df, name='my dataset')
Please refer to the documentation for additional details.
To publish a Snowflake table, use:

4. Transform your Dataset

You can apply transformations to Rasgo Dataset objects, like this:
datasets = rasgo.get.datasets()
internet_sales = rasgo.get.dataset(74)
ds2 = internet_sales.aggregate(
aggregations={'SALESAMOUNT':['AVG', 'SUM'],
Rasgo Transforms can be previewed and chained together, like this:
ds3 = ds2.one_hot_encode(column='PRODUCTKEY')
The result of your Rasgo Transforms can be published back to Rasgo using:
new_ds = rasgo.publish.dataset(dataset=ds3, name='Product Sales Analysis')
When a new Dataset is published, Rasgo stores the SQL operations created by using Rasgo Transforms in your data warehouse, so that the new dataset is stored alongside the original data.
Once published, the Dataset is also accessible via the Rasgo UI for visualization and collaboration.