Skip to Content
CosmicAC Logo
API referenceApp node API

Job routes

Job submission, status and history.

/auth/jobs/action

POST
/auth/jobs/action

Requires team capability jobs.action. Acts on the team in the X-Team-Id header. If omitted, the caller's only team membership is used.

Authorization

ttrToken
headerttr-token<token>

Session token issued by sign-in. Sent as the ttr-token header.

Header Parameters

x-team-id?string

Team to act on. Required only when the caller belongs to more than one team.

Request Body

application/json
  1. body
ids*array<>
Items1 <= items
action*string
Value in"start""stop""restart"

Response Body

Default Response

Example Request
curl -X POST 'https://your-app-node-url/auth/jobs/action' \  -H 'ttr-token: <session-token>' \  -H 'Content-Type: application/json' \  -d '{  "ids": [    "6e0346a3-e54d-40e3-9779-4ba1e707e35b"  ],  "action": "start"}'
Example Response200
Empty

/v1/auth/jobs

GET
/v1/auth/jobs

Requires team capability jobs.read. Acts on the team in the X-Team-Id header. If omitted, the caller's only team membership is used.

Authorization

ttrToken
headerttr-token<token>

Session token issued by sign-in. Sent as the ttr-token header.

Query Parameters

search?string
type?|array<>
status?|array<>
sort?string
Value in"newest""oldest""name_az""status"
offset?integer
Range0 <= value
limit?integer
Range1 <= value
overwrite_cache?boolean

Header Parameters

x-team-id?string

Team to act on. Required only when the caller belongs to more than one team.

Response Body

Default Response

Example Request
curl -X GET 'https://your-app-node-url/v1/auth/jobs' \  -H 'ttr-token: <session-token>'
Example Response200
Empty

/v1/auth/jobs

POST
/v1/auth/jobs

Requires team capability jobs.create. Acts on the team in the X-Team-Id header. If omitted, the caller's only team membership is used.

Authorization

ttrToken
headerttr-token<token>

Session token issued by sign-in. Sent as the ttr-token header.

Header Parameters

x-team-id?string

Team to act on. Required only when the caller belongs to more than one team.

Request Body

application/json
  1. body
name?string
tags?array<string>
location?string
type?"GPU_CONTAINER"
Value in"GPU_CONTAINER"
cost_limit?number
alerts?
notification_preferences?
params*
gpu?

Response Body

Default Response

Example Request
curl -X POST 'https://your-app-node-url/v1/auth/jobs' \  -H 'ttr-token: <session-token>' \  -H 'Content-Type: application/json' \  -d '{  "name": "string",  "tags": [    "string"  ],  "location": "string",  "type": "GPU_CONTAINER",  "gpu": {    "type": "string",    "count": 0,    "cpu_cores_per_gpu": 1,    "mem_gb_per_gpu": 1  },  "params": {    "base_image": "string"  }}'
Example Response200
Empty

/auth/job/{id}

GET
/auth/job/{id}

Requires team capability jobs.read. Acts on the team in the X-Team-Id header. If omitted, the caller's only team membership is used.

Authorization

ttrToken
headerttr-token<token>

Session token issued by sign-in. Sent as the ttr-token header.

Path Parameters

id*string

Query Parameters

overwrite_cache?boolean

Header Parameters

x-team-id?string

Team to act on. Required only when the caller belongs to more than one team.

Response Body

Default Response

Example Request
curl -X GET 'https://your-app-node-url/auth/job/string' \  -H 'ttr-token: <session-token>'
Example Response200
Empty

/auth/job/{id}

POST
/auth/job/{id}

Requires team capability jobs.action. Acts on the team in the X-Team-Id header. If omitted, the caller's only team membership is used.

Authorization

ttrToken
headerttr-token<token>

Session token issued by sign-in. Sent as the ttr-token header.

Path Parameters

id*string

Header Parameters

x-team-id?string

Team to act on. Required only when the caller belongs to more than one team.

Response Body

Default Response

Example Request
curl -X POST 'https://your-app-node-url/auth/job/string' \  -H 'ttr-token: <session-token>'
Example Response200
Empty

/auth/job/{id}

PATCH
/auth/job/{id}

Requires team capability jobs.update. Acts on the team in the X-Team-Id header. If omitted, the caller's only team membership is used.

Authorization

ttrToken
headerttr-token<token>

Session token issued by sign-in. Sent as the ttr-token header.

Path Parameters

id*string

Header Parameters

x-team-id?string

Team to act on. Required only when the caller belongs to more than one team.

Request Body

application/json
  1. body
name*string

Response Body

Default Response

Example Request
curl -X PATCH 'https://your-app-node-url/auth/job/string' \  -H 'ttr-token: <session-token>' \  -H 'Content-Type: application/json' \  -d '{  "name": "string"}'
Example Response200
Empty

/auth/job/{id}

DELETE
/auth/job/{id}

Requires team capability jobs.delete. Acts on the team in the X-Team-Id header. If omitted, the caller's only team membership is used.

Authorization

ttrToken
headerttr-token<token>

Session token issued by sign-in. Sent as the ttr-token header.

Path Parameters

id*string

Header Parameters

x-team-id?string

Team to act on. Required only when the caller belongs to more than one team.

Response Body

Default Response

Example Request
curl -X DELETE 'https://your-app-node-url/auth/job/string' \  -H 'ttr-token: <session-token>'
Example Response200
Empty
POST
/auth/job/{id}/replica/{replicaId}

Requires team capability jobs.action. Acts on the team in the X-Team-Id header. If omitted, the caller's only team membership is used.

Authorization

ttrToken
headerttr-token<token>

Session token issued by sign-in. Sent as the ttr-token header.

Path Parameters

id*string
replicaId*string

Header Parameters

x-team-id?string

Team to act on. Required only when the caller belongs to more than one team.

Response Body

Default Response

Example Request
curl -X POST 'https://your-app-node-url/auth/job/string/replica/string' \  -H 'ttr-token: <session-token>'
Example Response200
Empty
DELETE
/auth/job/{id}/replica/{replicaId}

Requires team capability jobs.delete. Acts on the team in the X-Team-Id header. If omitted, the caller's only team membership is used.

Authorization

ttrToken
headerttr-token<token>

Session token issued by sign-in. Sent as the ttr-token header.

Path Parameters

id*string
replicaId*string

Header Parameters

x-team-id?string

Team to act on. Required only when the caller belongs to more than one team.

Response Body

Default Response

Example Request
curl -X DELETE 'https://your-app-node-url/auth/job/string/replica/string' \  -H 'ttr-token: <session-token>'
Example Response200
Empty
GET
/auth/job/{id}/status-flow

Requires team capability jobs.read. Acts on the team in the X-Team-Id header. If omitted, the caller's only team membership is used.

Authorization

ttrToken
headerttr-token<token>

Session token issued by sign-in. Sent as the ttr-token header.

Path Parameters

id*string

Query Parameters

overwrite_cache?boolean

Header Parameters

x-team-id?string

Team to act on. Required only when the caller belongs to more than one team.

Response Body

Default Response

Example Request
curl -X GET 'https://your-app-node-url/auth/job/string/status-flow' \  -H 'ttr-token: <session-token>'
Example Response200
Empty

/v1/auth/jobs/validate

POST
/v1/auth/jobs/validate

Requires team capability jobs.create. Acts on the team in the X-Team-Id header. If omitted, the caller's only team membership is used.

Authorization

ttrToken
headerttr-token<token>

Session token issued by sign-in. Sent as the ttr-token header.

Header Parameters

x-team-id?string

Team to act on. Required only when the caller belongs to more than one team.

Request Body

application/json
  1. body
name?string
tags?array<string>
location?string
type?"GPU_CONTAINER"
Value in"GPU_CONTAINER"
cost_limit?number
alerts?
notification_preferences?
params*
gpu?

Response Body

Default Response

Example Request
curl -X POST 'https://your-app-node-url/v1/auth/jobs/validate' \  -H 'ttr-token: <session-token>' \  -H 'Content-Type: application/json' \  -d '{  "name": "string",  "tags": [    "string"  ],  "location": "string",  "type": "GPU_CONTAINER",  "gpu": {    "type": "string",    "count": 0,    "cpu_cores_per_gpu": 1,    "mem_gb_per_gpu": 1  },  "params": {    "base_image": "string"  }}'
Example Response200
Empty
GET
/v1/auth/endpoints/availability

Requires team capability jobs.create. Acts on the team in the X-Team-Id header. If omitted, the caller's only team membership is used.

Authorization

ttrToken
headerttr-token<token>

Session token issued by sign-in. Sent as the ttr-token header.

Query Parameters

name*string
Length1 <= length <= 63

Header Parameters

x-team-id?string

Team to act on. Required only when the caller belongs to more than one team.

Response Body

Default Response

Example Request
curl -X GET 'https://your-app-node-url/v1/auth/endpoints/availability?name=string' \  -H 'ttr-token: <session-token>'
Example Response200
Empty
POST
/v1/admin/jobs/backfill-team

Requires platform admin.

Authorization

ttrToken
headerttr-token<token>

Session token issued by sign-in. Sent as the ttr-token header.

Request Body

application/json
  1. body
teamId?string
Length1 <= length
dryRun?boolean
jobIds?array<>
Items1 <= items <= 500

Response Body

Default Response

Example Request
curl -X POST 'https://your-app-node-url/v1/admin/jobs/backfill-team' \  -H 'ttr-token: <session-token>' \  -H 'Content-Type: application/json' \  -d '{}'
Example Response200
Empty