KosmoKrator

productivity

Freshdesk CLI for AI Agents

Use the Freshdesk CLI from KosmoKrator to call Freshdesk tools headlessly, return JSON, inspect schemas, and automate workflows from coding agents, scripts, and CI.

Freshdesk CLI Setup

Freshdesk can be configured headlessly with `kosmokrator integrations:configure freshdesk`.

Install, configure, and verify
# 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 freshdesk --set api_key="$FRESHDESK_API_KEY" --set domain="$FRESHDESK_DOMAIN" --enable --read allow --write ask --json
kosmokrator integrations:doctor freshdesk --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.

KeyEnv varTypeRequiredLabel
api_key FRESHDESK_API_KEY Secret secret yes API Key
domain FRESHDESK_DOMAIN Text string yes Domain

Command Patterns

The generic command is stable across every integration. The provider shortcut is shorter for humans.

Generic CLI call
kosmo integrations:call freshdesk.freshdesk_list_tickets '{"page":1,"per_page":1,"filter":"example_filter","company_id":1,"requester_id":1,"email":"example_email"}' --json
Provider shortcut
kosmo integrations:freshdesk freshdesk_list_tickets '{"page":1,"per_page":1,"filter":"example_filter","company_id":1,"requester_id":1,"email":"example_email"}' --json

Discovery

These commands return structured output for coding agents that need to inspect capabilities before choosing a function.

Discovery commands
kosmo integrations:docs freshdesk --json
kosmo integrations:docs freshdesk.freshdesk_list_tickets --json
kosmo integrations:schema freshdesk.freshdesk_list_tickets --json
kosmo integrations:search "Freshdesk" --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.

freshdesk.freshdesk_list_tickets

List support tickets from Freshdesk. Supports filtering by status, priority, and pagination. Returns ticket details including subject, status, priority, requester, and assignee.

Read read
Parameters
page, per_page, filter, company_id, requester_id, email
Generic call
kosmo integrations:call freshdesk.freshdesk_list_tickets '{"page":1,"per_page":1,"filter":"example_filter","company_id":1,"requester_id":1,"email":"example_email"}' --json
Shortcut
kosmo integrations:freshdesk freshdesk_list_tickets '{"page":1,"per_page":1,"filter":"example_filter","company_id":1,"requester_id":1,"email":"example_email"}' --json

freshdesk.freshdesk_get_ticket

Get full details of a specific support ticket including description, custom fields, conversation history, and associated contacts.

Read read
Parameters
ticket_id
Generic call
kosmo integrations:call freshdesk.freshdesk_get_ticket '{"ticket_id":1}' --json
Shortcut
kosmo integrations:freshdesk freshdesk_get_ticket '{"ticket_id":1}' --json

freshdesk.freshdesk_create_ticket

Create a new support ticket. Requires a subject, description, and requester email. Optionally set priority and status.

Write write
Parameters
subject, description, email, priority, status, type, tags, group_id, assignee_id, cc_emails
Generic call
kosmo integrations:call freshdesk.freshdesk_create_ticket '{"subject":"example_subject","description":"example_description","email":"example_email","priority":1,"status":1,"type":"example_type","tags":"example_tags","group_id":1}' --json
Shortcut
kosmo integrations:freshdesk freshdesk_create_ticket '{"subject":"example_subject","description":"example_description","email":"example_email","priority":1,"status":1,"type":"example_type","tags":"example_tags","group_id":1}' --json

freshdesk.freshdesk_update_ticket

Update an existing support ticket. Can change subject, description, status, priority, assignee, and other fields.

Write write
Parameters
ticket_id, subject, description, priority, status, type, tags, group_id, assignee_id
Generic call
kosmo integrations:call freshdesk.freshdesk_update_ticket '{"ticket_id":1,"subject":"example_subject","description":"example_description","priority":1,"status":1,"type":"example_type","tags":"example_tags","group_id":1}' --json
Shortcut
kosmo integrations:freshdesk freshdesk_update_ticket '{"ticket_id":1,"subject":"example_subject","description":"example_description","priority":1,"status":1,"type":"example_type","tags":"example_tags","group_id":1}' --json

freshdesk.freshdesk_delete_ticket

Permanently delete a support ticket. This action cannot be undone.

Write write
Parameters
ticket_id
Generic call
kosmo integrations:call freshdesk.freshdesk_delete_ticket '{"ticket_id":1}' --json
Shortcut
kosmo integrations:freshdesk freshdesk_delete_ticket '{"ticket_id":1}' --json

freshdesk.freshdesk_list_contacts

List customer contacts from Freshdesk. Supports pagination. Returns contact names, emails, and company associations.

Read read
Parameters
page, per_page, email, company_id, mobile, phone
Generic call
kosmo integrations:call freshdesk.freshdesk_list_contacts '{"page":1,"per_page":1,"email":"example_email","company_id":1,"mobile":"example_mobile","phone":"example_phone"}' --json
Shortcut
kosmo integrations:freshdesk freshdesk_list_contacts '{"page":1,"per_page":1,"email":"example_email","company_id":1,"mobile":"example_mobile","phone":"example_phone"}' --json

freshdesk.freshdesk_get_contact

Get full details of a specific customer contact including email, phone, company, and custom fields.

Read read
Parameters
contact_id
Generic call
kosmo integrations:call freshdesk.freshdesk_get_contact '{"contact_id":1}' --json
Shortcut
kosmo integrations:freshdesk freshdesk_get_contact '{"contact_id":1}' --json

freshdesk.freshdesk_create_contact

Create a new customer contact in Freshdesk. Requires an email address and name.

Write write
Parameters
email, name, phone, mobile, company_id, job_title, tags
Generic call
kosmo integrations:call freshdesk.freshdesk_create_contact '{"email":"example_email","name":"example_name","phone":"example_phone","mobile":"example_mobile","company_id":1,"job_title":"example_job_title","tags":"example_tags"}' --json
Shortcut
kosmo integrations:freshdesk freshdesk_create_contact '{"email":"example_email","name":"example_name","phone":"example_phone","mobile":"example_mobile","company_id":1,"job_title":"example_job_title","tags":"example_tags"}' --json

freshdesk.freshdesk_list_agents

List all helpdesk agents. Returns agent details including name, email, availability, and group memberships.

Read read
Parameters
page, per_page
Generic call
kosmo integrations:call freshdesk.freshdesk_list_agents '{"page":1,"per_page":1}' --json
Shortcut
kosmo integrations:freshdesk freshdesk_list_agents '{"page":1,"per_page":1}' --json

freshdesk.freshdesk_get_agent

Get details of a specific helpdesk agent including name, email, role, availability, and group assignments.

Read read
Parameters
agent_id
Generic call
kosmo integrations:call freshdesk.freshdesk_get_agent '{"agent_id":1}' --json
Shortcut
kosmo integrations:freshdesk freshdesk_get_agent '{"agent_id":1}' --json

freshdesk.freshdesk_list_conversations

List all conversations on a ticket — includes public replies and private notes. Shows who posted, the body, and timestamps.

Read read
Parameters
ticket_id
Generic call
kosmo integrations:call freshdesk.freshdesk_list_conversations '{"ticket_id":1}' --json
Shortcut
kosmo integrations:freshdesk freshdesk_list_conversations '{"ticket_id":1}' --json

freshdesk.freshdesk_create_reply

Post a public reply to a support ticket. The reply is visible to the requester. Use this to respond to customers.

Write write
Parameters
ticket_id, body, cc_emails, bcc_emails
Generic call
kosmo integrations:call freshdesk.freshdesk_create_reply '{"ticket_id":1,"body":"example_body","cc_emails":"example_cc_emails","bcc_emails":"example_bcc_emails"}' --json
Shortcut
kosmo integrations:freshdesk freshdesk_create_reply '{"ticket_id":1,"body":"example_body","cc_emails":"example_cc_emails","bcc_emails":"example_bcc_emails"}' --json

freshdesk.freshdesk_create_note

Add a private note to a support ticket. Notes are only visible to agents, not to the customer. Use for internal communication.

Write write
Parameters
ticket_id, body
Generic call
kosmo integrations:call freshdesk.freshdesk_create_note '{"ticket_id":1,"body":"example_body"}' --json
Shortcut
kosmo integrations:freshdesk freshdesk_create_note '{"ticket_id":1,"body":"example_body"}' --json

freshdesk.freshdesk_list_companies

List customer companies from Freshdesk. Supports pagination. Returns company names, domains, and associated contacts.

Read read
Parameters
page, per_page
Generic call
kosmo integrations:call freshdesk.freshdesk_list_companies '{"page":1,"per_page":1}' --json
Shortcut
kosmo integrations:freshdesk freshdesk_list_companies '{"page":1,"per_page":1}' --json

freshdesk.freshdesk_get_current_user

Get the currently authenticated Freshdesk agent. Returns agent name, email, role, and availability. Use this to verify API credentials are working.

Read read
Parameters
none
Generic call
kosmo integrations:call freshdesk.freshdesk_get_current_user '{}' --json
Shortcut
kosmo integrations:freshdesk freshdesk_get_current_user '{}' --json

Function Schemas

Use these parameter tables when building CLI payloads without calling integrations:schema first.

freshdesk.freshdesk_list_tickets 6 parameters
Schema command
kosmo integrations:schema freshdesk.freshdesk_list_tickets --json
ParameterTypeRequiredDescription
page integer no Page number (default: 1).
per_page integer no Results per page (max: 100, default: 30).
filter string no Predefined filter: "new_and_my_open", "watching", "spam", "deleted".
company_id integer no Filter by company ID.
requester_id integer no Filter by requester ID.
email string no Filter by requester email.
freshdesk.freshdesk_get_ticket 1 parameters
Schema command
kosmo integrations:schema freshdesk.freshdesk_get_ticket --json
ParameterTypeRequiredDescription
ticket_id integer yes The ticket ID.
freshdesk.freshdesk_create_ticket 10 parameters
Schema command
kosmo integrations:schema freshdesk.freshdesk_create_ticket --json
ParameterTypeRequiredDescription
subject string yes Subject of the ticket.
description string yes HTML description of the ticket.
email string yes Email address of the requester.
priority integer no Priority: 1=Low, 2=Medium, 3=High, 4=Urgent.
status integer no Status: 2=Open, 3=Pending, 4=Resolved, 5=Closed.
type string no Ticket type (e.g., "Question", "Incident", "Problem").
tags array no Array of tags to assign.
group_id integer no ID of the group to assign the ticket to.
assignee_id integer no ID of the agent to assign the ticket to.
cc_emails array no Array of email addresses to CC.
freshdesk.freshdesk_update_ticket 9 parameters
Schema command
kosmo integrations:schema freshdesk.freshdesk_update_ticket --json
ParameterTypeRequiredDescription
ticket_id integer yes The ticket ID to update.
subject string no New subject.
description string no New HTML description.
priority integer no Priority: 1=Low, 2=Medium, 3=High, 4=Urgent.
status integer no Status: 2=Open, 3=Pending, 4=Resolved, 5=Closed.
type string no Ticket type.
tags array no Replace tags (array of strings).
group_id integer no Group ID to assign.
assignee_id integer no Agent ID to assign.
freshdesk.freshdesk_delete_ticket 1 parameters
Schema command
kosmo integrations:schema freshdesk.freshdesk_delete_ticket --json
ParameterTypeRequiredDescription
ticket_id integer yes The ticket ID to delete.
freshdesk.freshdesk_list_contacts 6 parameters
Schema command
kosmo integrations:schema freshdesk.freshdesk_list_contacts --json
ParameterTypeRequiredDescription
page integer no Page number (default: 1).
per_page integer no Results per page (max: 100, default: 30).
email string no Filter by contact email.
company_id integer no Filter by company ID.
mobile string no Filter by mobile number.
phone string no Filter by phone number.
freshdesk.freshdesk_get_contact 1 parameters
Schema command
kosmo integrations:schema freshdesk.freshdesk_get_contact --json
ParameterTypeRequiredDescription
contact_id integer yes The contact ID.
freshdesk.freshdesk_create_contact 7 parameters
Schema command
kosmo integrations:schema freshdesk.freshdesk_create_contact --json
ParameterTypeRequiredDescription
email string yes Email address of the contact.
name string yes Full name of the contact.
phone string no Phone number.
mobile string no Mobile number.
company_id integer no ID of the company to associate.
job_title string no Job title.
tags array no Array of tags.
freshdesk.freshdesk_list_agents 2 parameters
Schema command
kosmo integrations:schema freshdesk.freshdesk_list_agents --json
ParameterTypeRequiredDescription
page integer no Page number (default: 1).
per_page integer no Results per page (max: 100, default: 30).
freshdesk.freshdesk_get_agent 1 parameters
Schema command
kosmo integrations:schema freshdesk.freshdesk_get_agent --json
ParameterTypeRequiredDescription
agent_id integer yes The agent ID.
freshdesk.freshdesk_list_conversations 1 parameters
Schema command
kosmo integrations:schema freshdesk.freshdesk_list_conversations --json
ParameterTypeRequiredDescription
ticket_id integer yes The ticket ID.
freshdesk.freshdesk_create_reply 4 parameters
Schema command
kosmo integrations:schema freshdesk.freshdesk_create_reply --json
ParameterTypeRequiredDescription
ticket_id integer yes The ticket ID to reply to.
body string yes HTML body of the reply.
cc_emails array no Array of email addresses to CC on the reply.
bcc_emails array no Array of email addresses to BCC.
freshdesk.freshdesk_create_note 2 parameters
Schema command
kosmo integrations:schema freshdesk.freshdesk_create_note --json
ParameterTypeRequiredDescription
ticket_id integer yes The ticket ID.
body string yes HTML body of the note.
freshdesk.freshdesk_list_companies 2 parameters
Schema command
kosmo integrations:schema freshdesk.freshdesk_list_companies --json
ParameterTypeRequiredDescription
page integer no Page number (default: 1).
per_page integer no Results per page (max: 100, default: 30).
freshdesk.freshdesk_get_current_user 0 parameters
Schema command
kosmo integrations:schema freshdesk.freshdesk_get_current_user --json
ParameterTypeRequiredDescription
No parameters.

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.