OpenObserve Docs
ReferenceApi

Dashboards API

OpenObserve exposes panel-level APIs for performing granular create, update, and delete operations on dashboard panels. These endpoints let you modify a single panel without sending the entire dashboard payload.

All requests must include an authorization header. See the API Index for details on building the header.

Version support

Panel operations are supported only for v8 dashboards. Calling these endpoints against a dashboard of any other version returns 400 Bad Request with the message Panel operations are only supported for v8 dashboards.

Optimistic concurrency

The hash query parameter is mandatory on all three endpoints. It carries the current dashboard hash and is used for optimistic-concurrency conflict detection. If the dashboard has changed since the hash was issued, the request fails with 409 Conflict. Each successful response returns a new hash value that you can use for the next chained operation.

The full dashboard resource (create, get, update, delete, list, move) is also documented in the bundled OpenAPI/Swagger specification, available from the OpenObserve UI.

Add Panel

Adds a new panel to an existing dashboard. If the panel layout is omitted (or supplied as all-zero coordinates), the layout is auto-computed and the panel is placed to the right of the last panel when there is room, or below all existing panels otherwise. A panel ID is generated automatically when none is provided.

Endpoint

POST /api/{org_id}/dashboards/{dashboard_id}/panels

Path Parameters

NameTypeDescription
org_idstringOrganization name
dashboard_idstringDashboard ID

Query Parameters

NameTypeRequiredDescription
hashstringYesCurrent dashboard hash, used for optimistic-concurrency conflict detection.
folderstringNoFolder ID where the dashboard is located. Defaults to the default folder.

Request Body

FieldTypeDescription
panelobjectThe panel definition to add. Uses the v8 Panel schema. layout is optional (auto-computed).
tabIdstringOptional tab ID to add the panel to. Defaults to the first tab if omitted.
{
  "panel": {
    "id": "",
    "type": "bar",
    "title": "Requests per minute",
    "description": "",
    "queryType": "sql",
    "queries": [
      {
        "query": "SELECT histogram(_timestamp) AS x, count(*) AS y FROM default GROUP BY x",
        "customQuery": false,
        "fields": {
          "stream": "default",
          "stream_type": "logs",
          "x": [],
          "y": [],
          "filter": { "filterType": "group", "logicalOperator": "AND", "conditions": [] }
        },
        "config": {}
      }
    ],
    "config": {}
  },
  "tabId": "default"
}

Response

Returns the stored panel (including the resolved/auto-computed layout), the new dashboard hash, and the resolved tab ID.

{
  "panel": {
    "id": "7148506321657856",
    "type": "bar",
    "title": "Requests per minute",
    "description": "",
    "queryType": "sql",
    "queries": [ ... ],
    "config": {},
    "layout": { "x": 0, "y": 0, "w": 96, "h": 18, "i": 1 }
  },
  "hash": "13845632198765432100",
  "tabId": "default"
}
StatusDescription
200Panel added.
400Unsupported dashboard version, or hash missing.
404Dashboard or tab not found.
409Panel ID already exists, or hash conflict.

Update Panel

Updates a single panel in a dashboard, identified by its panel ID. The panel ID in the URL path is authoritative. If the request body omits layout, the existing layout of the panel is preserved.

Endpoint

PUT /api/{org_id}/dashboards/{dashboard_id}/panels/{panel_id}

Path Parameters

NameTypeDescription
org_idstringOrganization name
dashboard_idstringDashboard ID
panel_idstringID of the panel to update

Query Parameters

NameTypeRequiredDescription
hashstringYesCurrent dashboard hash, used for optimistic-concurrency conflict detection.
folderstringNoFolder ID where the dashboard is located. Defaults to the default folder.

Request Body

FieldTypeDescription
panelobjectThe updated panel definition. Uses the v8 Panel schema. Omit layout to preserve the existing layout.
tabIdstringOptional tab ID containing the panel. Defaults to the first tab if omitted.
{
  "panel": {
    "type": "line",
    "title": "Requests per minute (updated)",
    "description": "",
    "queryType": "sql",
    "queries": [
      {
        "query": "SELECT histogram(_timestamp) AS x, count(*) AS y FROM default GROUP BY x",
        "customQuery": false,
        "fields": {
          "stream": "default",
          "stream_type": "logs",
          "x": [],
          "y": [],
          "filter": { "filterType": "group", "logicalOperator": "AND", "conditions": [] }
        },
        "config": {}
      }
    ],
    "config": {}
  },
  "tabId": "default"
}

Response

Returns the updated panel, the new dashboard hash, and the resolved tab ID.

{
  "panel": {
    "id": "7148506321657856",
    "type": "line",
    "title": "Requests per minute (updated)",
    "description": "",
    "queryType": "sql",
    "queries": [ ... ],
    "config": {},
    "layout": { "x": 0, "y": 0, "w": 96, "h": 18, "i": 1 }
  },
  "hash": "98712345600112233445",
  "tabId": "default"
}
StatusDescription
200Panel updated.
400Unsupported dashboard version, or hash missing.
404Dashboard, tab, or panel not found.
409Hash conflict.

Delete Panel

Deletes a single panel from a dashboard, identified by its panel ID. If tabId is supplied, only that tab is searched; otherwise all tabs are searched until the panel is found.

Endpoint

DELETE /api/{org_id}/dashboards/{dashboard_id}/panels/{panel_id}

Path Parameters

NameTypeDescription
org_idstringOrganization name
dashboard_idstringDashboard ID
panel_idstringID of the panel to delete

Query Parameters

NameTypeRequiredDescription
hashstringYesCurrent dashboard hash, used for optimistic-concurrency conflict detection.
tabIdstringNoTab ID to search for the panel. If omitted, all tabs are searched.
folderstringNoFolder ID where the dashboard is located. Defaults to the default folder.

Response

Returns the new dashboard hash and the ID of the deleted panel.

{
  "hash": "44556677889900112233",
  "panelId": "7148506321657856"
}
StatusDescription
200Panel deleted.
400Unsupported dashboard version, or hash missing.
404Dashboard, tab, or panel not found.
409Hash conflict.

Next steps

Need some help?

Was this page helpful?

Last updated on

On this page