Skip to content

Runs API

The runs endpoints, each in TypeScript, Python, the CLI and curl.

Terminal window
npm install @reminix/sdk
export REMINIX_API_KEY="<your API key>"

To pass the key yourself, use createClient({ apiKey: key }) in TypeScript or Reminix(api_key=key) in Python.

Scope: runs:write.

Runs the script’s published version with these inputs, and returns the run when it finishes (201), with its output or error.

import { createClient } from "@reminix/sdk";
// Uses the REMINIX_API_KEY environment variable.
const reminix = createClient();
const run = await reminix.runs.create("unlock-account", {
inputs: {
email: "jane@example.com",
},
});
console.log(run);

Returns:

{
"id": "run_620f14ad-32e8-4f5e-89fd-1c80de7e9124",
"script": {
"id": "scr_6a7e78ca-5ef5-4c68-80cb-09aec047f7a3",
"slug": "unlock-account"
},
"version": 3,
"environment": "production",
"status": "succeeded",
"inputs": {
"email": "jane@example.com"
},
"output": {
"unlocked": true
},
"error": null,
"startedBy": {
"userId": "usr_276b6c46-92e7-4d47-89c1-2ada515bc3e4",
"name": "Ana Lopez",
"credential": {
"type": "pat",
"name": "ci"
}
},
"via": "api",
"automationName": null,
"approvalRequestId": null,
"scheduleId": null,
"triggerId": null,
"progress": null,
"progressMessage": null,
"test": false,
"logLines": 3,
"startedAt": "2026-10-02T14:05:00.000Z",
"finishedAt": "2026-10-02T14:05:02.400Z",
"durationMs": 1850,
"files": []
}
Field Description
slug string, path, required The slug's ID.
inputs object The script's inputs, by name. The default is no inputs.
via string Where the run came from, for the history. The default is api. Reminix records an agent's runs as agent whatever this says.
More about this endpoint

Reminix first checks the inputs against the version’s input schema. If they don’t match, the request returns 400 with one details entry per field. For a file input, pass a file id or an https link that Reminix fetches. The id can be a file you uploaded with files.upload, or a file another run saved. The script runs on its own fresh machine and can reach only the hosts its version declares. A run can last up to its version’s timeoutSeconds, at most 30, counted from when its code starts. Getting a machine can take up to 2 minutes first. If the run is still in progress after 60 seconds, the request returns 202 with status running, and you follow the run with runs.get. If the version’s timeoutSeconds is over 30, the run is a long run. A long run runs durably, and the request returns 202 at once. Every run counts toward the workspace’s runs usage.

Scope: runs:read.

Lists the workspace’s runs, newest first.

import { createClient } from "@reminix/sdk";
// Uses the REMINIX_API_KEY environment variable.
const reminix = createClient();
const runs = await reminix.runs.list();
console.log(runs);

Returns:

{
"items": [
{
"id": "run_620f14ad-32e8-4f5e-89fd-1c80de7e9124",
"script": {
"id": "scr_6a7e78ca-5ef5-4c68-80cb-09aec047f7a3",
"slug": "unlock-account"
},
"version": 3,
"environment": "production",
"status": "succeeded",
"inputs": {
"email": "jane@example.com"
},
"output": {
"unlocked": true
},
"error": null,
"startedBy": {
"userId": "usr_276b6c46-92e7-4d47-89c1-2ada515bc3e4",
"name": "Ana Lopez",
"credential": {
"type": "pat",
"name": "ci"
}
},
"via": "api",
"automationName": null,
"approvalRequestId": null,
"scheduleId": null,
"triggerId": null,
"progress": null,
"progressMessage": null,
"test": false,
"logLines": 3,
"startedAt": "2026-10-02T14:05:00.000Z",
"finishedAt": "2026-10-02T14:05:02.400Z",
"durationMs": 1850,
"files": []
}
],
"nextCursor": null
}
Field Description
limit number, query Items per page, 1–100 (default 25).
cursor string, query Opaque token from a previous page's nextCursor.
before string, query Start from this moment: items older than it, newest first. Ignored with cursor, which already says where to go on.
script string, query Only this script's runs, by its slug.
status string, query Only runs in this state.
More about this endpoint

Pass ?script=<slug> for one script’s runs and ?status= for runs in one state. Pass ?before= to start from a moment. Paginate with the opaque nextCursor token.

Scope: runs:read.

Returns one run, with its inputs, status, output or error, and who started it and how.

import { createClient } from "@reminix/sdk";
// Uses the REMINIX_API_KEY environment variable.
const reminix = createClient();
const run = await reminix.runs.get("run_620f14ad-32e8-4f5e-89fd-1c80de7e9124");
console.log(run);

Returns:

{
"id": "run_620f14ad-32e8-4f5e-89fd-1c80de7e9124",
"script": {
"id": "scr_6a7e78ca-5ef5-4c68-80cb-09aec047f7a3",
"slug": "unlock-account"
},
"version": 3,
"environment": "production",
"status": "succeeded",
"inputs": {
"email": "jane@example.com"
},
"output": {
"unlocked": true
},
"error": null,
"startedBy": {
"userId": "usr_276b6c46-92e7-4d47-89c1-2ada515bc3e4",
"name": "Ana Lopez",
"credential": {
"type": "pat",
"name": "ci"
}
},
"via": "api",
"automationName": null,
"approvalRequestId": null,
"scheduleId": null,
"triggerId": null,
"progress": null,
"progressMessage": null,
"test": false,
"logLines": 3,
"startedAt": "2026-10-02T14:05:00.000Z",
"finishedAt": "2026-10-02T14:05:02.400Z",
"durationMs": 1850,
"files": []
}
Field Description
runId string, path, required The run's ID.
More about this endpoint

The response also has the run’s files, both given and saved, each with a download link.

Scope: runs:write.

Cancels a long run that is still running.

import { createClient } from "@reminix/sdk";
// Uses the REMINIX_API_KEY environment variable.
const reminix = createClient();
const result = await reminix.runs.cancel("run_620f14ad-32e8-4f5e-89fd-1c80de7e9124");
console.log(result);

Returns:

{
"id": "run_620f14ad-32e8-4f5e-89fd-1c80de7e9124",
"script": {
"id": "scr_6a7e78ca-5ef5-4c68-80cb-09aec047f7a3",
"slug": "unlock-account"
},
"version": 3,
"environment": "production",
"status": "succeeded",
"inputs": {
"email": "jane@example.com"
},
"output": {
"unlocked": true
},
"error": null,
"startedBy": {
"userId": "usr_276b6c46-92e7-4d47-89c1-2ada515bc3e4",
"name": "Ana Lopez",
"credential": {
"type": "pat",
"name": "ci"
}
},
"via": "api",
"automationName": null,
"approvalRequestId": null,
"scheduleId": null,
"triggerId": null,
"progress": null,
"progressMessage": null,
"test": false,
"logLines": 3,
"startedAt": "2026-10-02T14:05:00.000Z",
"finishedAt": "2026-10-02T14:05:02.400Z",
"durationMs": 1850,
"files": []
}
Field Description
runId string, path, required The run's ID.
More about this endpoint

The run’s code stops, the run ends cancelled, and Reminix sends a run.cancelled event. The person who started the run, the script owner, a workspace owner or admin, or a workspace API key can cancel it.

Scope: runs:read.

Returns the run’s log: what the script wrote to standard error, line by line.

import { createClient } from "@reminix/sdk";
// Uses the REMINIX_API_KEY environment variable.
const reminix = createClient();
const result = await reminix.runs.log("run_620f14ad-32e8-4f5e-89fd-1c80de7e9124");
console.log(result);

Returns:

{
"lines": [
"Unlocking jane@example.com",
"→ POST api.yourapp.com/v1/users/unlock 200 (182 ms)",
"Unlocked jane@example.com"
]
}
Field Description
runId string, path, required The run's ID.
More about this endpoint

The log also has a line for each request the script made.