Skip to main content

TM1-CLI

PyPI - License PyPI - Version

TM1-CLI is a command-line interface (CLI) tool to interact with TM1 servers using TM1py.


Features

  • Easily execute TM1 functions via the command line.
  • Manage multiple connection settings with databases.yaml file.
  • Built with Python, powered by Typer for intuitive CLI design.

Installation

Using pip

Install the package directly from PyPI:

pip install tm1cli

Develop locally on linux

Clone the repository and install using Poetry

git clone https://github.com/onefloid/tm1cli.git
cd tm1cli
python -m venv .venv
source .source .venv/bin/activate
poetry install

Usage

Commands

Connect to a TM1 server and print its version:

tm1cli tm1-version
tm1cli threads
tm1cli whoami

tm1cli process list
tm1cli process exists <process_name>
tm1cli process clone --from <source_db> --to <target_db>
tm1cli process dump <name> --folder <path> --format <json|yaml>
tm1cli process load <name> --folder <path> --format <json|yaml>

tm1cli cube list
tm1cli cube exists <cube_name> --watch

tm1cli dimension list
tm1cli dimension exists <dimension_name> -w

tm1cli view list <cube_name>
tm1cli view exists <cube_name> <view_name>

tm1cli subset list <dimension_name>
tm1cli subset exists <dimension_name> <subset_name>

All Available Commands

Run the following to see all available commands:

tm1cli --help

Output formatting

By default, exists commands print a human-readable result, e.g. ✅ Cube exists!. Pass the global --output-raw flag before the command to get the raw True/False value instead, e.g. for scripting:

tm1cli --output-raw cube exists <cube_name>

Configuration

Connection settings are stored in a databases.yaml file. Here's an example:

databases:
  - name: mydb
    address: localhost
    port: 10001
    ssl: false
    user: admin
    password: ""

  - name: myremotedb
    address: tm1.example.com
    port: 20000
    ssl: false
    user: admin
    password: apple

If no databases.yaml file is found, tm1cli will look for environment variables starting with TM1_ and use them as the default database configuration.

For example, if you set the following environment variables, tm1cli will use them and will work just like in the configuration file example above:

  export TM1_ADDRESS=localhost
  export TM1_PORT=10001
  export TM1_SSL=false
  export TM1_USER=admin
  export TM1_PASSWORD=""

Notice: The clone command and the --database option are only supported with a databases.yaml file.

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

tm1cli-0.2.0.tar.gz (7.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

tm1cli-0.2.0-py3-none-any.whl (12.3 kB view details)

Uploaded Python 3

File details

Details for the file tm1cli-0.2.0.tar.gz.

File metadata

  • Download URL: tm1cli-0.2.0.tar.gz
  • Upload date:
  • Size: 7.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for tm1cli-0.2.0.tar.gz
Algorithm Hash digest
SHA256 ebbcdc291e51b9193da5c5fe7188063d9ef9270ecb1ef385df1c1059916e0e41
MD5 5cb746f93508debfafead6621730a098
BLAKE2b-256 e7ed42514a30a7d553b0fee259e62fed63c659be49b31c508d7ee94762650adb

See more details on using hashes here.

Provenance

The following attestation bundles were made for tm1cli-0.2.0.tar.gz:

Publisher: pypi-publish.yml on onefloid/tm1cli

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file tm1cli-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: tm1cli-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 12.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for tm1cli-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 c72d1fafa0dc4434ddfd80f711608935d07b550e83a6472101d181d2f0807d9c
MD5 68926425fd279d97348f4e886bbd4b36
BLAKE2b-256 f25a35152ef911dc37155fe8b141b9c042dd2114a9d04dac19f3272a42d3e526

See more details on using hashes here.

Provenance

The following attestation bundles were made for tm1cli-0.2.0-py3-none-any.whl:

Publisher: pypi-publish.yml on onefloid/tm1cli

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Release history Release notifications | RSS feed

This release

0.2.0 This release

2 files

0.1.7

2 files

0.1.6

2 files

0.1.5

2 files

0.1.4

2 files

0.1.3

2 files

0.1.2

2 files

0.1.1

2 files

0.1.0

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page