ProjectsJobs
Enqueue a job
POST
400 for an unknown type, or input that type does not take; 409 when the same job is already queued or running.
Who may call it: Whoever manages the project: an owner, security admin or admin of its organization, or an admin of the project. API keys: no.
sessioncookie
gamma.session_token<token>The session cookie a sign-in sets. Over HTTPS its name carries the __Secure- prefix. Browsers send it on their own; other clients keep it from the sign-in response.
projectId*stringThe project's id.
application/json- body
type*stringA registered job type, e.g. model.convert.
Length
1 <= length <= 50input*unknownWhat that type takes.
Created.
application/json- response
job*Example Request
curl -X POST 'http://localhost:3000/api/projects/string/jobs' \ -H 'Content-Type: application/json' \ -d '{ "type": "string", "input": null}'Example Response
{ "job": { "id": "string", "type": "string", "status": "queued", "attempts": -9007199254740991, "runAt": "2019-08-24T14:15:22Z", "startedAt": "2019-08-24T14:15:22Z", "finishedAt": "2019-08-24T14:15:22Z", "leaseUntil": "2019-08-24T14:15:22Z", "workerId": "string", "lastError": "string", "createdById": "string", "createdAt": "2019-08-24T14:15:22Z", "updatedAt": "2019-08-24T14:15:22Z", "subject": { "kind": "model", "id": "string", "label": "string" }, "input": null, "result": { "outputs": [ { "name": "string", "key": "string", "sizeBytes": -9007199254740991, "external": true } ], "data": { "property1": null, "property2": null }, "supersededBy": "string", "replacedByVersion": -9007199254740991 } }}