Braintest
POST/v1/dataset/{dataset_id}/insert

Insert events into a dataset

Inserts a set of events into the specified dataset. Provide the dataset UUID and an events array containing the rows to add, including event inputs, expected outputs, and optional tracing or merge information. Use _is_merge, _merge_paths, or _object_delete when you need to control how an event is combined with or removed from an existing row.

  • IdempotentThe SDK sends Idempotency-Key, so a retried request is only applied once.

1 parameter · 1 body field
dataset_idstringrequired
The unique identifier of the dataset that receives the events, in UUID format.

A payload containing the dataset events to insert.

eventsarray<object>required
A list of dataset events to insert

6 status codes
200Returns an object containing `row_ids`, an array of identifiers aligned one-to-one with the inserted events.
row_idsarray<string>required
The ids of all rows that were inserted, aligning one-to-one with the rows provided as input
400Returned when the request is unacceptable, including when the required `events` field is missing.
401Returned when no valid API key is provided.
403Returned when the API key does not have permission to insert events into the dataset.
429Returned when too many requests arrive too quickly; use exponential backoff before retrying.
500Returned when an internal service error occurs.

Error handling

dataset_id must be a valid UUID, and the request body must include the events array. A 400 is returned when the request is unacceptable or events is missing, a 401 when no valid API key is provided, and a 403 when the API key lacks permission. A 429 indicates excessive request frequency, while a 500 indicates an internal service failure.