Start typing to search.

API Reference

Create team explorer preset

View Markdown
POST /api/explorer-presets

Saves a reusable (optionally parameterized) Data Explorer query. Parameters are allowed for visual-mode presets (placeholders in filter values) and for raw-mode presets whose rawQuery is valid JSON (placeholders inside JSON string literals, e.g. Mongo). Every parameter must be referenced by a {{name}} placeholder, and every placeholder must reference a declared parameter.

Operation IDcreateExplorerPreset

Authentication

  • BearerAuth·http bearer·API key token (envoy_<hex>). Create keys from Settings → API Keys — see Using the API.

Request body

This request body is required.

Content typeapplication/json

requestobject
4 properties
namestringrequired
connector_idinteger | null
resourcestring | null
definitionobjectrequired
12 properties
modestringrequired

Parameters are allowed in visual mode (placeholders in filter values) and in raw mode when rawQuery is valid JSON (placeholders inside JSON string literals). SQL/OData raw queries cannot be parameterized.

filtersarray<ExplorerFilter>
Array items
itemobject
4 properties
fieldstringrequired
operatorstringrequired
valuestringrequired

A literal value, or a {{param}} placeholder referencing a name in the preset's parameters.

valueTypestring

Optional type hint. Use objectId for MongoDB ObjectId fields so the value is coerced to Extended JSON on apply.

actionstring

Visual builder action. Defaults to find when omitted.

rawQuerystring

Raw query string for mode: raw (SQL, Mongo Extended JSON, or OData). Ignored by parameterization.

columnsarray<string>
Array items
itemstring
limitstring
sortstring

Visual-mode sort column

orderstring

Visual-mode sort direction (omit or asc when unsorted / ascending)

resultViewstring
jsonatastring
csvDelimiterstring
parametersarray<PresetParameter>

Visual-mode only. Every parameter must be referenced by a {{name}} placeholder in a filter value, and every placeholder must reference a declared parameter.

Array items
itemobject
11 properties
namestringrequired

Referenced as {{name}} in a filter value. Letters, numbers, and underscores only; unique within the preset.

labelstringrequired

Shown in the apply dialog.

requiredboolean
typestringrequired

string — free text. objectId — free text validated as a 24-char hex ObjectId. mongoRecord — searchable record picker over a Mongo collection on the preset's connector.

collectionstring

Required for mongoRecord. The Mongo collection to query (e.g. migration_jobs).

valueFieldstring

mongoRecord. Field substituted into the filter. Defaults to _id (coerced to ObjectId hex).

labelFieldstring

mongoRecord. Primary display label (e.g. name).

descriptionFieldsarray<string>

mongoRecord. Muted metadata fields shown under the label.

Array items
itemstring
searchFieldsarray<string>

mongoRecord. Fields searched server-side for the picker query.

Array items
itemstring
filterobject

mongoRecord. Base filter merged into every picker query.

sortobject

mongoRecord. Mongo sort object.

Additional properties
valueinteger

Success response body

201Created preset

Created preset

Content typeapplication/json

responseobject
8 properties
idinteger
namestring
connector_idinteger | null
resourcestring | null
definitionobject
12 properties
modestringrequired

Parameters are allowed in visual mode (placeholders in filter values) and in raw mode when rawQuery is valid JSON (placeholders inside JSON string literals). SQL/OData raw queries cannot be parameterized.

filtersarray<ExplorerFilter>
Array items
itemobject
4 properties
fieldstringrequired
operatorstringrequired
valuestringrequired

A literal value, or a {{param}} placeholder referencing a name in the preset's parameters.

valueTypestring

Optional type hint. Use objectId for MongoDB ObjectId fields so the value is coerced to Extended JSON on apply.

actionstring

Visual builder action. Defaults to find when omitted.

rawQuerystring

Raw query string for mode: raw (SQL, Mongo Extended JSON, or OData). Ignored by parameterization.

columnsarray<string>
Array items
itemstring
limitstring
sortstring

Visual-mode sort column

orderstring

Visual-mode sort direction (omit or asc when unsorted / ascending)

resultViewstring
jsonatastring
csvDelimiterstring
parametersarray<PresetParameter>

Visual-mode only. Every parameter must be referenced by a {{name}} placeholder in a filter value, and every placeholder must reference a declared parameter.

Array items
itemobject
11 properties
namestringrequired

Referenced as {{name}} in a filter value. Letters, numbers, and underscores only; unique within the preset.

labelstringrequired

Shown in the apply dialog.

requiredboolean
typestringrequired

string — free text. objectId — free text validated as a 24-char hex ObjectId. mongoRecord — searchable record picker over a Mongo collection on the preset's connector.

collectionstring

Required for mongoRecord. The Mongo collection to query (e.g. migration_jobs).

valueFieldstring

mongoRecord. Field substituted into the filter. Defaults to _id (coerced to ObjectId hex).

labelFieldstring

mongoRecord. Primary display label (e.g. name).

descriptionFieldsarray<string>

mongoRecord. Muted metadata fields shown under the label.

Array items
itemstring
searchFieldsarray<string>

mongoRecord. Fields searched server-side for the picker query.

Array items
itemstring
filterobject

mongoRecord. Base filter merged into every picker query.

sortobject

mongoRecord. Mongo sort object.

Additional properties
valueinteger
created_byinteger
created_atstring · date-time
updated_atstring | null · date-time

Error responses

400Validation error (invalid definition)

Validation error (invalid definition)

Content typeapplication/json

responseobject
2 properties
errorstring
messagestring