Complete API reference for the Kubiya Agents service methods and classes
access
(_Access
): Manage user and group access permissionsenv
(_Env
): Handle environment variablesintegrations
(_Integrations
): Manage agent integrationsprompt
(_Prompt
): Configure AI instructions and promptssecrets
(_Secrets
): Manage agent secretstools
(_Tools
): Handle tool attachments and configurationslist(sort_by: str = "name", filter_term: str = "", limit: int = 100, show_active: bool = False) -> Dict[str, Any]
sort_by
(str
): Sort by field (“name”, “created”, “updated”). Default: “name”filter_term
(str
): Filter agents (supports partial matching on name, description, instruction_type, llm_model, and integrations). Default: ""limit
(int
): Limit number of results. Default: 100show_active
(bool
): Show only active agents (agents with runners and sources). Default: FalseList[Dict[str, Any]]
: List of agent dictionariesAgentError
: For listing-specific errorsget(agent_uuid: str) -> Dict[str, Any]
agent_uuid
(str
): UUID of the agent to retrieveDict[str, Any]
: Dictionary containing complete agent detailsAgentError
: For get-specific errors (e.g., agent not found)create(...) -> Dict[str, Any]
name
(str
): Agent name (required)description
(str
): Agent description. Default: ""llm_model
(str
): LLM model to use (“claude-4-sonnet”, “claude-4-opus”, “gpt-4o”). Default: “claude-4-sonnet”instruction_type
(str
): Type of instructions. Default: “natural_language”sources
(Optional[List[str]]
): List of source UUIDs to attach. Default: []secrets
(Optional[List[str]]
): List of secret names to attach. Default: []integrations
(Optional[List[str]]
): List of integrations to attach. Default: []environment
(Optional[Dict[str, str]]
): Environment variables dict. Default: runners
(Optional[List[str]]
): List of runner names. Default: [“gke-poc-kubiya”]ai_instructions
(str
): Custom AI instructions. Default: ""is_debug_mode
(bool
): Enable debug mode. Default: Falseowners
(Optional[List[str]]
): List of owner identifiers. Default: []allowed_users
(Optional[List[str]]
): List of allowed user identifiers. Default: []allowed_groups
(Optional[List[str]]
): List of allowed group identifiers. Default: []tools
(Optional[List[str]]
): List of tool identifiers. Default: []image
(str
): Docker image for the agent. Default: “ghcr.io/kubiyabot/kubiya-agent:stable”**kwargs
: Additional agent propertiesDict[str, Any]
: Dictionary containing created agent details including UUIDAgentError
: For creation-specific errorsdelete(agent_uuid: str) -> Dict[str, Any]
agent_uuid
(str
): UUID of the agent to deleteDict[str, Any]
: Dictionary containing deletion statusAgentError
: For deletion-specific errorsedit(agent_uuid: str, ...) -> Dict[str, Any]
agent_uuid
(str
): UUID of the agent to edit (required)name
(Optional[str]
): New agent namedescription
(Optional[str]
): New agent descriptionllm_model
(Optional[str]
): New LLM modelai_instructions
(Optional[str]
): New AI instructionsadd_sources
(Optional[List[str]]
): Sources to addremove_sources
(Optional[List[str]]
): Sources to removeadd_secrets
(Optional[List[str]]
): Secrets to addremove_secrets
(Optional[List[str]]
): Secrets to removeadd_env_vars
(Optional[Dict[str, str]]
): Environment variables to add/updateremove_env_vars
(Optional[List[str]]
): Environment variable keys to removeadd_integrations
(Optional[List[str]]
): Integrations to addremove_integrations
(Optional[List[str]]
): Integrations to removeadd_tools
(Optional[List[str]]
): Tools to addremove_tools
(Optional[List[str]]
): Tools to removeadd_allowed_users
(Optional[List[str]]
): Users to add to allowed listremove_allowed_users
(Optional[List[str]]
): Users to remove from allowed listadd_allowed_groups
(Optional[List[str]]
): Groups to add to allowed listremove_allowed_groups
(Optional[List[str]]
): Groups to remove from allowed listrunners
(Optional[List[str]]
): List of runners to set**kwargs
: Additional fields to updateDict[str, Any]
: Dictionary containing updated agent detailsAgentError
: For edit-specific errorsmodel(agent_uuid: str, llm_model: str) -> Dict[str, Any]
agent_uuid
(str
): UUID of the agentllm_model
(str
): LLM model to set (“claude-4-sonnet”, “claude-4-opus”, “gpt-4o”)Dict[str, Any]
: Dictionary containing operation resultAgentError
: For model-specific errorsValidationError
: For unsupported model namesrunner(agent_uuid: str, runner_name: str) -> Dict[str, Any]
agent_uuid
(str
): UUID of the agentrunner_name
(str
): Name of the runner to setDict[str, Any]
: Dictionary containing operation resultAgentError
: For runner-specific errorsshow(agent_uuid: str) -> Dict[str, Any]
agent_uuid
(str
): UUID of the agentDict[str, Any]
: Dictionary containing access control informationclear(agent_uuid: str) -> Dict[str, Any]
agent_uuid
(str
): UUID of the agentDict[str, Any]
: Dictionary containing operation resultadd_user(agent_uuid: str, users: List[str]) -> Dict[str, Any]
agent_uuid
(str
): UUID of the agentusers
(List[str]
): List of user identifiers to addDict[str, Any]
: Dictionary containing operation resultremove_user(agent_uuid: str, users: List[str]) -> Dict[str, Any]
agent_uuid
(str
): UUID of the agentusers
(List[str]
): List of user identifiers to removeDict[str, Any]
: Dictionary containing operation resultadd_group(agent_uuid: str, groups: List[str]) -> Dict[str, Any]
agent_uuid
(str
): UUID of the agentgroups
(List[str]
): List of group identifiers to addDict[str, Any]
: Dictionary containing operation resultremove_group(agent_uuid: str, groups: List[str]) -> Dict[str, Any]
agent_uuid
(str
): UUID of the agentgroups
(List[str]
): List of group identifiers to removeDict[str, Any]
: Dictionary containing operation resultlist(agent_uuid: str) -> Dict[str, Any]
agent_uuid
(str
): UUID of the agentDict[str, Any]
: Dictionary containing environment variablesset(agent_uuid: str, env_vars: Dict[str, str]) -> Dict[str, Any]
agent_uuid
(str
): UUID of the agentenv_vars
(Dict[str, str]
): Environment variables to set (key-value pairs)Dict[str, Any]
: Dictionary containing operation resultunset(agent_uuid: str, keys: List[str]) -> Dict[str, Any]
agent_uuid
(str
): UUID of the agentkeys
(List[str]
): Environment variable keys to unsetDict[str, Any]
: Dictionary containing operation resultlist(agent_uuid: str) -> Dict[str, Any]
agent_uuid
(str
): UUID of the agentDict[str, Any]
: Dictionary containing integrationsadd(agent_uuid: str, integrations: List[str]) -> Dict[str, Any]
agent_uuid
(str
): UUID of the agentintegrations
(List[str]
): List of integration names to addDict[str, Any]
: Dictionary containing operation resultremove(agent_uuid: str, integrations: List[str]) -> Dict[str, Any]
agent_uuid
(str
): UUID of the agentintegrations
(List[str]
): List of integration names to removeDict[str, Any]
: Dictionary containing operation resultget(agent_uuid: str) -> Dict[str, Any]
agent_uuid
(str
): UUID of the agentDict[str, Any]
: Dictionary containing AI instructionsset(...) -> Dict[str, Any]
agent_uuid
(str
): UUID of the agentcontent
(Optional[str]
): Prompt content to setfile_path
(Optional[str]
): Path to file containing prompt contenturl
(Optional[str]
): URL to fetch prompt content fromcontent
, file_path
, or url
must be provided.
Returns:
Dict[str, Any]
: Dictionary containing operation resultValidationError
: If no content source is provided or file/URL access failsappend(...) -> Dict[str, Any]
agent_uuid
(str
): UUID of the agentcontent
(Optional[str]
): Prompt content to appendfile_path
(Optional[str]
): Path to file containing prompt contenturl
(Optional[str]
): URL to fetch prompt content fromcontent
, file_path
, or url
must be provided.
Returns:
Dict[str, Any]
: Dictionary containing operation resultclear(agent_uuid: str) -> Dict[str, Any]
agent_uuid
(str
): UUID of the agentDict[str, Any]
: Dictionary containing operation resultlist(agent_uuid: str) -> Dict[str, Any]
agent_uuid
(str
): UUID of the agentDict[str, Any]
: Dictionary containing secretsadd(agent_uuid: str, secrets: List[str]) -> Dict[str, Any]
agent_uuid
(str
): UUID of the agentsecrets
(List[str]
): List of secret names to addDict[str, Any]
: Dictionary containing operation resultremove(agent_uuid: str, secrets: List[str]) -> Dict[str, Any]
agent_uuid
(str
): UUID of the agentsecrets
(List[str]
): List of secret names to removeDict[str, Any]
: Dictionary containing operation resultlist(agent_uuid: str) -> Dict[str, Any]
agent_uuid
(str
): UUID of the agentDict[str, Any]
: Dictionary containing toolsadd(agent_uuid: str, tools: List[str]) -> Dict[str, Any]
agent_uuid
(str
): UUID of the agenttools
(List[str]
): List of tool names/IDs to addDict[str, Any]
: Dictionary containing operation resultremove(agent_uuid: str, tools: List[str]) -> Dict[str, Any]
agent_uuid
(str
): UUID of the agenttools
(List[str]
): List of tool names/IDs to removeDict[str, Any]
: Dictionary containing operation resultdescribe(agent_uuid: str, tool_name: str) -> Dict[str, Any]
agent_uuid
(str
): UUID of the agenttool_name
(str
): Specific tool name to describeDict[str, Any]
: Dictionary containing tool descriptionAgentError
exceptions with specific context: