Skip to main content
GET
/
v1
/
agents
/
{agent_id}
/
tools
List Agent Tools
curl --request GET \
  --url https://api.xpander.ai/v1/agents/{agent_id}/tools \
  --header 'x-api-key: <api-key>'
import requests

url = "https://api.xpander.ai/v1/agents/{agent_id}/tools"

headers = {"x-api-key": "<api-key>"}

response = requests.get(url, headers=headers)

print(response.text)
const options = {method: 'GET', headers: {'x-api-key': '<api-key>'}};

fetch('https://api.xpander.ai/v1/agents/{agent_id}/tools', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));
<?php

$curl = curl_init();

curl_setopt_array($curl, [
CURLOPT_URL => "https://api.xpander.ai/v1/agents/{agent_id}/tools",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"x-api-key: <api-key>"
],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
package main

import (
"fmt"
"net/http"
"io"
)

func main() {

url := "https://api.xpander.ai/v1/agents/{agent_id}/tools"

req, _ := http.NewRequest("GET", url, nil)

req.Header.Add("x-api-key", "<api-key>")

res, _ := http.DefaultClient.Do(req)

defer res.Body.Close()
body, _ := io.ReadAll(res.Body)

fmt.Println(string(body))

}
HttpResponse<String> response = Unirest.get("https://api.xpander.ai/v1/agents/{agent_id}/tools")
.header("x-api-key", "<api-key>")
.asString();
require 'uri'
require 'net/http'

url = URI("https://api.xpander.ai/v1/agents/{agent_id}/tools")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["x-api-key"] = '<api-key>'

response = http.request(request)
puts response.read_body
[
  {
    "id": "<string>",
    "name": "<string>",
    "connection_id": "<string>",
    "operation_id": "<string>",
    "operation_name": "<string>",
    "custom_function_id": "<string>",
    "mcp_id": "<string>",
    "allowed_tools": [
      "<string>"
    ],
    "target_id": "<string>"
  }
]
{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}

Authorizations

x-api-key
string
header
required

API Key for authentication

Path Parameters

agent_id
string
required

Response

Successful Response

id
string
required

Stable handle for this attached tool. Pass it to DELETE to remove the tool.

type
enum<string>
required

The kind of attached tool.

Available options:
action,
custom_function,
mcp,
agent,
workflow
name
string | null

Human-readable tool name.

connection_id
string | null

Connector connection id. Actions only.

operation_id
string | null

Operation catalog id. Actions only.

operation_name
string | null

OpenAPI operationId. Actions only.

custom_function_id
string | null

Custom function id. Custom functions only.

mcp_id
string | null

MCP registry id. MCP only.

allowed_tools
string[] | null

Subset of MCP tools exposed. MCP only.

target_id
string | null

Referenced sub-agent or workflow id.