productivity
ClickSend CLI for AI Agents
Use the ClickSend CLI from KosmoKrator to call ClickSend tools headlessly, return JSON, inspect schemas, and automate workflows from coding agents, scripts, and CI.ClickSend CLI Setup
ClickSend can be configured headlessly with `kosmokrator integrations:configure clicksend`.
# Install KosmoKrator first if it is not available on PATH.
curl -fsSL https://raw.githubusercontent.com/OpenCompanyApp/kosmokrator/main/install.sh | bash
# Configure and verify this integration.
kosmokrator integrations:configure clicksend --set username="$CLICKSEND_USERNAME" --set api_key="$CLICKSEND_API_KEY" --enable --read allow --write ask --json
kosmokrator integrations:doctor clicksend --json
kosmokrator integrations:status --json Credentials
Authentication type: API key api_key. Configure credentials once, then reuse the same stored profile from scripts, coding CLIs, Lua, and MCP.
| Key | Env var | Type | Required | Label |
|---|---|---|---|---|
username | CLICKSEND_USERNAME | Text text | yes | Username |
api_key | CLICKSEND_API_KEY | Secret secret | yes | API Key |
Command Patterns
The generic command is stable across every integration. The provider shortcut is shorter for humans.
kosmo integrations:call clicksend.clicksend_get_account_balance '{}' --json kosmo integrations:clicksend clicksend_get_account_balance '{}' --json Discovery
These commands return structured output for coding agents that need to inspect capabilities before choosing a function.
kosmo integrations:docs clicksend --json
kosmo integrations:docs clicksend.clicksend_get_account_balance --json
kosmo integrations:schema clicksend.clicksend_get_account_balance --json
kosmo integrations:search "ClickSend" --json
kosmo integrations:list --json Automation Contexts
The same configured command surface works in these environments. The command does not change unless the host wrapper, credentials, or permissions change.
CLI Functions
Every function below can be called headlessly. Commands are highlighted, copyable, and scroll horizontally when payloads are long.
clicksend.clicksend_get_account_balance
Get the current ClickSend account balance.
read - Parameters
- none
kosmo integrations:call clicksend.clicksend_get_account_balance '{}' --json kosmo integrations:clicksend clicksend_get_account_balance '{}' --json clicksend.clicksend_get_email_history
Get email message history from ClickSend with pagination.
read - Parameters
- limit, page
kosmo integrations:call clicksend.clicksend_get_email_history '{"limit":1,"page":1}' --json kosmo integrations:clicksend clicksend_get_email_history '{"limit":1,"page":1}' --json clicksend.clicksend_get_sms_history
Get SMS message history from ClickSend. Supports date range filtering and pagination.
read - Parameters
- date_from, date_to, limit, page
kosmo integrations:call clicksend.clicksend_get_sms_history '{"date_from":"example_date_from","date_to":"example_date_to","limit":1,"page":1}' --json kosmo integrations:clicksend clicksend_get_sms_history '{"date_from":"example_date_from","date_to":"example_date_to","limit":1,"page":1}' --json clicksend.clicksend_get_sms_price
Get pricing for SMS messages before sending. Uses the same message format as send SMS but returns cost estimates only.
read - Parameters
- messages
kosmo integrations:call clicksend.clicksend_get_sms_price '{"messages":"example_messages"}' --json kosmo integrations:clicksend clicksend_get_sms_price '{"messages":"example_messages"}' --json clicksend.clicksend_get_voice_history
Get voice message history from ClickSend with pagination.
read - Parameters
- limit, page
kosmo integrations:call clicksend.clicksend_get_voice_history '{"limit":1,"page":1}' --json kosmo integrations:clicksend clicksend_get_voice_history '{"limit":1,"page":1}' --json clicksend.clicksend_list_contact_lists
List all contact lists from ClickSend with pagination.
read - Parameters
- limit, page
kosmo integrations:call clicksend.clicksend_list_contact_lists '{"limit":1,"page":1}' --json kosmo integrations:clicksend clicksend_list_contact_lists '{"limit":1,"page":1}' --json clicksend.clicksend_send_email
Send an email message via ClickSend. Requires recipient, subject, and body.
write - Parameters
- to, subject, body, from_email_address, from_name
kosmo integrations:call clicksend.clicksend_send_email '{"to":"example_to","subject":"example_subject","body":"example_body","from_email_address":"example_from_email_address","from_name":"example_from_name"}' --json kosmo integrations:clicksend clicksend_send_email '{"to":"example_to","subject":"example_subject","body":"example_body","from_email_address":"example_from_email_address","from_name":"example_from_name"}' --json clicksend.clicksend_send_post_letter
Send a post letter via ClickSend. Provide a file URL or template ID with recipient details.
write - Parameters
- file_url, template_id, recipients, duplex
kosmo integrations:call clicksend.clicksend_send_post_letter '{"file_url":"example_file_url","template_id":1,"recipients":"example_recipients","duplex":1}' --json kosmo integrations:clicksend clicksend_send_post_letter '{"file_url":"example_file_url","template_id":1,"recipients":"example_recipients","duplex":1}' --json clicksend.clicksend_send_sms
Send one or more SMS messages via ClickSend. Each message requires a "to" phone number and "body" text.
write - Parameters
- messages
kosmo integrations:call clicksend.clicksend_send_sms '{"messages":"example_messages"}' --json kosmo integrations:clicksend clicksend_send_sms '{"messages":"example_messages"}' --json clicksend.clicksend_send_voice
Send one or more voice messages via ClickSend. Each message requires a "to" phone number and "body" text.
write - Parameters
- messages
kosmo integrations:call clicksend.clicksend_send_voice '{"messages":"example_messages"}' --json kosmo integrations:clicksend clicksend_send_voice '{"messages":"example_messages"}' --json Function Schemas
Use these parameter tables when building CLI payloads without calling integrations:schema first.
clicksend.clicksend_get_account_balance 0 parameters
kosmo integrations:schema clicksend.clicksend_get_account_balance --json | Parameter | Type | Required | Description |
|---|---|---|---|
| No parameters. | |||
clicksend.clicksend_get_email_history 2 parameters
kosmo integrations:schema clicksend.clicksend_get_email_history --json | Parameter | Type | Required | Description |
|---|---|---|---|
limit | integer | no | Number of records per page (default 15). |
page | integer | no | Page number for pagination (default 1). |
clicksend.clicksend_get_sms_history 4 parameters
kosmo integrations:schema clicksend.clicksend_get_sms_history --json | Parameter | Type | Required | Description |
|---|---|---|---|
date_from | string | no | Start date for history (YYYY-MM-DD or Unix timestamp). |
date_to | string | no | End date for history (YYYY-MM-DD or Unix timestamp). |
limit | integer | no | Number of records per page (default 15). |
page | integer | no | Page number for pagination (default 1). |
clicksend.clicksend_get_sms_price 1 parameters
kosmo integrations:schema clicksend.clicksend_get_sms_price --json | Parameter | Type | Required | Description |
|---|---|---|---|
messages | array | yes | Array of message objects. Each object must have "to" (phone number) and "body" (text). Optional: "from" (sender ID). |
clicksend.clicksend_get_voice_history 2 parameters
kosmo integrations:schema clicksend.clicksend_get_voice_history --json | Parameter | Type | Required | Description |
|---|---|---|---|
limit | integer | no | Number of records per page (default 15). |
page | integer | no | Page number for pagination (default 1). |
clicksend.clicksend_list_contact_lists 2 parameters
kosmo integrations:schema clicksend.clicksend_list_contact_lists --json | Parameter | Type | Required | Description |
|---|---|---|---|
limit | integer | no | Number of records per page (default 15). |
page | integer | no | Page number for pagination (default 1). |
clicksend.clicksend_send_email 5 parameters
kosmo integrations:schema clicksend.clicksend_send_email --json | Parameter | Type | Required | Description |
|---|---|---|---|
to | string | yes | Recipient email address. |
subject | string | yes | Email subject line. |
body | string | yes | Email body content (HTML supported). |
from_email_address | string | no | Sender email address. |
from_name | string | no | Sender display name. |
clicksend.clicksend_send_post_letter 4 parameters
kosmo integrations:schema clicksend.clicksend_send_post_letter --json | Parameter | Type | Required | Description |
|---|---|---|---|
file_url | string | no | URL to the PDF file to send as a letter. |
template_id | integer | no | ClickSend template ID to use instead of a file URL. |
recipients | array | yes | Array of recipient objects with name, address, city, state, postal_code, country. |
duplex | integer | no | Print on both sides: 0 for simplex, 1 for duplex (default 0). |
clicksend.clicksend_send_sms 1 parameters
kosmo integrations:schema clicksend.clicksend_send_sms --json | Parameter | Type | Required | Description |
|---|---|---|---|
messages | array | yes | Array of message objects. Each object must have "to" (phone number) and "body" (text). Optional: "from" (sender ID). |
clicksend.clicksend_send_voice 1 parameters
kosmo integrations:schema clicksend.clicksend_send_voice --json | Parameter | Type | Required | Description |
|---|---|---|---|
messages | array | yes | Array of voice message objects. Each object must have "to" (phone number) and "body" (text). Optional: "voice" (voice type), "lang" (language code). |
Permissions
Headless calls still follow the integration read/write permission policy. Configure read/write defaults with
integrations:configure. Add --force only for trusted automation that should bypass that policy.