INNER CODE UNIT · TypeScript
getAgent
gobii-ai/gobii-platform · misc/ts-example-client/src/index.ts:134
async function getAgent(agentId: string): Promise<AgentDetail | null> {
console.log(`Input Agent ID: ${agentId}`);
return handleApiCall('Get Agent Details', () =>
browserUseApi.getAgent(agentId)
);
}
async function updateAgentName(
agentId: string,
newName: string
): Promise<AgentDetail | null> {
console.log(`Input Agent ID: ${agentId}`);
console.log(`Input New Name: ${newName}`);
return handleApiCall('Update Agent Name', () =>
browserUseApi.updateAgent(agentId, { name: newName })
);
}