To run any Op, you will need an account for The Ops Platform. Please sign up here.
Installing the CLI will allow you to:
Installing our Slack App will allow you to:
To see the Slack App installation process, click here.
You will need:
To install the Ops CLI, run:
npm install -g '@cto.ai/ops'
Once installed, run:
This should display:
You can sign in to your Ops account with:
Once you are signed in, you can now run Ops with:
ops run <op name>
Try our demo Op
@cto.ai/hello-world or take a look through our registry.
To start a new Op, run:
Follow the interactive prompts to configure initial properties of your Op:
Type of Op: A
command is a single Op while a
workflow can be a series of Ops.
Name: Your Op's name will be used in URLs, folders, and on the command line. For this reason, it needs to be alphanumeric, lowercase, and all-one-word. You can also include dashes (
-) and underscores (
Description: Please enter a short description of what your Op does.
Version: You can enter any version identification information here, or press Enter to use the default.
Once you've completed this initial configuration, a folder with scaffold code will be generated. You are now ready to code!
After adding in your own code, build the op with:
ops build <path to op>
and you can now run your new Op locally.
Ops are shared via teams. By default, a team will be created with the same name as your username. You can verify this with:
You may prefer to keep this private for testing. To create a new team, run:
You can switch between active teams freely with:
You can invite others to the team with:
Once you are on your preferred team, you will need to publish your Op onto that team. Run:
ops publish <path to op>
allowing them to run your Op.
You can see the public ops with:
or take a look through our registry.
To see the CLI installation process, click here.
You can install our Slack app onto your Workspace here.
Once completed, you will be able to see the CTO.ai app in the lower left hand corner of your Slack workspace under Recent Apps.
While the command to run Ops in the CLI is
ops run <op-name>, in Slack the command is
/ops run <op-name>.
Prior to running Ops in Slack, you will need to:
Link your Ops account to your Slack account.
Link an Ops team* to a Slack channel.
/ops run will default to getting you set up if you have not yet done so.
*Ops are published onto an Ops team to be shared. By default, the team name is the same name as the account.
Once everything has been linked, you can now run your Ops.
For other people to begin running Ops, they will need to link an Ops account to their own Slack account. This can still be done with
When there is an Ops team already linked to a Slack channel,
/ops run will first check if the user (based on the Ops account) is a member of that Ops team. If they aren't, a prompt will appear allowing them to request an invitation. Simply check the CTO.ai Slack app for notifications.