List
List Agent API Keys
client.agents.apiKeys.list(stringagentUuid, APIKeyListParams { page, per_page } query?, RequestOptionsoptions?): APIKeyListResponse { api_key_infos, links, meta }
/v2/gen-ai/agents/{agent_uuid}/api_keys
To list all agent API keys, send a GET request to /v2/gen-ai/agents/{agent_uuid}/api_keys
.
Parameters
agentUuid: string
Returns
List Agent API Keys
import Gradient from '@digitalocean/gradient';
const client = new Gradient();
const apiKeys = await client.agents.apiKeys.list('"123e4567-e89b-12d3-a456-426614174000"');
console.log(apiKeys.api_key_infos);
{
"api_key_infos": [
{
"created_at": "2023-01-01T00:00:00Z",
"created_by": "12345",
"deleted_at": "2023-01-01T00:00:00Z",
"name": "example name",
"secret_key": "example string",
"uuid": "123e4567-e89b-12d3-a456-426614174000"
}
],
"links": {
"pages": {
"first": "example string",
"last": "example string",
"next": "example string",
"previous": "example string"
}
},
"meta": {
"page": 123,
"pages": 123,
"total": 123
}
}
Returns Examples
{
"api_key_infos": [
{
"created_at": "2023-01-01T00:00:00Z",
"created_by": "12345",
"deleted_at": "2023-01-01T00:00:00Z",
"name": "example name",
"secret_key": "example string",
"uuid": "123e4567-e89b-12d3-a456-426614174000"
}
],
"links": {
"pages": {
"first": "example string",
"last": "example string",
"next": "example string",
"previous": "example string"
}
},
"meta": {
"page": 123,
"pages": 123,
"total": 123
}
}