Skip to main content
Braintrust logo
  • Category: artificial intelligence
  • Auth: API_KEY
  • Composio-managed OAuth available? N/A
  • Tools: 17
  • Triggers: 0
  • Slug: BRAINTRUST
  • Version: 20261030_00

Tools

Slug: BRAINTRUST_CREATE_DATASETCreate a named dataset under a Braintrust project, or return the existing dataset unchanged when its name already exists in that project.

Input Parameters

string
required
Dataset name, which must be unique within the project. Braintrust returns the existing dataset unchanged when this name already exists.
array
Tags to attach to the dataset.
object
User-controlled dataset metadata as an object.
string
required
UUID of the Braintrust project that will contain the dataset.
string
Optional human-readable dataset description.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: BRAINTRUST_CREATE_EXPERIMENTCreate an experiment under a Braintrust project. When its name already exists, Braintrust returns the existing experiment unchanged unless ensure_new is true, which creates an experiment with a unique name.

Input Parameters

string
Experiment name. Names are unique within a project unless ensure_new is true.
array
Tags to attach to the experiment.
boolean
Whether anyone inside or outside the organization can view the experiment.
object
User-controlled experiment metadata as an object.
string
UUID of the dataset linked to this experiment, when applicable.
boolean
Generate a unique experiment name on a name conflict. When false, Braintrust returns the existing same-name experiment unchanged.
string
required
UUID of the Braintrust project that will contain the experiment.
string
Optional human-readable experiment description.
string
Version of the linked dataset used for reproducibility.
string
UUID of the default baseline experiment used for comparisons.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: BRAINTRUST_CREATE_PROJECTCreate a Braintrust project, or return the existing project unchanged when its name already exists.

Input Parameters

string
required
Project name. Braintrust returns an existing project unchanged when this name already exists, so use a unique name when a new project is required.
string
Organization name for the rare case where the API key’s active data plane supports organization selection. This does not reliably switch organizations.
string
Optional human-readable project description.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: BRAINTRUST_CREATE_PROMPTUpsert a versioned prompt configuration under a Braintrust project without invoking it. The same project and slug reuse the prompt ID but create a new version that replaces the stored prompt configuration with the submitted configuration. MCP attachments and tool-function bindings are unsupported.

Input Parameters

string
required
Human-readable prompt name.
string
required
Prompt identity slug within the project. Reusing the same project and slug keeps the prompt ID but creates a new version that replaces the stored prompt configuration with the submitted configuration.
array
Tags to attach to the prompt.
string
required
UUID of the Braintrust project that will contain the prompt.
string
Optional human-readable prompt description.
object
Structured prompt block, model options, and parser configuration. MCP attachments and tool_functions are rejected by this schema.
string ("llm" | "scorer" | "task" | "tool" | "custom_view" | "preprocessor" | "facet" | "classifier" | "tag" | "parameters" | "sandbox")
Braintrust function classification assigned to the prompt.
string ("mustache" | "nunjucks" | "none")
Template syntax to store inside prompt_data.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: BRAINTRUST_DELETE_PROJECTSoft-delete a Braintrust project and return its deletion state.

Input Parameters

string
required
UUID of the Braintrust project to soft-delete.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: BRAINTRUST_DELETE_RESOURCEDelete one Braintrust experiment, dataset, or prompt by UUID for explicit lifecycle cleanup.

Input Parameters

string
required
UUID of the selected resource to delete.
string ("experiment" | "dataset" | "prompt")
required
Kind of Braintrust resource to delete.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: BRAINTRUST_FETCH_EVENTSFetch one newest-to-oldest page of project log, experiment, or dataset events.

Input Parameters

integer
Maximum full traces to request. A page can contain more events because one trace may contain multiple events.
string
Optional historical transaction version snapshot to fetch.
string
Opaque continuation token returned by a previous call. Omit it for the first page and pass it back unchanged to continue newest-to-oldest.
string
required
Project, experiment, or dataset UUID matching resource_type.
string ("project_logs" | "experiment" | "dataset")
required
Event stream to fetch.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: BRAINTRUST_GET_RESOURCEGet one project, experiment, dataset, prompt, or function by UUID.

Input Parameters

string
required
UUID of the selected Braintrust resource.
string ("project" | "experiment" | "dataset" | "prompt" | "function")
required
Kind of Braintrust resource to retrieve.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: BRAINTRUST_INSERT_DATASET_EVENTSUpsert a batch of examples into an existing Braintrust dataset. New or omitted IDs insert events; an existing supplied ID replaces that event’s current values.

Input Parameters

array
required
Dataset examples to upsert, in the order represented by returned row IDs. An event with an existing supplied ID replaces that event’s current values.
string
required
UUID of the Braintrust dataset that will receive the examples.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: BRAINTRUST_INSERT_EXPERIMENT_EVENTSUpsert a batch of result events into an existing Braintrust experiment. New or omitted IDs insert events; an existing supplied ID replaces that event’s current values.

Input Parameters

array
required
Experiment result events to upsert. Row IDs in the response align with this list in the same order. An event with an existing supplied ID replaces that event’s current values.
string
required
UUID of the Braintrust experiment that will receive the events.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: BRAINTRUST_LIST_RESOURCESList and filter one page of projects, experiments, datasets, prompts, or functions visible to the connected Braintrust API key.

Input Parameters

array
Restrict results to these resource UUIDs.
string
Exact resource name to match for the selected resource type.
string
Restrict prompts or functions to this slug.
integer
Maximum number of objects to request in this page.
string
Restrict prompts or functions to this version identifier.
string
Optional organization-name filter. It does not switch the API key’s active data-plane organization.
string
Restrict experiments, datasets, prompts, or functions to this project UUID.
string
Restrict prompts or functions to this environment slug.
string
Opaque continuation token returned by a previous call. Omit for the first page and pass it back unchanged to continue.
string
Restrict experiments, datasets, prompts, or functions to this project name.
string ("project" | "experiment" | "dataset" | "prompt" | "function")
required
Kind of Braintrust resource to list.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: BRAINTRUST_QUERY_DATARun one bounded synchronous read-only BTQL query over Braintrust project logs, an experiment, or a dataset. The first-page query must end with a positive LIMIT; continue later pages by passing the returned next_cursor unchanged.

Input Parameters

string
Read-only BTQL SELECT query. It must query project_logs(…), experiment(…), or dataset(…) and end with an explicit positive LIMIT. Required on the first page; omit it when passing next_cursor.
string
Optional historical data version for a reproducible query.
string ("default" | "strict")
Braintrust query linting mode.
number
Optional timezone offset in minutes using JavaScript’s Date.getTimezoneOffset convention: positive values are behind UTC. For example, 480 is US Pacific Standard Time (UTC-08:00).
string
Opaque continuation token returned by a previous QUERY_DATA call. Pass it back unchanged; the original query and options are carried authoritatively.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: BRAINTRUST_SUMMARIZE_RESOURCEReturn metadata and optional aggregate summaries for one Braintrust experiment or dataset.

Input Parameters

string
required
Experiment or dataset UUID matching resource_type.
string ("experiment" | "dataset")
required
Resource summary to calculate.
boolean
For experiments, summarize scores and metrics; for datasets, summarize data. Set false to return metadata only.
string
Optional baseline experiment UUID. Valid only when resource_type is experiment and include_aggregates is true. When omitted, Braintrust may select the configured baseline or a recent experiment.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: BRAINTRUST_UPDATE_DATASETUpdate the name, description, tags, or metadata of a Braintrust dataset. At least one non-null mutable field is required.

Input Parameters

string
New dataset name.
array
Complete replacement list of dataset tags.
object
Metadata fields to deep-merge into the dataset’s existing metadata.
string
required
UUID of the dataset to update.
string
New dataset description.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: BRAINTRUST_UPDATE_EXPERIMENTUpdate selected metadata and linkage fields on a Braintrust experiment. At least one non-null mutable field is required.

Input Parameters

string
New experiment name.
array
Complete replacement list of experiment tags.
boolean
Whether the experiment is publicly viewable.
object
User-controlled metadata fields to deep-merge into existing metadata.
string
UUID of the dataset to link to the experiment.
string
New experiment description.
string
required
UUID of the experiment to update.
string
Version of the linked dataset used by the experiment.
string
UUID of the default baseline experiment used for comparisons.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: BRAINTRUST_UPDATE_PROJECTUpdate selected fields of a Braintrust project. At least one non-null mutable field is required: name, description, or settings.

Input Parameters

string
New project name.
object
Complete replacement project settings. Include every existing setting that must be retained.
string
required
UUID of the project to update.
string
New project description.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not
Slug: BRAINTRUST_UPDATE_PROMPTUpdate a Braintrust prompt’s metadata or configuration without invoking it. At least one non-null mutable field is required.

Input Parameters

string
New prompt name.
string
New unique prompt slug.
array
Complete replacement list of prompt tags.
string
required
UUID of the prompt to update.
string
New prompt description.
object
Prompt block, model options, or parser fields to deep-merge. MCP attachments and tool_functions are unsupported and rejected.
string ("mustache" | "nunjucks" | "none")
Replacement template syntax, stored inside the provider’s prompt_data object.

Output

string
required
Data from the action execution
string
Error if any occurred during the execution of the action
boolean
required
Whether or not the action execution was successful or not