API Trading Prerequisites and Setup

Before you start, please make sure to familiarize yourself with the key concepts.


  • Variational Python SDK and API credentials (see the Quickstart Guide)

  • Connected Ethereum wallet (go to Variational Pro and hit Connect in the top right corner)

  • The private key for your registered wallet to sign spending permits

  • Some test USDC on Arbitrum Sepolia (you can use our faucet to get some)

Prepare the Clients and Contracts

All tutorials require a few things to be initialized:

import json

from variational import (Client, TESTNET, TransferPermitHelper,
                         PollingHelper, paginate)

# FIXME: load from environment variables
API_KEY = "your-api-key"
API_SECRET = "your-api-secret"
WALLET_PK = "your-wallet-private-key"

client = Client(API_KEY, API_SECRET, base_url=TESTNET)
permits = TransferPermitHelper(client=client, private_key=WALLET_PK)
poller = PollingHelper(client=client)

Last updated