curl --request PATCH \
--url https://api.honeycomb.io/1/dataset_definitions/{datasetSlug} \
--header 'Content-Type: application/json' \
--header 'X-Honeycomb-Team: <api-key>' \
--data '
{
"duration_ms": {
"name": "duration_we_send",
"column_type": "derived_column"
}
}
'{
"duration_ms": {
"name": "duration_ms",
"column_type": "column"
},
"error": null,
"name": null,
"parent_id": null,
"route": null,
"service_name": null,
"span_id": {
"name": "my_span_id",
"column_type": "column"
},
"span_kind": null,
"annotation_type": null,
"link_trace_id": null,
"link_span_id": null,
"status": null,
"trace_id": null,
"user": null,
"log_severity": null,
"log_message": null
}{
"status": 400,
"type": "https://api.honeycomb.io/problems/unparseable",
"title": "The request body could not be parsed.",
"detail": "could not parse request body",
"error": "could not parse request body"
}{
"error": "unknown API key - check your credentials"
}{
"error": "dataset not found"
}{
"error": "The following columns were not found: duration_we_send"
}Set or Update Dataset Definitions
Set or update one or more definitions for a Dataset.
Note: While the PATCH payload can include the column_type, Honeycomb does not use this field when updating Dataset Definitions.
curl --request PATCH \
--url https://api.honeycomb.io/1/dataset_definitions/{datasetSlug} \
--header 'Content-Type: application/json' \
--header 'X-Honeycomb-Team: <api-key>' \
--data '
{
"duration_ms": {
"name": "duration_we_send",
"column_type": "derived_column"
}
}
'{
"duration_ms": {
"name": "duration_ms",
"column_type": "column"
},
"error": null,
"name": null,
"parent_id": null,
"route": null,
"service_name": null,
"span_id": {
"name": "my_span_id",
"column_type": "column"
},
"span_kind": null,
"annotation_type": null,
"link_trace_id": null,
"link_span_id": null,
"status": null,
"trace_id": null,
"user": null,
"log_severity": null,
"log_message": null
}{
"status": 400,
"type": "https://api.honeycomb.io/problems/unparseable",
"title": "The request body could not be parsed.",
"detail": "could not parse request body",
"error": "could not parse request body"
}{
"error": "unknown API key - check your credentials"
}{
"error": "dataset not found"
}{
"error": "The following columns were not found: duration_we_send"
}Authorizations
Authenticate using a Honeycomb Configuration Key.
Pass the Token in the X-Honeycomb-Team header:
X-Honeycomb-Team: 1234567890123456789012
If you created your key using the API, use data.attributes.secret; this is the same value as the Token in the UI.
To learn how to create a Configuration Key, visit Manage Environment API Keys. To learn more about authenticating requests, visit API Authentication.
Body
The PATCH payload takes a map of Dataset definition type to Dataset definition. Fields not defined in the request are not modified on the server. Note: In order to CLEAR a column of a Dataset definition set the column’s name field to an empty string.
Dataset Definitions describe the fields with special meaning in the Dataset.
Response
Dataset Definitions have been updated
Dataset Definitions describe the fields with special meaning in the Dataset.