Skip to content

Agents: getting started

This page describes the recommended order of steps for an AI agent (or any terminal-first automation) that needs to start working in Operately.

Usually no. Every step below can be done from a terminal, including joining an organization from an invite and getting an API token. Use the web app only for things the CLI cannot do for you, such as completing Google sign-in in a browser or reading the verification email.

  1. Install the CLI.
  2. Optionally install the Operately skills.
  3. Join an organization or sign up.
  4. Get an API token (this happens as part of step 3 or step 5).
  5. Log in with operately auth login.
  6. Use the CLI from then on.
Terminal window
npm install -g @operately/operately-cli
operately --version

See CLI install and update for details.

Skills are an optional guidance layer. They teach compatible agent tools how to work with the Operately CLI and common workflows, but the CLI works without them.

Terminal window
npx skills add https://github.com/operately/skills --skill operately-cli

See CLI skills for more options.

Pick the path that matches your situation.

Take the invite token from the invite link and run:

Terminal window
operately auth join --invite-token <token>

The CLI signs you in (or creates your account), accepts the invite, creates an API token for you, and saves it to your local profile. You do not need to open the web app or visit the API Tokens page.

To skip prompts, pass the sign-in details as flags, for example --method email-password --email <email> --password <password>. Creating a new account still requires entering the verification code that Operately emails to the address you use, so the agent needs access to that inbox.

Terminal window
operately auth signup

After signing up you can create a company or join one with an invite. You can pass --next-step create-company, --next-step join, or --next-step later. Signup also creates and saves an API token. See Sign up and create a company with the CLI.

You do not have to click through API Tokens in the web app. The CLI creates the token for you:

  • operately auth join and operately auth signup create a full-access token and save it to your profile when they finish.
  • operately auth login with email and password or an email code creates a token for an account that already exists. Choose the access level with --access-mode read-only or --access-mode full-access, and pick the organization with --company-id or --company-name.
Terminal window
operately auth login \
--method email-password \
--email <email> \
--password <password> \
--company-name "<organization name>" \
--access-mode full-access

If a token already exists, for example one provided to the agent by a human through Create an API token, log in with it directly:

Terminal window
operately auth login --token <token>

For self-hosted instances, add --base-url https://operately.example.com. See CLI authentication for profiles, environment variables, and the resolution order.

Verify the session:

Terminal window
operately auth whoami

From here on, discover and run commands with the built-in help:

Terminal window
operately help
operately people get_me

See Use the CLI for the command shape, and the API docs for every endpoint.