Cloud Commands
You can create custom commands in ClickUp, including:
- Link commands which open a URL.
- Clipboard commands which allow you to copy and paste content.
- Cloud commands which allows developers to build fully customizable and interactive commands.
To create and use Cloud Commands, you'll need to create an endpoint on the web that returns a JSON Command Response to perform a customized command.
When you run a Cloud Command:
- ClickUp sends a request to your specified HTTPS endpoint.
- The endpoint reads the request and responds with your customized JSON Command Response.
- ClickUp receieves the Command Response and performs the specified operations.
Create an HTTPS endpoint
You can try using Replit to create an endpoint in a few clicks, either starting from scratch or forking these examples:
👍 Tip By default, Repls aren't always running. If you plan to use the Command often or to share it with others, you'll need to make sure the Repl is set to be Always On.
Customize your JSON Command Response
Your JSON Command Response defines the operations that the Cloud Command will perform.
The most basic thing a Cloud Command can do is return an action as the Command Response. An action just tells ClickUp to do something, such as open a URL.
👀 Note These examples will be written in JavaScript, but you can use any supported language you are comfortable with.
Open a URL
The following example opens the specified URL in your default web browser.
{
const response = {
action: {
type: "open-url",
url: "https://clickup.com/"
}
}
// Print the response as JSON string
console.log(JSON.stringify(response));
}
Add text to the Clipboard
Another type of Action is to add something to your Clipboard so you can paste it anywhere.
{
const response = {
action: {
type: "copy",
value: "Ahoy world!"
}
}
// Print the response as JSON string
console.log(JSON.stringify(response));
}