#
The Basics
You can use the POST /job
endpoint to create Engine jobs. The full API documentation can be found here.
On older versions of the Engine (v2
and older), the /job
endpoint is called /generic-job
.
Through the body of the HTTP POST
request, you can specify how your job will look like. The following fields are available:
#
Input Files
required
The inputFiles
field determines which scan modalities you are sending over and how you will transfer them to the Engine API.
#
Output Files
required
The outputFiles
field specifies which results you are expecting and how you will receive them from the Engine API.
#
Options
optional
The options
field allows you to specify additional settings for your job.
#
Finish Webhook
optional
The finishWebhook
field allows you to specify a callback URL, used by the Engine to notify you when your job is finished. As soon as the job is done, the Engine API will submit a HTTP POST
request to this URL, passing the job results in the JSON body of the request. The JSON body is identical to what is returned when polling for the job result.
If you have your own API, we recommend this approach to save resources on polling for the job status.
An easy way to start experimenting with the callback without setting up an actual API route for it, is by using Ngrok.
- Start an HTTP tunnel, e.g.
ngrok http 8085
- Submit a Job to the Engine, using your Ngrok url as webhook, e.g.
{"finishWebhook": "<YOUR-NGROK-TUNNEL-URL>/my-webhook"}
- Open up the web inspection interface at
http://localhost:4040
to inspect the callback request(s).
#
External Job ID
deprecated
The externalJobId
field allows you to choose a unique identifier for your job. If you do not specify one, the Engine will generate one for you. We recommend leaving this field empty and instead relying on the unique identifier generated by the Engine, as this field will be removed in future versions.
#
Cloud Package
optional
The cloudPackage
field allows you to specify which license to use for this job. Only relevant if this was agreed upon through Sales. When used, this allows for splitting the billing and analytics across different licenses (e.g. production and internal testing).
#
End User ID
optional
The endUserId
field allows you to specify the end user that this job is for. Only relevant if this was agreed upon through Sales. When used, this allows for fine-grained analytics and billing.