Skip to main content

Overview


Command Line Interface

The iMerit Command Line Interface (CLI) allows you to manage your anotation projects from the terminal. The iMerit CLI is a Python package hosted on GitHub.

Installation

Install the imerit-python Python package using pip.

tip

The imerit-python package is not yet available on PyPA (coming soon). In the meantime, you can install it directly from GitHub.

Here is how you install it in a new directory, with a Python virtual environment.

mkdir my-project
cd my-project

Create the virtual environment:

python3 -m venv .venv

Activate the virtual environment:

# bash shell
source .venv/bin/activate
# csh shell
source .venv/bin/activate.csh
# fish shell
source .venv/bin/activate.fish

Install imerit-python:

pip install git+https://github.com/imerit-io/imerit-python

Getting your API key

Your API key will be provided to you by your iMerit representative.

Copy/paste the API key and set it as environment variable on your command line:

export IMERIT_API_KEY=7055f8979067eb5cb99121c509af62779

Verify that your setup is O.K. by listing the organizations you have access to:

imerit organization list

Expected output:

Showing organizations:

> ORGANIZATIONS

ID NAME CREATED_AT UPDATED_AT
------------------------------------ ----------- ------------------- -------------------
1b5279cf-0f51-4e64-8ecd-bca36aab47d2 Valbois Inc 2021-10-14T15:02:10 2023-08-17T15:02:10

tip

If you work with a single organization, set the follwing environment variable so you don't have to pass it to every command:

export IMERIT_ORGANIZATION_ID=1b5279cf-0f51-4e64-8ecd-bca36aab47d2
Getting Help
imerit organization --help

You're are all set!