Module trase.tools.splitgraph_utilities.config

Interaction with the Splitgraph config file, usually at ~/.splitgraph/.sgconfig

Functions

def access_token(client: splitgraph.cloud.RESTAPIClient) ‑> str

Get a cloud access token

Raises: RuntimeError with helpful message if the token doesn't exist or is out of date

def graphql_api(remote)

Fully-qualified URL to the GraphQL API

def make_client(remote) ‑> splitgraph.cloud.RESTAPIClient

Construct an API client for the given Splitgraph remote

Example

client = make_client("trase")  # internal
client = make_client("data.spligraph.io")  # public

Raises: RuntimeError with a helpful message if the remote does not exist