Retrieves information about the containers running on this node, and the number of jobs pending.
- Method:
GET - URL:
/info - Response:
- Success:
- Code:
200 OK - Content:
{ "containers": Container[], "pending": { "offchain": integer, "onchain": integer } }containers: Array of Container objectspending: Job countsoffchain: Offchain jobs pendingonchain: Onchain jobs pending
- Code:
- Success:
Creates a new off-chain job (direct compute request or subscription).
- Method:
POST - URL:
/api/jobs - Body: JobRequest
- Response:
- Success:
- Code:
200 OK - Content:
{ "id": string }id: UUID of the created job.
- Code:
- Failure:
- Code:
400 Bad Request - Content:
{"error": string[, "params": object]}error: Error messageparams: Additional error parameters (if applicable).
- Code:
- Success:
Creates off-chain jobs in batch (direct compute requests or subscriptions).
NOTE: Individual job requests fail silently in batch mode, i.e. this endpoint might
return 200 OK even if subset / all job requests fail. It is the caller's responsibility to check
the returned array for errors in creating jobs.
- Method:
POST - URL:
/api/jobs/batch - Body: JobRequest[]
- Response:
- Success:
- Code:
200 OK - Content:
{"id": string} | {"error": string[, "params": object]} []- Array of job UUID or error for each JobRequest in order, depending on successful creation.
- Code:
- Failure:
- Code:
400 Bad Request - Content:
{"error": string[, "params": object]}error: Error messageparams: Additional error parameters (if applicable).
- Code:
- Success:
Retrieves specific job results based on one or more provided job IDs. If the id query parameter is not provided, returns a list of job IDs for the client. Optionally filters by pending status.
- Method:
GET - URL:
/api/jobs - Query Parameters:
id(string, optional, repeatable): Job UUID(s). If provided, the endpoint returns the status of the specific job(s). Multiple job IDs can be specified by repeating this parameter (e.g.,?id=123&id=456). If omitted, the endpoint returns a list of job IDs for the given client.intermediate(boolean, optional): Only used ifidis provided. Flag for returning intermediate results. Applies to all specified jobspending(boolean, optional): Only used ifidis omitted. Flag to specify whether to fetch pending (true), finished (false), or all jobs (omit).
- Response:
- Success:
- Code:
200 OK - Content:
- If
idis provided: JobResult[]- If
intermediate=true, includes intermediate results.
- If
- If
idis not provided: An array of job IDs (string[])- If
pending=true, only returns pending jobs. - If
pending=false, only returns finished jobs. - If
pendingis omitted, returns all jobs.
- If
- If
- Code:
- Failure:
- Code:
400 Bad Request/404 Not Found - Content:
{ "error": string }error: Error message
- Code:
- Success:
Specifies a job, which consists of running one or more containers. If more than one container is specified, output of container i is input to container i+1; containers[0] takes data as input; and containers[n-1]'s output is the result of the job.
- containers (
string[]) - Array of container IDs to run in sequence. - data (
object) - The input data to be passed intocontainers[0].
{
"containers": string[],
"data": object
}- id: Job UUID.
- status:
"running","success", or"failed". - result: ContainerResult
- intermediate: Array of ContainerResults. Optional.
{
"id": string,
"status": string,
"result": ContainerResult,
"intermediate_results": ContainerResult[]
}Represents a containerized workload running on the node.
- id (
string) - ID of the container. - external (
boolean) - Whether the container is external, i.e.trueif container can be the first container in JobRequest.containers. - image (
string) - The DockerHub image this container is running. - description (
string, optional) - Description of the containerized workload.
{
"id": string,
"external": boolean,
"image": string,
"description": string
}Represents the output data of a container.
- container (
string) - ID of the container. - output (
object) - The output data, structure depends on the container.
{
"container": string,
"output": object
}Represents the output error of a container.
- container (
string) - ID of the container. - error (
string) - The error message from the container.
{
"container": string,
"error": string
}