Skip to main content
POST
/
dashboards
/
dashboards
/
{id}
/
bulk_widgets
cURL
curl --request POST \
  --url https://api.cekura.ai/dashboards/dashboards/{id}/bulk_widgets/ \
  --header 'Content-Type: application/json' \
  --header 'X-CEKURA-API-KEY: <api-key>' \
  --data '
{
  "create": [
    {}
  ],
  "update": [
    {}
  ],
  "delete": [
    123
  ]
}
'
{
  "created": [
    {
      "chart_type": "line",
      "id": 123,
      "dashboard": 123,
      "name": "<string>",
      "filters": {
        "field": "<string>",
        "op": "eq",
        "value": "<unknown>",
        "operator": "and",
        "conditions": [
          "<unknown>"
        ]
      },
      "effective_filters": {
        "field": "<string>",
        "op": "eq",
        "value": "<unknown>",
        "operator": "and",
        "conditions": [
          "<unknown>"
        ]
      },
      "data_type": "numeric",
      "field": "",
      "metric": 123,
      "metric_name": "<string>",
      "time_period": "hour",
      "aggregation_function": "count",
      "group_by": "<unknown>",
      "metadata": "<unknown>",
      "created_at": "2023-11-07T05:31:56Z",
      "updated_at": "2023-11-07T05:31:56Z"
    }
  ],
  "updated": [
    {
      "chart_type": "line",
      "id": 123,
      "dashboard": 123,
      "name": "<string>",
      "filters": {
        "field": "<string>",
        "op": "eq",
        "value": "<unknown>",
        "operator": "and",
        "conditions": [
          "<unknown>"
        ]
      },
      "effective_filters": {
        "field": "<string>",
        "op": "eq",
        "value": "<unknown>",
        "operator": "and",
        "conditions": [
          "<unknown>"
        ]
      },
      "data_type": "numeric",
      "field": "",
      "metric": 123,
      "metric_name": "<string>",
      "time_period": "hour",
      "aggregation_function": "count",
      "group_by": "<unknown>",
      "metadata": "<unknown>",
      "created_at": "2023-11-07T05:31:56Z",
      "updated_at": "2023-11-07T05:31:56Z"
    }
  ],
  "deleted": [
    123
  ],
  "errors": [
    {}
  ]
}

Documentation Index

Fetch the complete documentation index at: https://docs.cekura.ai/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

X-CEKURA-API-KEY
string
header
required

API Key Authentication. It should be included in the header of each request.

Path Parameters

id
string
required

Body

Serializer for bulk widget operations request.

Accepts separate lists for create, update, and delete operations. All operations are performed in a single transaction. Dashboard is provided via query parameter (dashboard_id).

Example request: { "create": [{"name": "New Widget", "field": "duration", "chart_type": "line"}, ...], "update": [{"id": 1, "name": "Updated Name", "filters": {}}, ...], "delete": [2, 3, 4] }

create
object[]

List of widget data objects to create

update
object[]

List of widget objects with 'id' field for updates

delete
integer[]

List of widget IDs to delete

Response

200 - application/json

Response serializer for bulk widget operations.

Returns the created, updated, and deleted widgets.

created
object[]
required

List of created widgets

updated
object[]
required

List of updated widgets

deleted
integer[]
required

List of deleted widget IDs

errors
object[]

List of errors that occurred during operations