Module datapane.client.api.user
Datapane User API
User management functions, including authentication
It's possible to authenticate within Python, however we also provide (and recommend) authenticating via the CLI, as it's easier to automate.
$ datapane signup
$ datapane login --token ...
$ datapane logout
Functions
def login(token: Optional[str], server: str = 'https://datapane.com', env: str = 'default', cli_login: bool = True) ‑> str
-
Login to the specified Datapane Server, storing the token within a config-file called
env
for future useArgs
token
- Token to use when logging in
server
- Datapane Server to connect to (default: Datapane Community at https://datapane.com/)
env
- The environment profile to store these login details to (default:
default
) cli_login
- Toggle if this login is occuring via the CLI (optional)
Returns
the email for the logged in user
Note: Can also be ran via CLI as
"datapane login"
def logout(env: str = 'default') ‑> None
-
Logout from Datapane Server, removing local credentials
Args
env
- Environment profile to logout from
Note: Can also be ran via CLI as
"datapane logout"
def ping(config: Optional[datapane.client.config.Config] = None, cli_login: bool = False, verbose: bool = True) ‑> str
-
Ping the Datapane Server to check login credentials
def signup()
-
Signup and link your account to the Datapane CLI automatically
def hello_world()
-
Create and run an example report, and open in the browser