asteroid-odyssey 1.1.2 → 1.2.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/generated/agents/sdk.gen.d.ts +29 -1
- package/dist/generated/agents/sdk.gen.js +95 -1
- package/dist/generated/agents/types.gen.d.ts +301 -1
- package/dist/index.d.ts +68 -1
- package/dist/index.js +118 -2
- package/package.json +6 -7
- package/dist/AgentsSDK.d.ts +0 -70
- package/dist/AgentsSDK.js +0 -102
- package/dist/Asteroid.d.ts +0 -70
- package/dist/Asteroid.js +0 -102
- package/dist/examples/index.d.ts +0 -1
- package/dist/examples/index.js +0 -33
- package/dist/generated/agents/core/ApiError.d.ts +0 -10
- package/dist/generated/agents/core/ApiError.js +0 -20
- package/dist/generated/agents/core/ApiRequestOptions.d.ts +0 -13
- package/dist/generated/agents/core/ApiRequestOptions.js +0 -2
- package/dist/generated/agents/core/ApiResult.d.ts +0 -7
- package/dist/generated/agents/core/ApiResult.js +0 -2
- package/dist/generated/agents/core/CancelablePromise.d.ts +0 -20
- package/dist/generated/agents/core/CancelablePromise.js +0 -104
- package/dist/generated/agents/core/OpenAPI.d.ts +0 -16
- package/dist/generated/agents/core/OpenAPI.js +0 -14
- package/dist/generated/agents/core/request.d.ts +0 -30
- package/dist/generated/agents/core/request.js +0 -294
- package/dist/generated/agents/models/Agent.d.ts +0 -22
- package/dist/generated/agents/models/Agent.js +0 -2
- package/dist/generated/agents/models/CreateWorkflowRequest.d.ts +0 -27
- package/dist/generated/agents/models/CreateWorkflowRequest.js +0 -14
- package/dist/generated/agents/models/Execution.d.ts +0 -18
- package/dist/generated/agents/models/Execution.js +0 -2
- package/dist/generated/agents/models/OptimisationRequest.d.ts +0 -6
- package/dist/generated/agents/models/OptimisationRequest.js +0 -2
- package/dist/generated/agents/models/Workflow.d.ts +0 -30
- package/dist/generated/agents/models/Workflow.js +0 -2
- package/dist/generated/agents/models/WorkflowExecution.d.ts +0 -6
- package/dist/generated/agents/models/WorkflowExecution.js +0 -2
- package/dist/generated/agents/models/WorkflowExecutionRequest.d.ts +0 -4
- package/dist/generated/agents/models/WorkflowExecutionRequest.js +0 -2
- package/dist/generated/agents/services/AgentService.d.ts +0 -10
- package/dist/generated/agents/services/AgentService.js +0 -19
- package/dist/generated/agents/services/ApiService.d.ts +0 -9
- package/dist/generated/agents/services/ApiService.js +0 -19
- package/dist/generated/agents/services/DefaultService.d.ts +0 -23
- package/dist/generated/agents/services/DefaultService.js +0 -43
- package/dist/generated/agents/services/OptimiserService.d.ts +0 -11
- package/dist/generated/agents/services/OptimiserService.js +0 -22
- package/dist/generated/agents/services/WorkflowService.d.ts +0 -20
- package/dist/generated/agents/services/WorkflowService.js +0 -44
- package/dist/generated/platform/core/ApiError.d.ts +0 -10
- package/dist/generated/platform/core/ApiError.js +0 -20
- package/dist/generated/platform/core/ApiRequestOptions.d.ts +0 -13
- package/dist/generated/platform/core/ApiRequestOptions.js +0 -2
- package/dist/generated/platform/core/ApiResult.d.ts +0 -7
- package/dist/generated/platform/core/ApiResult.js +0 -2
- package/dist/generated/platform/core/CancelablePromise.d.ts +0 -20
- package/dist/generated/platform/core/CancelablePromise.js +0 -104
- package/dist/generated/platform/core/OpenAPI.d.ts +0 -16
- package/dist/generated/platform/core/OpenAPI.js +0 -14
- package/dist/generated/platform/core/request.d.ts +0 -30
- package/dist/generated/platform/core/request.js +0 -294
- package/dist/generated/platform/index.d.ts +0 -57
- package/dist/generated/platform/index.js +0 -58
- package/dist/generated/platform/models/APIKey.d.ts +0 -9
- package/dist/generated/platform/models/APIKey.js +0 -2
- package/dist/generated/platform/models/AgentReport.d.ts +0 -45
- package/dist/generated/platform/models/AgentReport.js +0 -2
- package/dist/generated/platform/models/AsteroidChat.d.ts +0 -9
- package/dist/generated/platform/models/AsteroidChat.js +0 -2
- package/dist/generated/platform/models/AsteroidChoice.d.ts +0 -16
- package/dist/generated/platform/models/AsteroidChoice.js +0 -14
- package/dist/generated/platform/models/AsteroidMessage.d.ts +0 -27
- package/dist/generated/platform/models/AsteroidMessage.js +0 -15
- package/dist/generated/platform/models/AsteroidToolCall.d.ts +0 -11
- package/dist/generated/platform/models/AsteroidToolCall.js +0 -2
- package/dist/generated/platform/models/ChainExecution.d.ts +0 -6
- package/dist/generated/platform/models/ChainExecution.js +0 -2
- package/dist/generated/platform/models/ChainExecutionState.d.ts +0 -8
- package/dist/generated/platform/models/ChainExecutionState.js +0 -2
- package/dist/generated/platform/models/ChainRequest.d.ts +0 -6
- package/dist/generated/platform/models/ChainRequest.js +0 -2
- package/dist/generated/platform/models/ChatFormat.d.ts +0 -5
- package/dist/generated/platform/models/ChatFormat.js +0 -13
- package/dist/generated/platform/models/ChatIds.d.ts +0 -5
- package/dist/generated/platform/models/ChatIds.js +0 -2
- package/dist/generated/platform/models/ChoiceIds.d.ts +0 -6
- package/dist/generated/platform/models/ChoiceIds.js +0 -2
- package/dist/generated/platform/models/Decision.d.ts +0 -7
- package/dist/generated/platform/models/Decision.js +0 -15
- package/dist/generated/platform/models/ErrorResponse.d.ts +0 -4
- package/dist/generated/platform/models/ErrorResponse.js +0 -2
- package/dist/generated/platform/models/FailureCategory.d.ts +0 -12
- package/dist/generated/platform/models/FailureCategory.js +0 -20
- package/dist/generated/platform/models/FailureReport.d.ts +0 -33
- package/dist/generated/platform/models/FailureReport.js +0 -13
- package/dist/generated/platform/models/Feedback.d.ts +0 -13
- package/dist/generated/platform/models/Feedback.js +0 -2
- package/dist/generated/platform/models/FeedbackRequest.d.ts +0 -6
- package/dist/generated/platform/models/FeedbackRequest.js +0 -2
- package/dist/generated/platform/models/FileURL.d.ts +0 -4
- package/dist/generated/platform/models/FileURL.js +0 -2
- package/dist/generated/platform/models/HubStats.d.ts +0 -10
- package/dist/generated/platform/models/HubStats.js +0 -2
- package/dist/generated/platform/models/MessageRole.d.ts +0 -5
- package/dist/generated/platform/models/MessageRole.js +0 -13
- package/dist/generated/platform/models/MessageType.d.ts +0 -6
- package/dist/generated/platform/models/MessageType.js +0 -14
- package/dist/generated/platform/models/Permission.d.ts +0 -5
- package/dist/generated/platform/models/Permission.js +0 -13
- package/dist/generated/platform/models/Project.d.ts +0 -8
- package/dist/generated/platform/models/Project.js +0 -2
- package/dist/generated/platform/models/ReviewPayload.d.ts +0 -29
- package/dist/generated/platform/models/ReviewPayload.js +0 -2
- package/dist/generated/platform/models/Run.d.ts +0 -9
- package/dist/generated/platform/models/Run.js +0 -2
- package/dist/generated/platform/models/RunExecution.d.ts +0 -8
- package/dist/generated/platform/models/RunExecution.js +0 -2
- package/dist/generated/platform/models/RunState.d.ts +0 -2
- package/dist/generated/platform/models/RunState.js +0 -2
- package/dist/generated/platform/models/Status.d.ts +0 -8
- package/dist/generated/platform/models/Status.js +0 -16
- package/dist/generated/platform/models/SupervisionRequest.d.ts +0 -9
- package/dist/generated/platform/models/SupervisionRequest.js +0 -2
- package/dist/generated/platform/models/SupervisionRequestState.d.ts +0 -8
- package/dist/generated/platform/models/SupervisionRequestState.js +0 -2
- package/dist/generated/platform/models/SupervisionResult.d.ts +0 -9
- package/dist/generated/platform/models/SupervisionResult.js +0 -2
- package/dist/generated/platform/models/SupervisionStatus.d.ts +0 -7
- package/dist/generated/platform/models/SupervisionStatus.js +0 -2
- package/dist/generated/platform/models/Supervisor.d.ts +0 -10
- package/dist/generated/platform/models/Supervisor.js +0 -2
- package/dist/generated/platform/models/SupervisorChain.d.ts +0 -5
- package/dist/generated/platform/models/SupervisorChain.js +0 -2
- package/dist/generated/platform/models/SupervisorStats.d.ts +0 -21
- package/dist/generated/platform/models/SupervisorStats.js +0 -2
- package/dist/generated/platform/models/SupervisorType.d.ts +0 -8
- package/dist/generated/platform/models/SupervisorType.js +0 -16
- package/dist/generated/platform/models/Task.d.ts +0 -7
- package/dist/generated/platform/models/Task.js +0 -2
- package/dist/generated/platform/models/Tool.d.ts +0 -9
- package/dist/generated/platform/models/Tool.js +0 -2
- package/dist/generated/platform/models/ToolCallIds.d.ts +0 -4
- package/dist/generated/platform/models/ToolCallIds.js +0 -2
- package/dist/generated/platform/models/ToolSupervisionResult.d.ts +0 -36
- package/dist/generated/platform/models/ToolSupervisionResult.js +0 -2
- package/dist/generated/platform/models/User.d.ts +0 -4
- package/dist/generated/platform/models/User.js +0 -2
- package/dist/generated/platform/services/ApiKeyService.d.ts +0 -33
- package/dist/generated/platform/services/ApiKeyService.js +0 -64
- package/dist/generated/platform/services/ApiService.d.ts +0 -9
- package/dist/generated/platform/services/ApiService.js +0 -19
- package/dist/generated/platform/services/ImproveService.d.ts +0 -20
- package/dist/generated/platform/services/ImproveService.js +0 -47
- package/dist/generated/platform/services/ProjectService.d.ts +0 -34
- package/dist/generated/platform/services/ProjectService.js +0 -72
- package/dist/generated/platform/services/RunService.d.ts +0 -121
- package/dist/generated/platform/services/RunService.js +0 -260
- package/dist/generated/platform/services/StatsService.d.ts +0 -10
- package/dist/generated/platform/services/StatsService.js +0 -22
- package/dist/generated/platform/services/SupervisionService.d.ts +0 -46
- package/dist/generated/platform/services/SupervisionService.js +0 -100
- package/dist/generated/platform/services/SupervisorService.d.ts +0 -43
- package/dist/generated/platform/services/SupervisorService.js +0 -92
- package/dist/generated/platform/services/TaskService.d.ts +0 -29
- package/dist/generated/platform/services/TaskService.js +0 -59
- package/dist/generated/platform/services/ToolCallService.d.ts +0 -42
- package/dist/generated/platform/services/ToolCallService.js +0 -92
- package/dist/generated/platform/services/ToolService.d.ts +0 -47
- package/dist/generated/platform/services/ToolService.js +0 -92
- package/dist/src/generated/agents/core/ApiError.d.ts +0 -10
- package/dist/src/generated/agents/core/ApiError.js +0 -20
- package/dist/src/generated/agents/core/ApiRequestOptions.d.ts +0 -13
- package/dist/src/generated/agents/core/ApiRequestOptions.js +0 -2
- package/dist/src/generated/agents/core/ApiResult.d.ts +0 -7
- package/dist/src/generated/agents/core/ApiResult.js +0 -2
- package/dist/src/generated/agents/core/CancelablePromise.d.ts +0 -20
- package/dist/src/generated/agents/core/CancelablePromise.js +0 -104
- package/dist/src/generated/agents/core/OpenAPI.d.ts +0 -16
- package/dist/src/generated/agents/core/OpenAPI.js +0 -14
- package/dist/src/generated/agents/core/request.d.ts +0 -30
- package/dist/src/generated/agents/core/request.js +0 -294
- package/dist/src/generated/agents/index.d.ts +0 -16
- package/dist/src/generated/agents/index.js +0 -24
- package/dist/src/generated/agents/models/Agent.d.ts +0 -22
- package/dist/src/generated/agents/models/Agent.js +0 -2
- package/dist/src/generated/agents/models/CreateWorkflowRequest.d.ts +0 -14
- package/dist/src/generated/agents/models/CreateWorkflowRequest.js +0 -2
- package/dist/src/generated/agents/models/Execution.d.ts +0 -18
- package/dist/src/generated/agents/models/Execution.js +0 -2
- package/dist/src/generated/agents/models/OptimisationRequest.d.ts +0 -6
- package/dist/src/generated/agents/models/OptimisationRequest.js +0 -2
- package/dist/src/generated/agents/models/Workflow.d.ts +0 -26
- package/dist/src/generated/agents/models/Workflow.js +0 -2
- package/dist/src/generated/agents/models/WorkflowExecution.d.ts +0 -6
- package/dist/src/generated/agents/models/WorkflowExecution.js +0 -2
- package/dist/src/generated/agents/models/WorkflowExecutionRequest.d.ts +0 -4
- package/dist/src/generated/agents/models/WorkflowExecutionRequest.js +0 -2
- package/dist/src/generated/agents/services/AgentService.d.ts +0 -10
- package/dist/src/generated/agents/services/AgentService.js +0 -19
- package/dist/src/generated/agents/services/ApiService.d.ts +0 -9
- package/dist/src/generated/agents/services/ApiService.js +0 -19
- package/dist/src/generated/agents/services/DefaultService.d.ts +0 -23
- package/dist/src/generated/agents/services/DefaultService.js +0 -43
- package/dist/src/generated/agents/services/OptimiserService.d.ts +0 -11
- package/dist/src/generated/agents/services/OptimiserService.js +0 -22
- package/dist/src/generated/agents/services/WorkflowService.d.ts +0 -19
- package/dist/src/generated/agents/services/WorkflowService.js +0 -40
- package/dist/src/generated/platform/core/ApiError.d.ts +0 -10
- package/dist/src/generated/platform/core/ApiError.js +0 -20
- package/dist/src/generated/platform/core/ApiRequestOptions.d.ts +0 -13
- package/dist/src/generated/platform/core/ApiRequestOptions.js +0 -2
- package/dist/src/generated/platform/core/ApiResult.d.ts +0 -7
- package/dist/src/generated/platform/core/ApiResult.js +0 -2
- package/dist/src/generated/platform/core/CancelablePromise.d.ts +0 -20
- package/dist/src/generated/platform/core/CancelablePromise.js +0 -104
- package/dist/src/generated/platform/core/OpenAPI.d.ts +0 -16
- package/dist/src/generated/platform/core/OpenAPI.js +0 -14
- package/dist/src/generated/platform/core/request.d.ts +0 -30
- package/dist/src/generated/platform/core/request.js +0 -294
- package/dist/src/generated/platform/index.d.ts +0 -56
- package/dist/src/generated/platform/index.js +0 -58
- package/dist/src/generated/platform/models/APIKey.d.ts +0 -9
- package/dist/src/generated/platform/models/APIKey.js +0 -2
- package/dist/src/generated/platform/models/AgentReport.d.ts +0 -45
- package/dist/src/generated/platform/models/AgentReport.js +0 -2
- package/dist/src/generated/platform/models/AsteroidChat.d.ts +0 -9
- package/dist/src/generated/platform/models/AsteroidChat.js +0 -2
- package/dist/src/generated/platform/models/AsteroidChoice.d.ts +0 -16
- package/dist/src/generated/platform/models/AsteroidChoice.js +0 -14
- package/dist/src/generated/platform/models/AsteroidMessage.d.ts +0 -27
- package/dist/src/generated/platform/models/AsteroidMessage.js +0 -15
- package/dist/src/generated/platform/models/AsteroidToolCall.d.ts +0 -11
- package/dist/src/generated/platform/models/AsteroidToolCall.js +0 -2
- package/dist/src/generated/platform/models/ChainExecution.d.ts +0 -6
- package/dist/src/generated/platform/models/ChainExecution.js +0 -2
- package/dist/src/generated/platform/models/ChainExecutionState.d.ts +0 -8
- package/dist/src/generated/platform/models/ChainExecutionState.js +0 -2
- package/dist/src/generated/platform/models/ChainRequest.d.ts +0 -6
- package/dist/src/generated/platform/models/ChainRequest.js +0 -2
- package/dist/src/generated/platform/models/ChatFormat.d.ts +0 -5
- package/dist/src/generated/platform/models/ChatFormat.js +0 -13
- package/dist/src/generated/platform/models/ChatIds.d.ts +0 -5
- package/dist/src/generated/platform/models/ChatIds.js +0 -2
- package/dist/src/generated/platform/models/ChoiceIds.d.ts +0 -6
- package/dist/src/generated/platform/models/ChoiceIds.js +0 -2
- package/dist/src/generated/platform/models/Decision.d.ts +0 -7
- package/dist/src/generated/platform/models/Decision.js +0 -15
- package/dist/src/generated/platform/models/ErrorResponse.d.ts +0 -4
- package/dist/src/generated/platform/models/ErrorResponse.js +0 -2
- package/dist/src/generated/platform/models/FailureCategory.d.ts +0 -12
- package/dist/src/generated/platform/models/FailureCategory.js +0 -20
- package/dist/src/generated/platform/models/FailureReport.d.ts +0 -33
- package/dist/src/generated/platform/models/FailureReport.js +0 -13
- package/dist/src/generated/platform/models/Feedback.d.ts +0 -13
- package/dist/src/generated/platform/models/Feedback.js +0 -2
- package/dist/src/generated/platform/models/FeedbackRequest.d.ts +0 -6
- package/dist/src/generated/platform/models/FeedbackRequest.js +0 -2
- package/dist/src/generated/platform/models/HubStats.d.ts +0 -10
- package/dist/src/generated/platform/models/HubStats.js +0 -2
- package/dist/src/generated/platform/models/MessageRole.d.ts +0 -5
- package/dist/src/generated/platform/models/MessageRole.js +0 -13
- package/dist/src/generated/platform/models/MessageType.d.ts +0 -6
- package/dist/src/generated/platform/models/MessageType.js +0 -14
- package/dist/src/generated/platform/models/Permission.d.ts +0 -5
- package/dist/src/generated/platform/models/Permission.js +0 -13
- package/dist/src/generated/platform/models/Project.d.ts +0 -8
- package/dist/src/generated/platform/models/Project.js +0 -2
- package/dist/src/generated/platform/models/ReviewPayload.d.ts +0 -29
- package/dist/src/generated/platform/models/ReviewPayload.js +0 -2
- package/dist/src/generated/platform/models/Run.d.ts +0 -9
- package/dist/src/generated/platform/models/Run.js +0 -2
- package/dist/src/generated/platform/models/RunExecution.d.ts +0 -8
- package/dist/src/generated/platform/models/RunExecution.js +0 -2
- package/dist/src/generated/platform/models/RunState.d.ts +0 -2
- package/dist/src/generated/platform/models/RunState.js +0 -2
- package/dist/src/generated/platform/models/Status.d.ts +0 -8
- package/dist/src/generated/platform/models/Status.js +0 -16
- package/dist/src/generated/platform/models/SupervisionRequest.d.ts +0 -9
- package/dist/src/generated/platform/models/SupervisionRequest.js +0 -2
- package/dist/src/generated/platform/models/SupervisionRequestState.d.ts +0 -8
- package/dist/src/generated/platform/models/SupervisionRequestState.js +0 -2
- package/dist/src/generated/platform/models/SupervisionResult.d.ts +0 -9
- package/dist/src/generated/platform/models/SupervisionResult.js +0 -2
- package/dist/src/generated/platform/models/SupervisionStatus.d.ts +0 -7
- package/dist/src/generated/platform/models/SupervisionStatus.js +0 -2
- package/dist/src/generated/platform/models/Supervisor.d.ts +0 -10
- package/dist/src/generated/platform/models/Supervisor.js +0 -2
- package/dist/src/generated/platform/models/SupervisorChain.d.ts +0 -5
- package/dist/src/generated/platform/models/SupervisorChain.js +0 -2
- package/dist/src/generated/platform/models/SupervisorStats.d.ts +0 -21
- package/dist/src/generated/platform/models/SupervisorStats.js +0 -2
- package/dist/src/generated/platform/models/SupervisorType.d.ts +0 -8
- package/dist/src/generated/platform/models/SupervisorType.js +0 -16
- package/dist/src/generated/platform/models/Task.d.ts +0 -7
- package/dist/src/generated/platform/models/Task.js +0 -2
- package/dist/src/generated/platform/models/Tool.d.ts +0 -9
- package/dist/src/generated/platform/models/Tool.js +0 -2
- package/dist/src/generated/platform/models/ToolCallIds.d.ts +0 -4
- package/dist/src/generated/platform/models/ToolCallIds.js +0 -2
- package/dist/src/generated/platform/models/ToolSupervisionResult.d.ts +0 -36
- package/dist/src/generated/platform/models/ToolSupervisionResult.js +0 -2
- package/dist/src/generated/platform/models/User.d.ts +0 -4
- package/dist/src/generated/platform/models/User.js +0 -2
- package/dist/src/generated/platform/services/ApiKeyService.d.ts +0 -33
- package/dist/src/generated/platform/services/ApiKeyService.js +0 -64
- package/dist/src/generated/platform/services/ApiService.d.ts +0 -9
- package/dist/src/generated/platform/services/ApiService.js +0 -19
- package/dist/src/generated/platform/services/ImproveService.d.ts +0 -20
- package/dist/src/generated/platform/services/ImproveService.js +0 -47
- package/dist/src/generated/platform/services/ProjectService.d.ts +0 -34
- package/dist/src/generated/platform/services/ProjectService.js +0 -72
- package/dist/src/generated/platform/services/RunService.d.ts +0 -103
- package/dist/src/generated/platform/services/RunService.js +0 -227
- package/dist/src/generated/platform/services/StatsService.d.ts +0 -10
- package/dist/src/generated/platform/services/StatsService.js +0 -22
- package/dist/src/generated/platform/services/SupervisionService.d.ts +0 -46
- package/dist/src/generated/platform/services/SupervisionService.js +0 -100
- package/dist/src/generated/platform/services/SupervisorService.d.ts +0 -43
- package/dist/src/generated/platform/services/SupervisorService.js +0 -92
- package/dist/src/generated/platform/services/TaskService.d.ts +0 -29
- package/dist/src/generated/platform/services/TaskService.js +0 -59
- package/dist/src/generated/platform/services/ToolCallService.d.ts +0 -42
- package/dist/src/generated/platform/services/ToolCallService.js +0 -92
- package/dist/src/generated/platform/services/ToolService.d.ts +0 -47
- package/dist/src/generated/platform/services/ToolService.js +0 -92
- package/dist/src/index.d.ts +0 -70
- package/dist/src/index.js +0 -102
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { type Options as ClientOptions, type TDataShape, type Client } from '@hey-api/client-fetch';
|
|
2
|
-
import type { GetOpenApiData, UploadExecutionFilesData, HealthCheckData, ExecuteAgentData, ExecuteAgentStructuredData, GetExecutionStatusData, GetExecutionResultData, GetBrowserSessionRecordingData } from './types.gen';
|
|
2
|
+
import type { GetOpenApiData, UploadExecutionFilesData, HealthCheckData, ExecuteAgentData, ExecuteAgentStructuredData, GetExecutionStatusData, GetExecutionResultData, GetBrowserSessionRecordingData, GetAgentProfilesData, CreateAgentProfileData, DeleteAgentProfileData, GetAgentProfileData, UpdateAgentProfileData } from './types.gen';
|
|
3
3
|
export type Options<TData extends TDataShape = TDataShape, ThrowOnError extends boolean = boolean> = ClientOptions<TData, ThrowOnError> & {
|
|
4
4
|
/**
|
|
5
5
|
* You can provide a client instance returned by `createClient()` instead of
|
|
@@ -33,6 +33,7 @@ export declare const healthCheck: <ThrowOnError extends boolean = false>(options
|
|
|
33
33
|
error?: string;
|
|
34
34
|
}, ThrowOnError>;
|
|
35
35
|
/**
|
|
36
|
+
* @deprecated
|
|
36
37
|
* Execute an agent
|
|
37
38
|
* Executes an agent with the provided parameters
|
|
38
39
|
*/
|
|
@@ -55,3 +56,30 @@ export declare const getExecutionResult: <ThrowOnError extends boolean = false>(
|
|
|
55
56
|
* Retrieves the browser session recording URL for a completed execution
|
|
56
57
|
*/
|
|
57
58
|
export declare const getBrowserSessionRecording: <ThrowOnError extends boolean = false>(options: Options<GetBrowserSessionRecordingData, ThrowOnError>) => import("@hey-api/client-fetch").RequestResult<import("./types.gen").BrowserSessionRecordingResponse, import("./types.gen").ErrorResponse, ThrowOnError>;
|
|
59
|
+
/**
|
|
60
|
+
* Get agent profiles
|
|
61
|
+
* Returns all agent profiles for the organization. If organization_id is not provided, returns profiles for all user's organizations.
|
|
62
|
+
*/
|
|
63
|
+
export declare const getAgentProfiles: <ThrowOnError extends boolean = false>(options?: Options<GetAgentProfilesData, ThrowOnError>) => import("@hey-api/client-fetch").RequestResult<import("./types.gen").AgentProfile[], import("./types.gen").ErrorResponse, ThrowOnError>;
|
|
64
|
+
/**
|
|
65
|
+
* Create an agent profile
|
|
66
|
+
* Creates a new agent profile for the organization
|
|
67
|
+
*/
|
|
68
|
+
export declare const createAgentProfile: <ThrowOnError extends boolean = false>(options: Options<CreateAgentProfileData, ThrowOnError>) => import("@hey-api/client-fetch").RequestResult<import("./types.gen").AgentProfile, import("./types.gen").ErrorResponse, ThrowOnError>;
|
|
69
|
+
/**
|
|
70
|
+
* Delete an agent profile
|
|
71
|
+
* Deletes the specified agent profile
|
|
72
|
+
*/
|
|
73
|
+
export declare const deleteAgentProfile: <ThrowOnError extends boolean = false>(options: Options<DeleteAgentProfileData, ThrowOnError>) => import("@hey-api/client-fetch").RequestResult<{
|
|
74
|
+
message?: string;
|
|
75
|
+
}, import("./types.gen").ErrorResponse, ThrowOnError>;
|
|
76
|
+
/**
|
|
77
|
+
* Get an agent profile by ID
|
|
78
|
+
* Returns the complete agent profile including credentials
|
|
79
|
+
*/
|
|
80
|
+
export declare const getAgentProfile: <ThrowOnError extends boolean = false>(options: Options<GetAgentProfileData, ThrowOnError>) => import("@hey-api/client-fetch").RequestResult<import("./types.gen").AgentProfile, import("./types.gen").ErrorResponse, ThrowOnError>;
|
|
81
|
+
/**
|
|
82
|
+
* Update an agent profile
|
|
83
|
+
* Updates an agent profile including metadata and/or credentials
|
|
84
|
+
*/
|
|
85
|
+
export declare const updateAgentProfile: <ThrowOnError extends boolean = false>(options: Options<UpdateAgentProfileData, ThrowOnError>) => import("@hey-api/client-fetch").RequestResult<import("./types.gen").AgentProfile, import("./types.gen").ErrorResponse, ThrowOnError>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
// This file is auto-generated by @hey-api/openapi-ts
|
|
3
3
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
-
exports.getBrowserSessionRecording = exports.getExecutionResult = exports.getExecutionStatus = exports.executeAgentStructured = exports.executeAgent = exports.healthCheck = exports.uploadExecutionFiles = exports.getOpenApi = void 0;
|
|
4
|
+
exports.updateAgentProfile = exports.getAgentProfile = exports.deleteAgentProfile = exports.createAgentProfile = exports.getAgentProfiles = exports.getBrowserSessionRecording = exports.getExecutionResult = exports.getExecutionStatus = exports.executeAgentStructured = exports.executeAgent = exports.healthCheck = exports.uploadExecutionFiles = exports.getOpenApi = void 0;
|
|
5
5
|
const client_fetch_1 = require("@hey-api/client-fetch");
|
|
6
6
|
const client_gen_1 = require("./client.gen");
|
|
7
7
|
/**
|
|
@@ -46,6 +46,7 @@ const healthCheck = (options) => {
|
|
|
46
46
|
};
|
|
47
47
|
exports.healthCheck = healthCheck;
|
|
48
48
|
/**
|
|
49
|
+
* @deprecated
|
|
49
50
|
* Execute an agent
|
|
50
51
|
* Executes an agent with the provided parameters
|
|
51
52
|
*/
|
|
@@ -136,3 +137,96 @@ const getBrowserSessionRecording = (options) => {
|
|
|
136
137
|
});
|
|
137
138
|
};
|
|
138
139
|
exports.getBrowserSessionRecording = getBrowserSessionRecording;
|
|
140
|
+
/**
|
|
141
|
+
* Get agent profiles
|
|
142
|
+
* Returns all agent profiles for the organization. If organization_id is not provided, returns profiles for all user's organizations.
|
|
143
|
+
*/
|
|
144
|
+
const getAgentProfiles = (options) => {
|
|
145
|
+
return (options?.client ?? client_gen_1.client).get({
|
|
146
|
+
security: [
|
|
147
|
+
{
|
|
148
|
+
name: 'X-Asteroid-Agents-Api-Key',
|
|
149
|
+
type: 'apiKey'
|
|
150
|
+
}
|
|
151
|
+
],
|
|
152
|
+
url: '/agent-profiles',
|
|
153
|
+
...options
|
|
154
|
+
});
|
|
155
|
+
};
|
|
156
|
+
exports.getAgentProfiles = getAgentProfiles;
|
|
157
|
+
/**
|
|
158
|
+
* Create an agent profile
|
|
159
|
+
* Creates a new agent profile for the organization
|
|
160
|
+
*/
|
|
161
|
+
const createAgentProfile = (options) => {
|
|
162
|
+
return (options.client ?? client_gen_1.client).post({
|
|
163
|
+
security: [
|
|
164
|
+
{
|
|
165
|
+
name: 'X-Asteroid-Agents-Api-Key',
|
|
166
|
+
type: 'apiKey'
|
|
167
|
+
}
|
|
168
|
+
],
|
|
169
|
+
url: '/agent-profiles',
|
|
170
|
+
...options,
|
|
171
|
+
headers: {
|
|
172
|
+
'Content-Type': 'application/json',
|
|
173
|
+
...options?.headers
|
|
174
|
+
}
|
|
175
|
+
});
|
|
176
|
+
};
|
|
177
|
+
exports.createAgentProfile = createAgentProfile;
|
|
178
|
+
/**
|
|
179
|
+
* Delete an agent profile
|
|
180
|
+
* Deletes the specified agent profile
|
|
181
|
+
*/
|
|
182
|
+
const deleteAgentProfile = (options) => {
|
|
183
|
+
return (options.client ?? client_gen_1.client).delete({
|
|
184
|
+
security: [
|
|
185
|
+
{
|
|
186
|
+
name: 'X-Asteroid-Agents-Api-Key',
|
|
187
|
+
type: 'apiKey'
|
|
188
|
+
}
|
|
189
|
+
],
|
|
190
|
+
url: '/agent-profiles/{profile_id}',
|
|
191
|
+
...options
|
|
192
|
+
});
|
|
193
|
+
};
|
|
194
|
+
exports.deleteAgentProfile = deleteAgentProfile;
|
|
195
|
+
/**
|
|
196
|
+
* Get an agent profile by ID
|
|
197
|
+
* Returns the complete agent profile including credentials
|
|
198
|
+
*/
|
|
199
|
+
const getAgentProfile = (options) => {
|
|
200
|
+
return (options.client ?? client_gen_1.client).get({
|
|
201
|
+
security: [
|
|
202
|
+
{
|
|
203
|
+
name: 'X-Asteroid-Agents-Api-Key',
|
|
204
|
+
type: 'apiKey'
|
|
205
|
+
}
|
|
206
|
+
],
|
|
207
|
+
url: '/agent-profiles/{profile_id}',
|
|
208
|
+
...options
|
|
209
|
+
});
|
|
210
|
+
};
|
|
211
|
+
exports.getAgentProfile = getAgentProfile;
|
|
212
|
+
/**
|
|
213
|
+
* Update an agent profile
|
|
214
|
+
* Updates an agent profile including metadata and/or credentials
|
|
215
|
+
*/
|
|
216
|
+
const updateAgentProfile = (options) => {
|
|
217
|
+
return (options.client ?? client_gen_1.client).patch({
|
|
218
|
+
security: [
|
|
219
|
+
{
|
|
220
|
+
name: 'X-Asteroid-Agents-Api-Key',
|
|
221
|
+
type: 'apiKey'
|
|
222
|
+
}
|
|
223
|
+
],
|
|
224
|
+
url: '/agent-profiles/{profile_id}',
|
|
225
|
+
...options,
|
|
226
|
+
headers: {
|
|
227
|
+
'Content-Type': 'application/json',
|
|
228
|
+
...options?.headers
|
|
229
|
+
}
|
|
230
|
+
});
|
|
231
|
+
};
|
|
232
|
+
exports.updateAgentProfile = updateAgentProfile;
|
|
@@ -66,7 +66,7 @@ export type ExecutionResult = {
|
|
|
66
66
|
/**
|
|
67
67
|
* Status of the execution
|
|
68
68
|
*/
|
|
69
|
-
export type Status = 'starting' | 'running' | 'paused' | 'completed' | 'cancelled' | 'failed' | '
|
|
69
|
+
export type Status = 'starting' | 'running' | 'paused' | 'completed' | 'cancelled' | 'failed' | 'awaiting_confirmation' | 'paused_by_agent';
|
|
70
70
|
export type ErrorResponse = {
|
|
71
71
|
/**
|
|
72
72
|
* Error message
|
|
@@ -94,6 +94,124 @@ export type StructuredAgentExecutionRequest = {
|
|
|
94
94
|
[key: string]: unknown;
|
|
95
95
|
};
|
|
96
96
|
};
|
|
97
|
+
export type AgentProfile = {
|
|
98
|
+
/**
|
|
99
|
+
* Unique identifier for the agent profile
|
|
100
|
+
*/
|
|
101
|
+
id: string;
|
|
102
|
+
/**
|
|
103
|
+
* Name of the agent profile (unique within organization)
|
|
104
|
+
*/
|
|
105
|
+
name: string;
|
|
106
|
+
/**
|
|
107
|
+
* Description of the agent profile
|
|
108
|
+
*/
|
|
109
|
+
description: string;
|
|
110
|
+
/**
|
|
111
|
+
* The ID of the organization that the agent profile belongs to
|
|
112
|
+
*/
|
|
113
|
+
organization_id: string;
|
|
114
|
+
proxy_cc: CountryCode;
|
|
115
|
+
proxy_type: ProxyType;
|
|
116
|
+
/**
|
|
117
|
+
* Whether the captcha solver is active for this profile
|
|
118
|
+
*/
|
|
119
|
+
captcha_solver_active: boolean;
|
|
120
|
+
/**
|
|
121
|
+
* Whether the same IP address should be used for all executions of this profile
|
|
122
|
+
*/
|
|
123
|
+
sticky_ip: boolean;
|
|
124
|
+
/**
|
|
125
|
+
* List of credentials associated with this agent profile
|
|
126
|
+
*/
|
|
127
|
+
credentials: Array<Credential>;
|
|
128
|
+
/**
|
|
129
|
+
* The date and time the agent profile was created
|
|
130
|
+
*/
|
|
131
|
+
created_at: string;
|
|
132
|
+
/**
|
|
133
|
+
* The last update time of the agent profile
|
|
134
|
+
*/
|
|
135
|
+
updated_at: string;
|
|
136
|
+
};
|
|
137
|
+
export type CreateAgentProfileRequest = {
|
|
138
|
+
/**
|
|
139
|
+
* Name of the agent profile (must be unique within organization)
|
|
140
|
+
*/
|
|
141
|
+
name: string;
|
|
142
|
+
/**
|
|
143
|
+
* Description of the agent profile
|
|
144
|
+
*/
|
|
145
|
+
description: string;
|
|
146
|
+
/**
|
|
147
|
+
* The ID of the organization that the agent profile belongs to
|
|
148
|
+
*/
|
|
149
|
+
organization_id: string;
|
|
150
|
+
proxy_cc: CountryCode;
|
|
151
|
+
proxy_type: ProxyType;
|
|
152
|
+
/**
|
|
153
|
+
* Whether the captcha solver should be active for this profile
|
|
154
|
+
*/
|
|
155
|
+
captcha_solver_active: boolean;
|
|
156
|
+
/**
|
|
157
|
+
* Whether the same IP address should be used for all executions of this profile
|
|
158
|
+
*/
|
|
159
|
+
sticky_ip: boolean;
|
|
160
|
+
/**
|
|
161
|
+
* Optional list of credentials to create with the profile
|
|
162
|
+
*/
|
|
163
|
+
credentials: Array<Credential>;
|
|
164
|
+
};
|
|
165
|
+
export type UpdateAgentProfileRequest = {
|
|
166
|
+
/**
|
|
167
|
+
* The name of the agent profile
|
|
168
|
+
*/
|
|
169
|
+
name?: string;
|
|
170
|
+
/**
|
|
171
|
+
* The description of the agent profile
|
|
172
|
+
*/
|
|
173
|
+
description?: string;
|
|
174
|
+
proxy_cc?: CountryCode;
|
|
175
|
+
proxy_type?: ProxyType;
|
|
176
|
+
/**
|
|
177
|
+
* Whether the captcha solver should be active for this profile
|
|
178
|
+
*/
|
|
179
|
+
captcha_solver_active?: boolean;
|
|
180
|
+
/**
|
|
181
|
+
* Whether the same IP address should be used for all executions of this profile
|
|
182
|
+
*/
|
|
183
|
+
sticky_ip?: boolean;
|
|
184
|
+
/**
|
|
185
|
+
* Complete list of credentials (replaces existing)
|
|
186
|
+
*/
|
|
187
|
+
credentials?: Array<Credential>;
|
|
188
|
+
};
|
|
189
|
+
/**
|
|
190
|
+
* Two-letter country code for proxy location
|
|
191
|
+
*/
|
|
192
|
+
export type CountryCode = 'us' | 'uk' | 'fr' | 'it' | 'jp' | 'au' | 'de' | 'fi' | 'ca';
|
|
193
|
+
/**
|
|
194
|
+
* Type of proxy to use
|
|
195
|
+
*/
|
|
196
|
+
export type ProxyType = 'residential' | 'mobile';
|
|
197
|
+
export type Credential = {
|
|
198
|
+
/**
|
|
199
|
+
* The unique identifier for this credential
|
|
200
|
+
*/
|
|
201
|
+
id?: string;
|
|
202
|
+
/**
|
|
203
|
+
* The credential name
|
|
204
|
+
*/
|
|
205
|
+
name: string;
|
|
206
|
+
/**
|
|
207
|
+
* The encrypted credential
|
|
208
|
+
*/
|
|
209
|
+
data: string;
|
|
210
|
+
/**
|
|
211
|
+
* When the credential was created
|
|
212
|
+
*/
|
|
213
|
+
created_at?: string;
|
|
214
|
+
};
|
|
97
215
|
export type GetOpenApiData = {
|
|
98
216
|
body?: never;
|
|
99
217
|
path?: never;
|
|
@@ -336,6 +454,188 @@ export type GetBrowserSessionRecordingResponses = {
|
|
|
336
454
|
200: BrowserSessionRecordingResponse;
|
|
337
455
|
};
|
|
338
456
|
export type GetBrowserSessionRecordingResponse = GetBrowserSessionRecordingResponses[keyof GetBrowserSessionRecordingResponses];
|
|
457
|
+
export type GetAgentProfilesData = {
|
|
458
|
+
body?: never;
|
|
459
|
+
path?: never;
|
|
460
|
+
query?: {
|
|
461
|
+
/**
|
|
462
|
+
* The ID of the organization to filter by
|
|
463
|
+
*/
|
|
464
|
+
organization_id?: string;
|
|
465
|
+
};
|
|
466
|
+
url: '/agent-profiles';
|
|
467
|
+
};
|
|
468
|
+
export type GetAgentProfilesErrors = {
|
|
469
|
+
/**
|
|
470
|
+
* Unauthorized - Authentication required
|
|
471
|
+
*/
|
|
472
|
+
401: ErrorResponse;
|
|
473
|
+
/**
|
|
474
|
+
* Forbidden - Insufficient permissions
|
|
475
|
+
*/
|
|
476
|
+
403: ErrorResponse;
|
|
477
|
+
/**
|
|
478
|
+
* Internal server error
|
|
479
|
+
*/
|
|
480
|
+
500: ErrorResponse;
|
|
481
|
+
};
|
|
482
|
+
export type GetAgentProfilesError = GetAgentProfilesErrors[keyof GetAgentProfilesErrors];
|
|
483
|
+
export type GetAgentProfilesResponses = {
|
|
484
|
+
/**
|
|
485
|
+
* List of agent profiles
|
|
486
|
+
*/
|
|
487
|
+
200: Array<AgentProfile>;
|
|
488
|
+
};
|
|
489
|
+
export type GetAgentProfilesResponse = GetAgentProfilesResponses[keyof GetAgentProfilesResponses];
|
|
490
|
+
export type CreateAgentProfileData = {
|
|
491
|
+
body: CreateAgentProfileRequest;
|
|
492
|
+
path?: never;
|
|
493
|
+
query?: never;
|
|
494
|
+
url: '/agent-profiles';
|
|
495
|
+
};
|
|
496
|
+
export type CreateAgentProfileErrors = {
|
|
497
|
+
/**
|
|
498
|
+
* Bad request - Invalid input or profile name already exists
|
|
499
|
+
*/
|
|
500
|
+
400: ErrorResponse;
|
|
501
|
+
/**
|
|
502
|
+
* Unauthorized - Authentication required
|
|
503
|
+
*/
|
|
504
|
+
401: ErrorResponse;
|
|
505
|
+
/**
|
|
506
|
+
* Forbidden - Insufficient permissions
|
|
507
|
+
*/
|
|
508
|
+
403: ErrorResponse;
|
|
509
|
+
/**
|
|
510
|
+
* Internal server error
|
|
511
|
+
*/
|
|
512
|
+
500: ErrorResponse;
|
|
513
|
+
};
|
|
514
|
+
export type CreateAgentProfileError = CreateAgentProfileErrors[keyof CreateAgentProfileErrors];
|
|
515
|
+
export type CreateAgentProfileResponses = {
|
|
516
|
+
/**
|
|
517
|
+
* Agent profile created successfully
|
|
518
|
+
*/
|
|
519
|
+
201: AgentProfile;
|
|
520
|
+
};
|
|
521
|
+
export type CreateAgentProfileResponse = CreateAgentProfileResponses[keyof CreateAgentProfileResponses];
|
|
522
|
+
export type DeleteAgentProfileData = {
|
|
523
|
+
body?: never;
|
|
524
|
+
path: {
|
|
525
|
+
/**
|
|
526
|
+
* The ID of the agent profile
|
|
527
|
+
*/
|
|
528
|
+
profile_id: string;
|
|
529
|
+
};
|
|
530
|
+
query?: never;
|
|
531
|
+
url: '/agent-profiles/{profile_id}';
|
|
532
|
+
};
|
|
533
|
+
export type DeleteAgentProfileErrors = {
|
|
534
|
+
/**
|
|
535
|
+
* Unauthorized - Authentication required
|
|
536
|
+
*/
|
|
537
|
+
401: ErrorResponse;
|
|
538
|
+
/**
|
|
539
|
+
* Forbidden - Insufficient permissions
|
|
540
|
+
*/
|
|
541
|
+
403: ErrorResponse;
|
|
542
|
+
/**
|
|
543
|
+
* Agent profile not found
|
|
544
|
+
*/
|
|
545
|
+
404: ErrorResponse;
|
|
546
|
+
/**
|
|
547
|
+
* Internal server error
|
|
548
|
+
*/
|
|
549
|
+
500: ErrorResponse;
|
|
550
|
+
};
|
|
551
|
+
export type DeleteAgentProfileError = DeleteAgentProfileErrors[keyof DeleteAgentProfileErrors];
|
|
552
|
+
export type DeleteAgentProfileResponses = {
|
|
553
|
+
/**
|
|
554
|
+
* Agent profile deleted successfully
|
|
555
|
+
*/
|
|
556
|
+
200: {
|
|
557
|
+
message?: string;
|
|
558
|
+
};
|
|
559
|
+
};
|
|
560
|
+
export type DeleteAgentProfileResponse = DeleteAgentProfileResponses[keyof DeleteAgentProfileResponses];
|
|
561
|
+
export type GetAgentProfileData = {
|
|
562
|
+
body?: never;
|
|
563
|
+
path: {
|
|
564
|
+
/**
|
|
565
|
+
* The ID of the agent profile
|
|
566
|
+
*/
|
|
567
|
+
profile_id: string;
|
|
568
|
+
};
|
|
569
|
+
query?: never;
|
|
570
|
+
url: '/agent-profiles/{profile_id}';
|
|
571
|
+
};
|
|
572
|
+
export type GetAgentProfileErrors = {
|
|
573
|
+
/**
|
|
574
|
+
* Unauthorized - Authentication required
|
|
575
|
+
*/
|
|
576
|
+
401: ErrorResponse;
|
|
577
|
+
/**
|
|
578
|
+
* Forbidden - Insufficient permissions
|
|
579
|
+
*/
|
|
580
|
+
403: ErrorResponse;
|
|
581
|
+
/**
|
|
582
|
+
* Agent profile not found
|
|
583
|
+
*/
|
|
584
|
+
404: ErrorResponse;
|
|
585
|
+
/**
|
|
586
|
+
* Internal server error
|
|
587
|
+
*/
|
|
588
|
+
500: ErrorResponse;
|
|
589
|
+
};
|
|
590
|
+
export type GetAgentProfileError = GetAgentProfileErrors[keyof GetAgentProfileErrors];
|
|
591
|
+
export type GetAgentProfileResponses = {
|
|
592
|
+
/**
|
|
593
|
+
* Agent profile found
|
|
594
|
+
*/
|
|
595
|
+
200: AgentProfile;
|
|
596
|
+
};
|
|
597
|
+
export type GetAgentProfileResponse = GetAgentProfileResponses[keyof GetAgentProfileResponses];
|
|
598
|
+
export type UpdateAgentProfileData = {
|
|
599
|
+
body: UpdateAgentProfileRequest;
|
|
600
|
+
path: {
|
|
601
|
+
/**
|
|
602
|
+
* The ID of the agent profile
|
|
603
|
+
*/
|
|
604
|
+
profile_id: string;
|
|
605
|
+
};
|
|
606
|
+
query?: never;
|
|
607
|
+
url: '/agent-profiles/{profile_id}';
|
|
608
|
+
};
|
|
609
|
+
export type UpdateAgentProfileErrors = {
|
|
610
|
+
/**
|
|
611
|
+
* Bad request - Invalid input
|
|
612
|
+
*/
|
|
613
|
+
400: ErrorResponse;
|
|
614
|
+
/**
|
|
615
|
+
* Unauthorized - Authentication required
|
|
616
|
+
*/
|
|
617
|
+
401: ErrorResponse;
|
|
618
|
+
/**
|
|
619
|
+
* Forbidden - Insufficient permissions
|
|
620
|
+
*/
|
|
621
|
+
403: ErrorResponse;
|
|
622
|
+
/**
|
|
623
|
+
* Agent profile not found
|
|
624
|
+
*/
|
|
625
|
+
404: ErrorResponse;
|
|
626
|
+
/**
|
|
627
|
+
* Internal server error
|
|
628
|
+
*/
|
|
629
|
+
500: ErrorResponse;
|
|
630
|
+
};
|
|
631
|
+
export type UpdateAgentProfileError = UpdateAgentProfileErrors[keyof UpdateAgentProfileErrors];
|
|
632
|
+
export type UpdateAgentProfileResponses = {
|
|
633
|
+
/**
|
|
634
|
+
* Agent profile updated successfully
|
|
635
|
+
*/
|
|
636
|
+
200: AgentProfile;
|
|
637
|
+
};
|
|
638
|
+
export type UpdateAgentProfileResponse = UpdateAgentProfileResponses[keyof UpdateAgentProfileResponses];
|
|
339
639
|
export type ClientOptions = {
|
|
340
640
|
baseUrl: 'https://odyssey.asteroid.ai/api/v1' | `${string}://${string}/api/v1` | (string & {});
|
|
341
641
|
};
|
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { Client } from '@hey-api/client-fetch';
|
|
2
|
-
import type { StructuredAgentExecutionRequest, ExecutionStatusResponse, BrowserSessionRecordingResponse } from './generated/agents/types.gen';
|
|
2
|
+
import type { StructuredAgentExecutionRequest, ExecutionStatusResponse, BrowserSessionRecordingResponse, AgentProfile, CreateAgentProfileRequest, UpdateAgentProfileRequest } from './generated/agents/types.gen';
|
|
3
3
|
/**
|
|
4
4
|
* Create an API client with a provided API key.
|
|
5
5
|
*
|
|
@@ -95,6 +95,73 @@ export declare const uploadExecutionFiles: (client: Client, executionId: string,
|
|
|
95
95
|
message?: string;
|
|
96
96
|
file_ids?: string[];
|
|
97
97
|
}>;
|
|
98
|
+
/**
|
|
99
|
+
* Get agent profiles for an organization (or all organizations for the user if not specified).
|
|
100
|
+
*
|
|
101
|
+
* @param client - The API client.
|
|
102
|
+
* @param organizationId - Optional organization ID to filter by.
|
|
103
|
+
* @returns The list of agent profiles.
|
|
104
|
+
*
|
|
105
|
+
* @example
|
|
106
|
+
* const profiles = await getAgentProfiles(client, 'org_123');
|
|
107
|
+
*/
|
|
108
|
+
export declare const getAgentProfiles: (client: Client, organizationId?: string) => Promise<AgentProfile[]>;
|
|
109
|
+
/**
|
|
110
|
+
* Create a new agent profile.
|
|
111
|
+
*
|
|
112
|
+
* @param client - The API client.
|
|
113
|
+
* @param payload - The agent profile data.
|
|
114
|
+
* @returns The created agent profile.
|
|
115
|
+
*
|
|
116
|
+
* @example
|
|
117
|
+
* const profile = await createAgentProfile(client, {
|
|
118
|
+
* name: 'My Profile',
|
|
119
|
+
* description: 'Profile description',
|
|
120
|
+
* organization_id: 'org_123',
|
|
121
|
+
* proxy_cc: 'us',
|
|
122
|
+
* proxy_type: 'residential',
|
|
123
|
+
* captcha_solver_active: false,
|
|
124
|
+
* sticky_ip: false,
|
|
125
|
+
* credentials: []
|
|
126
|
+
* });
|
|
127
|
+
*/
|
|
128
|
+
export declare const createAgentProfile: (client: Client, payload: CreateAgentProfileRequest) => Promise<AgentProfile>;
|
|
129
|
+
/**
|
|
130
|
+
* Get a specific agent profile by ID.
|
|
131
|
+
*
|
|
132
|
+
* @param client - The API client.
|
|
133
|
+
* @param profileId - The agent profile ID.
|
|
134
|
+
* @returns The agent profile.
|
|
135
|
+
*
|
|
136
|
+
* @example
|
|
137
|
+
* const profile = await getAgentProfile(client, 'profile_123');
|
|
138
|
+
*/
|
|
139
|
+
export declare const getAgentProfile: (client: Client, profileId: string) => Promise<AgentProfile>;
|
|
140
|
+
/**
|
|
141
|
+
* Update an existing agent profile.
|
|
142
|
+
*
|
|
143
|
+
* @param client - The API client.
|
|
144
|
+
* @param profileId - The agent profile ID.
|
|
145
|
+
* @param payload - The update data.
|
|
146
|
+
* @returns The updated agent profile.
|
|
147
|
+
*
|
|
148
|
+
* @example
|
|
149
|
+
* const updated = await updateAgentProfile(client, 'profile_123', { name: 'New Name' });
|
|
150
|
+
*/
|
|
151
|
+
export declare const updateAgentProfile: (client: Client, profileId: string, payload: UpdateAgentProfileRequest) => Promise<AgentProfile>;
|
|
152
|
+
/**
|
|
153
|
+
* Delete an agent profile by ID.
|
|
154
|
+
*
|
|
155
|
+
* @param client - The API client.
|
|
156
|
+
* @param profileId - The agent profile ID.
|
|
157
|
+
* @returns A success message.
|
|
158
|
+
*
|
|
159
|
+
* @example
|
|
160
|
+
* await deleteAgentProfile(client, 'profile_123');
|
|
161
|
+
*/
|
|
162
|
+
export declare const deleteAgentProfile: (client: Client, profileId: string) => Promise<{
|
|
163
|
+
message?: string;
|
|
164
|
+
}>;
|
|
98
165
|
/**
|
|
99
166
|
* Optionally, re-export all generated functions and types.
|
|
100
167
|
*/
|
package/dist/index.js
CHANGED
|
@@ -36,7 +36,7 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
36
36
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
37
37
|
};
|
|
38
38
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
39
|
-
exports.uploadExecutionFiles = exports.getBrowserSessionRecording = exports.waitForExecutionResult = exports.getExecutionResult = exports.getExecutionStatus = exports.executeAgent = exports.AsteroidClient = void 0;
|
|
39
|
+
exports.deleteAgentProfile = exports.updateAgentProfile = exports.getAgentProfile = exports.createAgentProfile = exports.getAgentProfiles = exports.uploadExecutionFiles = exports.getBrowserSessionRecording = exports.waitForExecutionResult = exports.getExecutionResult = exports.getExecutionStatus = exports.executeAgent = exports.AsteroidClient = void 0;
|
|
40
40
|
const client_fetch_1 = require("@hey-api/client-fetch");
|
|
41
41
|
const AgentsSDK = __importStar(require("./generated/agents/sdk.gen"));
|
|
42
42
|
/**
|
|
@@ -127,7 +127,7 @@ const getExecutionResult = async (client, executionId) => {
|
|
|
127
127
|
if (response.data.error) {
|
|
128
128
|
throw new Error(response.data.error);
|
|
129
129
|
}
|
|
130
|
-
return response.data.
|
|
130
|
+
return response.data.execution_result || {};
|
|
131
131
|
};
|
|
132
132
|
exports.getExecutionResult = getExecutionResult;
|
|
133
133
|
/**
|
|
@@ -211,6 +211,122 @@ const uploadExecutionFiles = async (client, executionId, files) => {
|
|
|
211
211
|
return response.data;
|
|
212
212
|
};
|
|
213
213
|
exports.uploadExecutionFiles = uploadExecutionFiles;
|
|
214
|
+
/**
|
|
215
|
+
* Get agent profiles for an organization (or all organizations for the user if not specified).
|
|
216
|
+
*
|
|
217
|
+
* @param client - The API client.
|
|
218
|
+
* @param organizationId - Optional organization ID to filter by.
|
|
219
|
+
* @returns The list of agent profiles.
|
|
220
|
+
*
|
|
221
|
+
* @example
|
|
222
|
+
* const profiles = await getAgentProfiles(client, 'org_123');
|
|
223
|
+
*/
|
|
224
|
+
const getAgentProfiles = async (client, organizationId) => {
|
|
225
|
+
const response = await AgentsSDK.getAgentProfiles({
|
|
226
|
+
client,
|
|
227
|
+
query: organizationId ? { organization_id: organizationId } : undefined,
|
|
228
|
+
});
|
|
229
|
+
if (response.error) {
|
|
230
|
+
throw new Error(response.error.error);
|
|
231
|
+
}
|
|
232
|
+
return response.data;
|
|
233
|
+
};
|
|
234
|
+
exports.getAgentProfiles = getAgentProfiles;
|
|
235
|
+
/**
|
|
236
|
+
* Create a new agent profile.
|
|
237
|
+
*
|
|
238
|
+
* @param client - The API client.
|
|
239
|
+
* @param payload - The agent profile data.
|
|
240
|
+
* @returns The created agent profile.
|
|
241
|
+
*
|
|
242
|
+
* @example
|
|
243
|
+
* const profile = await createAgentProfile(client, {
|
|
244
|
+
* name: 'My Profile',
|
|
245
|
+
* description: 'Profile description',
|
|
246
|
+
* organization_id: 'org_123',
|
|
247
|
+
* proxy_cc: 'us',
|
|
248
|
+
* proxy_type: 'residential',
|
|
249
|
+
* captcha_solver_active: false,
|
|
250
|
+
* sticky_ip: false,
|
|
251
|
+
* credentials: []
|
|
252
|
+
* });
|
|
253
|
+
*/
|
|
254
|
+
const createAgentProfile = async (client, payload) => {
|
|
255
|
+
const response = await AgentsSDK.createAgentProfile({
|
|
256
|
+
client,
|
|
257
|
+
body: payload,
|
|
258
|
+
});
|
|
259
|
+
if (response.error) {
|
|
260
|
+
throw new Error(response.error.error);
|
|
261
|
+
}
|
|
262
|
+
return response.data;
|
|
263
|
+
};
|
|
264
|
+
exports.createAgentProfile = createAgentProfile;
|
|
265
|
+
/**
|
|
266
|
+
* Get a specific agent profile by ID.
|
|
267
|
+
*
|
|
268
|
+
* @param client - The API client.
|
|
269
|
+
* @param profileId - The agent profile ID.
|
|
270
|
+
* @returns The agent profile.
|
|
271
|
+
*
|
|
272
|
+
* @example
|
|
273
|
+
* const profile = await getAgentProfile(client, 'profile_123');
|
|
274
|
+
*/
|
|
275
|
+
const getAgentProfile = async (client, profileId) => {
|
|
276
|
+
const response = await AgentsSDK.getAgentProfile({
|
|
277
|
+
client,
|
|
278
|
+
path: { profile_id: profileId },
|
|
279
|
+
});
|
|
280
|
+
if (response.error) {
|
|
281
|
+
throw new Error(response.error.error);
|
|
282
|
+
}
|
|
283
|
+
return response.data;
|
|
284
|
+
};
|
|
285
|
+
exports.getAgentProfile = getAgentProfile;
|
|
286
|
+
/**
|
|
287
|
+
* Update an existing agent profile.
|
|
288
|
+
*
|
|
289
|
+
* @param client - The API client.
|
|
290
|
+
* @param profileId - The agent profile ID.
|
|
291
|
+
* @param payload - The update data.
|
|
292
|
+
* @returns The updated agent profile.
|
|
293
|
+
*
|
|
294
|
+
* @example
|
|
295
|
+
* const updated = await updateAgentProfile(client, 'profile_123', { name: 'New Name' });
|
|
296
|
+
*/
|
|
297
|
+
const updateAgentProfile = async (client, profileId, payload) => {
|
|
298
|
+
const response = await AgentsSDK.updateAgentProfile({
|
|
299
|
+
client,
|
|
300
|
+
path: { profile_id: profileId },
|
|
301
|
+
body: payload,
|
|
302
|
+
});
|
|
303
|
+
if (response.error) {
|
|
304
|
+
throw new Error(response.error.error);
|
|
305
|
+
}
|
|
306
|
+
return response.data;
|
|
307
|
+
};
|
|
308
|
+
exports.updateAgentProfile = updateAgentProfile;
|
|
309
|
+
/**
|
|
310
|
+
* Delete an agent profile by ID.
|
|
311
|
+
*
|
|
312
|
+
* @param client - The API client.
|
|
313
|
+
* @param profileId - The agent profile ID.
|
|
314
|
+
* @returns A success message.
|
|
315
|
+
*
|
|
316
|
+
* @example
|
|
317
|
+
* await deleteAgentProfile(client, 'profile_123');
|
|
318
|
+
*/
|
|
319
|
+
const deleteAgentProfile = async (client, profileId) => {
|
|
320
|
+
const response = await AgentsSDK.deleteAgentProfile({
|
|
321
|
+
client,
|
|
322
|
+
path: { profile_id: profileId },
|
|
323
|
+
});
|
|
324
|
+
if (response.error) {
|
|
325
|
+
throw new Error(response.error.error);
|
|
326
|
+
}
|
|
327
|
+
return response.data;
|
|
328
|
+
};
|
|
329
|
+
exports.deleteAgentProfile = deleteAgentProfile;
|
|
214
330
|
/**
|
|
215
331
|
* Optionally, re-export all generated functions and types.
|
|
216
332
|
*/
|