ReluAutomate
Core concepts

Presets

A preset is a saved, named set of parameter and output settings for a service, created in the platform and reused by ID when you create orders.

A preset is a reusable, named bundle of settings for one service. You create it once in the platform UI — configuring a service's parameters (and output files) exactly how you want them — and then reference it by preset_id every time you create an order. The order inherits the preset's settings, so you don't have to spell out every parameter_value on each request.

Presets are scoped to your organization and tied to a single service_id. A given preset can only be used with the service it was created for.

Two ways to set up an order

When you create an order you choose how the parameters get filled. Both are valid — pick based on how much control you want at call time:

Explicit parametersPresets
HowSend every value in parameter_valuesSave settings once in the UI, send preset_id
Best whenYou vary options per order and want to set them flexibly from your sideYou have a stable, well-defined configuration per service and rarely change it
Where config livesIn your codeIn the Relu platform, editable without a code change
Override per ordern/aYes — send parameter_values alongside preset_id to override individual keys

You can also mix the two: start from a preset and override just the handful of parameters that differ for a given order. See Combining a preset with overrides.

Creating a preset in the platform

  1. Log in to automate.relu.ai and open the service you want to configure.
  2. Set the parameters (and, if relevant, the output files) to the values you want.
  3. Click Save Preset, give it a name, and save.

The preset now belongs to your organization and shows up wherever that service is used. Editing the preset later changes the configuration for every future order that references it — no code change on your side.

Presets capture more than parameters

A preset also stores the service's output file selection and, for services that support it, the engraving / text selection. Referencing the preset in an order pulls all of these in, not just parameter_values.

Finding a preset's ID

preset_id is what you pass when creating an order. Discover it via:

  • GET /presets — lists active presets in your organization. Filter by service_id to find presets for a given service. Pass include_deleted=true to also return soft-deleted presets; the deleted field identifies them.
  • GET /presets/{preset_id} — fetch a single preset, including its parameter_name_to_value, to inspect exactly what it will apply.
  • GET /services/{service_id} — the service response includes an included_presets array with the presets available for that service.
import requests

presets = requests.get(
    "https://api.automate.relu.ai/presets",
    headers={"Authorization": "ApiKey <your_api_token>"},
).json()

for p in presets:
    if p["service_id"] == "<service-uuid>":
        print(p["id"], p["name"])
const res = await fetch('https://api.automate.relu.ai/presets', {
  headers: { Authorization: `ApiKey ${process.env.RELU_API_TOKEN}` },
});
const presets = await res.json();
presets
  .filter((p) => p.service_id === '<service-uuid>')
  .forEach((p) => console.log(p.id, p.name));

Reading and writing presets through the API requires the matching preset scopes on your token (read:presets, create:presets, …). See Scopes.

Using a preset when creating an order

Pass preset_id in the POST /orders body instead of (or alongside) parameter_values. You still provide input_data and service_id as usual:

response = requests.post(
    "https://api.automate.relu.ai/orders",
    json={
        "service_id": "<service-uuid>",
        "preset_id": "<preset-uuid>",
        "order_name": "case-001",
        "input_data": {
            "lower_jaw": {
                "external_download_url": "https://.../lower.stl",
                "extension": ".stl",
            },
        },
        "callback_url": "https://your-app.com/relu-webhook",
    },
    headers={"X-API-Key": "<your_api_token>"},
)
order = response.json()
print(order["id"])
const res = await fetch('https://api.automate.relu.ai/orders', {
  method: 'POST',
  headers: {
    'X-API-Key': process.env.RELU_API_TOKEN,
    'Content-Type': 'application/json',
  },
  body: JSON.stringify({
    service_id: '<service-uuid>',
    preset_id: '<preset-uuid>',
    order_name: 'case-001',
    input_data: {
      lower_jaw: {
        external_download_url: 'https://.../lower.stl',
        extension: '.stl',
      },
    },
    callback_url: 'https://your-app.com/relu-webhook',
  }),
});
const order = await res.json();
console.log(order.id);

Combining a preset with overrides

You don't have to choose all-or-nothing. Send preset_id for the baseline and parameter_values for the few keys that differ on this order. Relu resolves parameters in this priority order:

  1. parameter_values you send on the order (highest priority)
  2. The preset's saved values
  3. The service's built-in defaults (lowest priority)

So any key present in parameter_values wins; everything else falls back to the preset, and anything the preset doesn't set falls back to the service default.

{
  "service_id": "<service-uuid>",
  "preset_id": "<preset-uuid>",
  "order_name": "case-001",
  "input_data": {
    "lower_jaw": { "external_download_url": "...", "extension": ".stl" }
  },
  "parameter_values": {
    "guide_thickness": 2.8
  }
}

In the example above the order uses every setting from the preset, except guide_thickness, which is overridden to 2.8 for this order only. The preset itself is unchanged.

On this page