import { APIResource } from "../../core/resource.mjs"; import * as AgentsAPI from "./agents.mjs"; import { APIPromise } from "../../core/api-promise.mjs"; import { RequestOptions } from "../../internal/request-options.mjs"; /** * Endpoints for creating and managing agents (experimental), called by the partner's backend using platform credentials. Covers the full agent lifecycle: creation, policy configuration, pausing, deletion, the device code installation flow, and approving or rejecting transactions initiated by agents. */ export declare class DeviceCodes extends APIResource { /** * Check whether a device code has been redeemed. Use this to poll for agent * installation completion after creating an agent. * * @example * ```ts * const agentDeviceCodeStatusResponse = * await client.agents.deviceCodes.getStatus('code'); * ``` */ getStatus(code: string, options?: RequestOptions): APIPromise; /** * Redeem a device code to obtain agent credentials. This endpoint is called by the * agent software during installation. On success, returns a Bearer access token * that the agent uses for all subsequent API calls. The token is returned only * once and must be stored securely. This endpoint does not require platform * authentication — the device code itself serves as proof of authorization. * * @example * ```ts * const agentDeviceCodeRedeemResponse = * await client.agents.deviceCodes.redeem('code'); * ``` */ redeem(code: string, options?: RequestOptions): APIPromise; /** * Generate a new device code for an existing agent. Use this when the original * device code has expired before being redeemed, or when the agent software needs * to be reinstalled. Any previously issued unredeemed device codes for this agent * are invalidated. * * @example * ```ts * const agentDeviceCode = * await client.agents.deviceCodes.regenerate('agentId'); * ``` */ regenerate(agentID: string, options?: RequestOptions): APIPromise; } //# sourceMappingURL=device-codes.d.mts.map