IDEAS Python library and CLI
Project description
IDEAS Python
This package provides a python API and a CLI to interact with the IDEAS platform.
Installation
Requirements:
python >= 3.11
Installing
The recommended way to install IDEAS Python is with pip in a virtualenv:
python3 -m venv venv
pip install ideas-python
Running
Installing adds the ideas command to the virtualenv. You can either run it directly from the
virtualenv with venv/bin/ideas, or symlink it to a directory in your shell's PATH variable:
# by activating the virtualenv
source venv/bin/activate
# OR, manually
ln -sf $(pwd)/venv/bin/ideas ~/.local/bin/ideas
Note on Windows: For windows, run these commands instead in a git-bash to make ideas available in your path:
mkdir -p ~/.local/bin && touch ~/.bash_profile && echo 'export PATH="$PATH:$HOME/.local/bin"' >> ~/.bash_profile && source ~/.bash_profile
ln -sf $(pwd)/venv/Scripts/ideas.exe ~/.local/bin/ideas.exe
Now you can run the CLI directly:
ideas
Configuration
As ideas interfaces with the IDEAS platform, it must authenticate, and we provide two ways to
do so: through CLI parameters (like --username), or through a configuration wizard.
Configuration wizard
ideas offers a handy shortcut to edit your configuration interactively:
ideas configure
You will be asked for:
- Which region are you in: this corresponds to which region you specified as your home region when you signed up for your IDEAS account.
- Your credentials: use the email address and password you sign into IDEAS with.
- [Optional] You may be asked which tenant you would like to use, if you belong to multiple tenants.
You may call ideas configure again at any point to change these values.
Configuring and using profiles
It is possible also to configure multiple profiles, with arbitrary names. This could be for accessing different regions, using separate accounts, or selecting another tenant ID.
ideas --profile us configure
ideas --profile jp configure
A given profile can then be used by specifying the profile:
ideas --profile jp tenants
Configuring through arguments
Alternatively, you can configure ideas through arguments. If no configuration file exists,
ideas will exclusively use arguments. If you have a configuration file, these arguments will
override the file:
| CLI argument | Config file name | Description |
|---|---|---|
-e/--env |
env |
Which environment to use. List supported environments with ideas environments. |
-u/--username |
username |
Your IDEAS username/email address. |
-p/--password |
password |
The password you log into IDEAS with. |
-t/--tenant-id |
tenant_id |
The numerical ID of the tenant you want to use. List your tenants with ideas tenants. |
Shell completion
You can optionally enable shell completion for the ideas command. We provide tab completion support for Bash (version 4.4 and up), Zsh, and Fish shells.
Bash
# Save the script somewhere
_IDEAS_COMPLETE=bash_source ideas > ~/.ideas-complete.bash
# Source the file in ~/.bashrc
. ~/.ideas-complete.bash
Zsh
# Save the script somewhere.
_IDEAS_COMPLETE=zsh_source ideas > ~/.ideas-complete.zsh
# Source the file in ~/.zshrc.
. ~/.ideas-complete.zsh
Fish
# Save the script to ~/.config/fish/completions/ideas.fish:
_IDEAS_COMPLETE=fish_source ideas > ~/.config/fish/completions/ideas.fish
After modifying the shell config, you need to start a new shell in order for the changes to be loaded.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file ideas_python-1.3.0-py3-none-any.whl.
File metadata
- Download URL: ideas_python-1.3.0-py3-none-any.whl
- Upload date:
- Size: 132.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.9.17 {"installer":{"name":"uv","version":"0.9.17","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
1eddf25818d9d68c8e86f9c82942a5bd454451613318cdc0f7a8556d8fe58b70
|
|
| MD5 |
80a0b15a85153094f1d5239474149146
|
|
| BLAKE2b-256 |
d30261912cbfedb25aaeda100227200dbb48564bcf7acd163f4568c6d8e27576
|