Skip to main content

Get

Returns the specified agent.

To get the list of all available agents, make a List request.

import { cloudApi, serviceClients, Session } from "@yandex-cloud/nodejs-sdk";

const GetAgentRequest = cloudApi.loadtesting.api_agent_service.GetAgentRequest;

(async () => {
const authToken = process.env["YC_OAUTH_TOKEN"];
const session = new Session({ oauthToken: authToken });
const client = session.client(serviceClients.AgentServiceClient);

const result = await client.get(
GetAgentRequest.fromPartial({
// agentId: "agentId"
})
);
console.log(result);
})();

GetAgentRequest

agentId : string

ID of the agent to return.

Agent

Load testing agent on which tests are executed.

id : string

ID of the agent. Generated at creation time.

folderId : string

ID of the folder that the agent belongs to.

name : string

Name of the agent.

description : string

Description of the agent.

computeInstanceId : string

ID of the compute instance managed by the agent.

Empty if there is no such instance (i.e. the case of external agent).

status : Status

Status of the agent.

errors : string

List of errors reported by the agent.

currentJobId : string

ID of the test that is currently being executed by the agent.

agentVersionId : string

Version of the agent.

labels : string

Agent labels as key:value pairs.

logSettings : agent.LogSettings

Agent log settings

LogSettings

cloudLogGroupId : string

Id of Yandex Cloud log group to upload agent logs to