Docs
DocumentationQuery ReferenceAPI Reference
Open Console→→
DocumentationQuery ReferenceAPI Reference

Get started

IntroductionSend dataQuery dataPaginationAPI limits

Annotations

List all annotationsGETRetrieve annotationGETCreate annotationPOSTUpdate annotationPUTDelete annotationDELETE

API tokens

List all API tokensGETRetrieve API tokenGETCreate API tokenPOSTRegenerate API tokenPOSTDelete API tokenDELETE

Dashboards

Dashboard JSONList all dashboardsGETRetrieve dashboardGETCreate dashboardPOSTUpdate dashboardPUTPatch dashboard elementPATCHDelete dashboardDELETE

Datasets

List all datasetsGETRetrieve datasetGETList all fields in datasetGETRetrieve field in datasetGETCreate datasetPOSTIngest data (legacy)POSTRun APL query (legacy)POSTRun query (legacy)POSTTrim datasetPOSTUpdate datasetPUTUpdate fieldPUTVacuum datasetPOSTDelete fieldsPOSTDelete fieldDELETEDelete datasetDELETE

Edge

Ingest data to edge deploymentIngest Splunk HEC eventsIngest raw Splunk HEC eventsCheck Splunk HEC healthRun APL query to edge deploymentRun batch query to edge deploymentRun MPL query to edge deploymentGet metrics for a datasetFind metrics by tag valueGet metric tags for a datasetGet metric tag values for a datasetGet tags for a datasetGet tag values for a dataset

Labels

List all labelsGETRetrieve labelGETCreate labelPOSTUpdate labelPUTDelete labelDELETEList label assignmentsPOSTReplace label assignmentsPUT

Map fields

List all map fieldsGETCreate map fieldPOSTUpdate list of map fieldsPUTDelete map fieldsDELETE

Monitors

List all monitorsGETRetrieve monitorGETRetrieve monitor historyGETCreate monitorPOSTUpdate monitorPUTDelete monitorDELETE

Notifiers

List all notifiersGETRetrieve notifierGETCreate notifierPOSTUpdate notifierPUTDelete notifierDELETE

Organizations

List all orgsGETRetrieve orgGETCreate orgPOSTUpdate orgPUTProvision orgPOST

Role-based access control

List all rolesGETRetrieve roleGETList all groupsGETRetrieve groupGETCreate rolePOSTCreate groupPOSTUpdate rolePUTUpdate groupPUTDelete roleDELETEDelete groupDELETE

Saved queries

List all saved queriesGETRetrieve saved queryGETCreate saved queryPOSTUpdate saved queryPUTDelete saved queryDELETE

Users

Retrieve current userGETList all usersGETRetrieve userGETCreate userPOSTUpdate current userPUTUpdate user rolePUTDelete user from orgDELETE

Views

List all viewsGETRetrieve viewGETCreate viewPOSTUpdate viewPUTDelete viewDELETE

Virtual fields

List all virtual fieldsGETRetrieve virtual fieldGETCreate virtual fieldPOSTUpdate virtual fieldPUTDelete virtual fieldDELETE
Datasets

Create dataset

POST/v2/datasets

Creates a dataset. The name must be unique in your organization, and retentionDays can't exceed the retention window of your plan. labelIds replaces assignments when supplied; [] clears them. Omitted or null labelIds preserves assignments on updates and creates an unlabeled resource on creation. IDs must belong to existing labels in your organization and are validated before saving.

Parameters

PropertyTypeLocationDescription
referrerstringqueryReferrer slug

Body

application/json
PropertyTypeDescription
descriptionstringDataset description
edgeDeploymentstringEdge deployment of the dataset
kindstringThe kind of the dataset
labelIdsstring[]Existing label IDs; replaces assignments when supplied, clears with [], and preserves them when omitted or null.
namestringRequiredDataset unique name
retentionDaysintegerNumber of days to retain data in the dataset
useRetentionPeriodbooleanIgnored. Axiom derives this value from retentionDays.

Request

curl -X POST 'https://api.axiom.co/v2/datasets' \
  -H 'Authorization: Bearer API_TOKEN' \
  -H 'Content-Type: application/json' \
  -d '{"description":"string","kind":"axiom:events:v1","name":"string","retentionDays":30}'
Try itRun this request against your Axiom organization

Credentials stay in this browser tab and are only sent to Axiom when you run the request.

Response

200Created dataset.
application/json
400Invalid or reserved `name`, invalid `kind`, `retentionDays` longer than your plan allows, unsupported `edgeDeployment`, or dataset limit reached.
application/json
403Forbidden
409A dataset with this name already exists.
application/json
PropertyTypeDescription
canWritebooleanWhether this dataset has write access
createdstring<date-time>RequiredThe RFC3339-formatted time when the dataset was created.
createdByAgentbooleantrue when the MCP server created this dataset
descriptionstringRequiredDataset description
edgeDeploymentstringEdge deployment of the dataset
edgeDeploymentUrlstringURL of the edge deployment
idstringRequiredDataset ID
kindstringRequiredThe kind of the dataset
labelIdsstring[]RequiredIDs of labels assigned to this dataset.
labelNamesstring[]RequiredNames of assigned labels, including with exclude=labels; [] when unassigned.
labelsobject[]Resolved labels assigned to this dataset.
└colorobjectRequired—
└namestringRequired—
└typestringRequired—
└descriptionstring—
└idstringRequired—
└namestringRequired—
mapFieldsstring[]—
namestringRequiredUnique dataset name
reclaimableFieldsinteger<int64>Number of unused fields a vacuum can reclaim, when the dataset is a vacuum candidate
retentionDaysintegerNumber of days to retain data in the dataset
sharedByOrgstringID of the org that shared this resource, if it's shared
updatedAtstring<date-time>RequiredThe RFC3339-formatted time when the dataset was last updated.
useRetentionPeriodbooleanWhether to use the retention period
vacuumCandidatebooleanWhether the dataset has unused fields that a vacuum can reclaim
whostringRequiredName of the dataset creator
Was this page helpful?
Suggest edits on GitHub
PreviousRetrieve field in datasetNextIngest data (legacy)
On this page
ParametersBodyRequestResponse