Client Authentication

Authenticating the client

Environment Variable Configuration

To authenticate with the API, by default the clients grab your Kaskada client-id and client-secret from the environment variables. Depending on whether or not you are working inside a notebook, there are two primary ways to do this:

Working from Notebooks

If you are running in a notebook environment (like Jupyter or Google Colab), we recommend using the python getpass method to avoid saving your client secret to the notebook:

import os
from getpass import getpass

os.environ['KASKADA_CLIENT_ID'] = '<your-client-id>'
os.environ['KASKADA_CLIENT_SECRET'] = getpass('Enter your Kaskada Client Secret here: ')

When executing this code-block, paste in your client secret, and it will be added to the environment without displaying it to the screen or saving it to the notebook.

Working with generic python (outside a notebook)

If you are running outside a notebook, you can simply set environment variables on your machine:

export KASKADA_CLIENT_ID=<your-client-id>
export KASKADA_CLIENT_SECRET=<your-client-secret>

Client Initialization

After setting the environment variables, initialize your desired client:

Python

import kaskada as kda

kda.init()

To verify your credentials are working you can make an API call using the Python client:

from kaskada import table
table.list_tables()
{}

️ Info

If you have yet to set up tables you'll receive an empty result, this is expected and verifies the credentials are working.

You may also provide your Client ID and Client Secret explicitly when creating a client:

kda.init(client_id = "<your-client-id>", client_secret = "<your-client-secret>")

Fenl Magic

%load_ext fenlmagic

To explicitly provide your Client ID and Client Secret, use the fenl_auth magic command:

%fenl_auth <your-client-id> <your-client-secret>

© Copyright 2021 Kaskada, Inc. All rights reserved. Privacy Policy

Kaskada products are protected by patents in the United States, and Kaskada is currently seeking protection internationally with pending applications.