---
title: "DECTRIS D.LAB Job API"
url: "https://help.dectris.cloud/en/article/dectris-dlab-jobs-api"
language: "en"
last_updated: "2026-07-15T07:50:50.099Z"
---

# DECTRIS D.LAB Job API

## **Configuring job templates for the job API**

The **DECTRIS D.LAB Job API** lets lab managers and local scientists script job submissions based on pre-configured job templates.

To configure which job templates can be submitted by a specific lab, go to the cockpit area and click on the processing panel. This opens a view in which you can configure up to four job template slots by choosing the template name, template version, default machine type and default disk size (for the job work directory) : 

![](https://cdn-assets.productfruits.com/7d1c941f-4f45-4c63-af23-7cd1070ac8e4)

After clicking save to apply the changes, a pop-up displays an example **POST** request and equivalent **curl** command that can be used as a starting point for programmatic submissions.

The number of template slots is limited by the facility tier:

-   Free: 0
-   Base: 2
-   Accelerate: 4

## **Configuring machine type and disk size**

To overwrite the default machine type, replace the empty machine type key `""` with one of the following:

-   `"free"` 
-   `"base"` 
-   `"swift"`
-   `"dash(gpu)"`
-   `"turbo"`
-   `"hypersonic"`
-   `"hypersonic(4gpu)"`
-   `"lightspeed"`
-   `"lightspeed(Sapphire Rapids)"`

To overwrite the default disk size, replace the empty disk size key `""` with one of the following disk sizes (as str):

-   `"16"` 
-   `"32"` 
-   `"64"` 
-   `"128"` 
-   `"256"`
-   `"512"`
-   `"1024"`

## **Examples**

Below is an example curl command, where the machine type is overwritten to be `base` and the disk size if overwritten to be `64` GB. Note the different typings of the parameters:

```plaintext
curl -X POST https://api.dectris.cloud/v0/job/trigger/1 \
  -H "Authorization: Bearer $DECTRIS_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
  "machine_type": "base",
  "disk_size": "64",
  "parameters": {
    "DC_EXAMPLE_VAR": "example value",
    "DC_NUM": 33.3,
    "DC_BOOL": true,
    "DC_PATH": "",
    "DC_LIST_STR": [
      "An",
      "Example",
      "Job"
    ],
    "DC_LIST_NUM": [
      2,
      3,
      4.5,
      -1.34
    ],
    "DC_LIST_BOOL": [
      true,
      true,
      false
    ]
  }
}'
```

The example assumes that the environment variable `DECTRIS_TOKEN` has been set to be the API token from the cockpit:

 ![](https://cdn-assets.productfruits.com/7fab2c03-77ae-41ff-ad70-fade597b98ee)
