openapi: 3.1.0 info: title: Exa Agent Monitors Runs API version: 2.0.0 description: Exa Agent API - subset of the Exa Public API. servers: - url: https://api.exa.ai security: - apiKey: [] - bearer: [] tags: - name: Monitors Runs paths: /v0/monitors/{monitor}/runs: servers: - url: https://api.exa.ai/websets get: description: Lists all runs for the Monitor. operationId: monitors-runs-list parameters: - name: monitor required: true in: path description: The id of the Monitor to list runs for schema: type: string responses: '200': description: List of monitor runs content: application/json: schema: $ref: '#/components/schemas/ListMonitorRunsResponse' headers: X-Request-Id: schema: type: string description: Unique identifier for the request. example: req_N6SsgoiaOQOPqsYKKiw5 required: true summary: List Monitor Runs tags: - Monitors Runs security: - apiKey: [] - bearer: [] x-codeSamples: - lang: javascript label: JavaScript source: "// npm install exa-js\nimport Exa from \"exa-js\";\nconst exa = new Exa(\"YOUR_EXA_API_KEY\");\n\nconst runs = await exa.websets.monitors.runs.list(\"monitor_id\");\n\nconsole.log(`Found ${runs.data.length} monitor runs`);\nruns.data.forEach((run) => {\n console.log(`- ${run.id}: ${run.status}`);\n});" - lang: python label: Python source: "# pip install exa-py\nfrom exa_py import Exa\n\nexa = Exa(\"YOUR_EXA_API_KEY\")\n\nruns = exa.websets.monitors.runs.list(\"monitor_id\")\n\nprint(f\"Found {len(runs.data)} monitor runs\")\nfor run in runs.data:\n print(f\"- {run.id}: {run.status}\")" /v0/monitors/{monitor}/runs/{id}: servers: - url: https://api.exa.ai/websets get: description: Gets a specific monitor run. operationId: monitors-runs-get parameters: - name: monitor required: true in: path description: The id of the Monitor to get the run for schema: type: string - name: id required: true in: path schema: type: string responses: '200': description: Monitor run details content: application/json: schema: $ref: '#/components/schemas/MonitorRun' headers: X-Request-Id: schema: type: string description: Unique identifier for the request. example: req_N6SsgoiaOQOPqsYKKiw5 required: true summary: Get Monitor Run tags: - Monitors Runs security: - apiKey: [] - bearer: [] x-codeSamples: - lang: javascript label: JavaScript source: '// npm install exa-js import Exa from "exa-js"; const exa = new Exa("YOUR_EXA_API_KEY"); const run = await exa.websets.monitors.runs.get("monitor_id", "run_id"); console.log(`Monitor run: ${run.id} - ${run.status}`);' - lang: python label: Python source: '# pip install exa-py from exa_py import Exa exa = Exa("YOUR_EXA_API_KEY") run = exa.websets.monitors.runs.get("monitor_id", "run_id") print(f"Monitor run: {run.id} - {run.status}")' components: schemas: ListMonitorRunsResponse: type: - object properties: data: type: - array items: type: - object $ref: '#/components/schemas/MonitorRun' description: The list of monitor runs hasMore: type: - boolean description: Whether there are more results to paginate through nextCursor: type: string description: The cursor to paginate through the next set of results nullable: true required: - data - hasMore - nextCursor MonitorRun: type: - object properties: id: type: - string description: The unique identifier for the Monitor Run object: type: - string enum: - monitor_run description: The type of object status: type: - string enum: - created - running - completed - canceled - failed description: The status of the Monitor Run monitorId: type: - string description: The monitor that the run is associated with type: type: - string enum: - search - refresh description: The type of the Monitor Run completedAt: type: string format: date-time description: When the run completed nullable: true failedAt: type: string format: date-time description: When the run failed nullable: true failedReason: type: string description: The reason the run failed nullable: true canceledAt: type: string format: date-time description: When the run was canceled nullable: true createdAt: type: - string format: date-time description: When the run was created updatedAt: type: - string format: date-time description: When the run was last updated required: - id - object - monitorId - status - type - completedAt - failedAt - failedReason - canceledAt - createdAt - updatedAt securitySchemes: apiKey: type: apiKey name: x-api-key in: header description: 'Pass your Exa API key in the x-api-key header. You can also authenticate with Authorization: Bearer .' bearer: type: http scheme: bearer description: 'Pass your Exa API key in the x-api-key header. You can also authenticate with Authorization: Bearer .'