v1

latestSwagger 2.02026-07-17290378721.8 KB
correlations

Add correlation.

post/datasources/uid/{sourceUID}/correlations

Path parameters

sourceUIDstring required

Request body

descriptionstring

Optional description of the correlation

labelstring

Optional label identifying the correlation

targetUIDstring

Target data source UID to which the correlation is created. required if config.type = query

Example request

{
  "config": {
    "field": "message",
    "target": {
      "expr": "job=app"
    }
  },
  "description": "Logs to Traces",
  "label": "My label",
  "targetUID": "PE1C5CBDA0504A6A3"
}

Response

(empty)

messagestring

Example response

{
  "message": "Correlation created",
  "result": {
    "config": {
      "field": "message",
      "target": {
        "expr": "job=app"
      }
    },
    "description": "Logs to Traces",
    "label": "My Label",
    "sourceUID": "d0oxYRg4z",
    "targetUID": "PE1C5CBDA0504A6A3",
    "uid": "50xhMlg9k"
  }
}