Get Agent
curl --request GET \
--url https://api.agentwallex.com/api/v1/agents/{id} \
--header 'X-API-Key: <api-key>'import requests
url = "https://api.agentwallex.com/api/v1/agents/{id}"
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.agentwallex.com/api/v1/agents/{id}', 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.agentwallex.com/api/v1/agents/{id}",
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.agentwallex.com/api/v1/agents/{id}"
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.agentwallex.com/api/v1/agents/{id}")
.header("X-API-Key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.agentwallex.com/api/v1/agents/{id}")
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>",
"agent_name": "<string>",
"agent_description": "<string>",
"wallet": {
"address": "<string>",
"chain": "<string>"
},
"metadata": "<string>",
"created_at": "2023-11-07T05:31:56Z"
}{
"code": "authentication_failed",
"type": "authentication_error",
"message": "The provided API key is invalid or expired."
}{
"code": "insufficient_permissions",
"type": "authorization_error",
"message": "You do not have permission to perform this action."
}{
"code": "resource_not_found",
"type": "not_found_error",
"message": "The requested resource was not found."
}{
"code": "rate_limit_exceeded",
"type": "rate_limit_error",
"message": "Too many requests. Please retry after a short delay."
}{
"code": "server_error",
"type": "internal_error",
"message": "An unexpected error occurred. Please try again later."
}Agent
Lấy Tác nhân
Truy xuất một tác nhân theo ID, bao gồm địa chỉ ví và trạng thái hiện tại.
GET
/
api
/
v1
/
agents
/
{id}
Get Agent
curl --request GET \
--url https://api.agentwallex.com/api/v1/agents/{id} \
--header 'X-API-Key: <api-key>'import requests
url = "https://api.agentwallex.com/api/v1/agents/{id}"
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.agentwallex.com/api/v1/agents/{id}', 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.agentwallex.com/api/v1/agents/{id}",
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.agentwallex.com/api/v1/agents/{id}"
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.agentwallex.com/api/v1/agents/{id}")
.header("X-API-Key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.agentwallex.com/api/v1/agents/{id}")
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>",
"agent_name": "<string>",
"agent_description": "<string>",
"wallet": {
"address": "<string>",
"chain": "<string>"
},
"metadata": "<string>",
"created_at": "2023-11-07T05:31:56Z"
}{
"code": "authentication_failed",
"type": "authentication_error",
"message": "The provided API key is invalid or expired."
}{
"code": "insufficient_permissions",
"type": "authorization_error",
"message": "You do not have permission to perform this action."
}{
"code": "resource_not_found",
"type": "not_found_error",
"message": "The requested resource was not found."
}{
"code": "rate_limit_exceeded",
"type": "rate_limit_error",
"message": "Too many requests. Please retry after a short delay."
}{
"code": "server_error",
"type": "internal_error",
"message": "An unexpected error occurred. Please try again later."
}Truy xuất chi tiết đầy đủ của một tác nhân, bao gồm địa chỉ ví, trạng thái, metadata và dấu thời gian tạo.
Tham số Đường dẫn
string
bắt buộc
Định danh tác nhân duy nhất (ví dụ:
agent_abc123).Phản hồi
Hiện Các trường phản hồi
Hiện Các trường phản hồi
Ví dụ
curl -X GET https://api.agentwallex.com/api/v1/agents/agent_abc123 \
-H "X-API-Key: awx_your_api_key"
const agent = await aw.agents.get("agent_abc123");
agent = await aw.agents.get("agent_abc123")
Response
{
"id": "agent_abc123",
"agent_name": "research-bot",
"agent_description": "Market research automation agent",
"wallet": {
"address": "0x1234567890abcdef1234567890abcdef12345678",
"chain": "eip155:84532"
},
"status": "active",
"metadata": "{\"team\":\"growth\"}",
"created_at": "2025-06-01T10:00:00Z"
}
Ủy quyền
ApiKeyAuthBearerAuth
API key authentication. Keys are prefixed with awx_.
Tham số đường dẫn
The unique agent identifier (e.g., agent_abc123).
Phản hồi
Agent details.
An AI agent with an MPC-secured wallet.
Unique agent identifier (e.g., agent_abc123).
Agent display name.
Agent description.
An on-chain wallet associated with an agent.
Show child attributes
Show child attributes
Agent status.
Tùy chọn có sẵn:
active, inactive JSON-encoded metadata string.
ISO 8601 creation timestamp.
⌘I