ATM template fields
A Tradovate ATM template stores a scale-out bracket so a webhook can use it by name. The config values use the same syntax as the webhook fields described in Tradovate ATM.
| Field | Type | Access | Constraints | Description |
|---|---|---|---|---|
id | string | R | Template id, assigned when it is created | |
name | string | W | 1 to 64 characters: letters, digits, spaces, _, . and -, starting with a letter or digit and not ending with a space. Unique, not case-sensitive (409 template_name_conflict) | The name webhooks use |
description | string or null | W | At most 500 characters. null removes it | Your note |
active | boolean | W | New templates are off unless you send true | Only active templates can be used by webhooks |
config | object | W | Checked as a whole with the webhook parser | The bracket definition |
config.targets | string or null | W | Required. Same as atm_targets | Profit-target offsets, one per tier |
config.stops | string or null | W | Required. Same as atm_stops | Stop offsets, one per tier |
config.quantities | string or null | W | Same as atm_qtys | Quantity per tier |
config.trail | string or null | W | Same as atm_trail | Which tiers trail |
config.trailTrigger | string or null | W | Same as atm_trail_trigger | Profit distance that arms a trailing tier |
config.trailOffset | string or null | W | Same as atm_trail_offset | How far the trailing stop follows the best price |
config.breakeven | string or null | W | Same as atm_breakeven | Target tier whose fill moves stops to breakeven |
config.breakevenOffset | string or null | W | Same as atm_breakeven_offset | Offset past entry for the breakeven stop |
created | string (timestamp) or null | R | When the template was created | |
updated | string (timestamp) or null | R | When the template last changed |
In a PATCH, a config field set to null removes it, and the whole configuration is checked again after the change.
When the configuration is not valid, the error is 422 invalid_atm_config. fields lists the config.* fields involved, and detail names the problem using the same field names, for example config.targets=abc is not a valid number or config.quantities must have exactly 2 value(s) to match config.targets; got 1 (with fields holding config.quantities and config.targets). When the problem does not name a field, fields points at config.
A create refuses id, created and updated (422 field_read_only). A PATCH may echo them back from a GET: they are ignored when they equal the saved values (updated always is) and refused when they differ.
Changes apply to the next webhook signal that names the template.