Open Context Protocol is live! 🚀 Read the launch post
getAllDashboards

getAllDashboards

Get all dashboards

Details

  • Method: GET
  • Path: /rest/api/3/dashboard
  • Operation ID: getAllDashboards

Parameters

{
  "filter": {
    "description": "The filter applied to the list of dashboards. Valid values are:\n\n *  `favourite` Returns dashboards the user has marked as favorite.\n *  `my` Returns dashboards owned by the user.",
    "required": false,
    "location": "query",
    "type": "string",
    "enum": [
      "my",
      "favourite"
    ]
  },
  "startAt": {
    "description": "The index of the first item to return in a page of results (page offset).",
    "required": false,
    "location": "query",
    "type": "integer",
    "format": "int32"
  },
  "maxResults": {
    "description": "The maximum number of items to return per page.",
    "required": false,
    "location": "query",
    "type": "integer",
    "format": "int32"
  }
}

Response Schema

{
  "additionalProperties": false,
  "description": "A page containing dashboard details.",
  "properties": {
    "dashboards": {
      "description": "List of dashboards.",
      "items": {
        "additionalProperties": false,
        "description": "Details of a dashboard.",
        "properties": {
          "automaticRefreshMs": {
            "description": "The automatic refresh interval for the dashboard in milliseconds.",
            "format": "int32",
            "readOnly": true,
            "type": "integer"
          },
          "description": {
            "type": "string"
          },
          "editPermissions": {
            "description": "The details of any edit share permissions for the dashboard.",
            "items": {
              "additionalProperties": false,
              "description": "Details of a share permission for the filter.",
              "properties": {
                "group": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/GroupName"
                    }
                  ],
                  "description": "The group that the filter is shared with. For a request, specify the `groupId` or `name` property for the group. As a group's name can change, use of `groupId` is recommended."
                },
                "id": {
                  "description": "The unique identifier of the share permission.",
                  "format": "int64",
                  "readOnly": true,
                  "type": "integer"
                },
                "project": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/Project"
                    }
                  ],
                  "description": "The project that the filter is shared with. This is similar to the project object returned by [Get project](#api-rest-api-3-project-projectIdOrKey-get) but it contains a subset of the properties, which are: `self`, `id`, `key`, `assigneeType`, `name`, `roles`, `avatarUrls`, `projectType`, `simplified`.  \nFor a request, specify the `id` for the project."
                },
                "role": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ProjectRole"
                    }
                  ],
                  "description": "The project role that the filter is shared with.  \nFor a request, specify the `id` for the role. You must also specify the `project` object and `id` for the project that the role is in."
                },
                "type": {
                  "description": "The type of share permission:\n\n *  `user` Shared with a user.\n *  `group` Shared with a group. If set in a request, then specify `sharePermission.group` as well.\n *  `project` Shared with a project. If set in a request, then specify `sharePermission.project` as well.\n *  `projectRole` Share with a project role in a project. This value is not returned in responses. It is used in requests, where it needs to be specify with `projectId` and `projectRoleId`.\n *  `global` Shared globally. If set in a request, no other `sharePermission` properties need to be specified.\n *  `loggedin` Shared with all logged-in users. Note: This value is set in a request by specifying `authenticated` as the `type`.\n *  `project-unknown` Shared with a project that the user does not have access to. Cannot be set in a request.",
                  "enum": [
                    "user",
                    "group",
                    "project",
                    "projectRole",
                    "global",
                    "loggedin",
                    "authenticated",
                    "project-unknown"
                  ],
                  "type": "string"
                },
                "user": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/UserBean"
                    }
                  ],
                  "description": "The user account ID that the filter is shared with. For a request, specify the `accountId` property for the user."
                }
              },
              "required": [
                "type"
              ],
              "type": "object"
            },
            "readOnly": true,
            "type": "array"
          },
          "id": {
            "description": "The ID of the dashboard.",
            "readOnly": true,
            "type": "string"
          },
          "isFavourite": {
            "description": "Whether the dashboard is selected as a favorite by the user.",
            "readOnly": true,
            "type": "boolean"
          },
          "isWritable": {
            "description": "Whether the current user has permission to edit the dashboard.",
            "readOnly": true,
            "type": "boolean"
          },
          "name": {
            "description": "The name of the dashboard.",
            "readOnly": true,
            "type": "string"
          },
          "owner": {
            "allOf": [
              {
                "$ref": "#/components/schemas/UserBean"
              }
            ],
            "description": "The owner of the dashboard.",
            "readOnly": true
          },
          "popularity": {
            "description": "The number of users who have this dashboard as a favorite.",
            "format": "int64",
            "readOnly": true,
            "type": "integer"
          },
          "rank": {
            "description": "The rank of this dashboard.",
            "format": "int32",
            "readOnly": true,
            "type": "integer"
          },
          "self": {
            "description": "The URL of these dashboard details.",
            "format": "uri",
            "readOnly": true,
            "type": "string"
          },
          "sharePermissions": {
            "description": "The details of any view share permissions for the dashboard.",
            "items": {
              "additionalProperties": false,
              "description": "Details of a share permission for the filter.",
              "properties": {
                "group": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/GroupName"
                    }
                  ],
                  "description": "The group that the filter is shared with. For a request, specify the `groupId` or `name` property for the group. As a group's name can change, use of `groupId` is recommended."
                },
                "id": {
                  "description": "The unique identifier of the share permission.",
                  "format": "int64",
                  "readOnly": true,
                  "type": "integer"
                },
                "project": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/Project"
                    }
                  ],
                  "description": "The project that the filter is shared with. This is similar to the project object returned by [Get project](#api-rest-api-3-project-projectIdOrKey-get) but it contains a subset of the properties, which are: `self`, `id`, `key`, `assigneeType`, `name`, `roles`, `avatarUrls`, `projectType`, `simplified`.  \nFor a request, specify the `id` for the project."
                },
                "role": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ProjectRole"
                    }
                  ],
                  "description": "The project role that the filter is shared with.  \nFor a request, specify the `id` for the role. You must also specify the `project` object and `id` for the project that the role is in."
                },
                "type": {
                  "description": "The type of share permission:\n\n *  `user` Shared with a user.\n *  `group` Shared with a group. If set in a request, then specify `sharePermission.group` as well.\n *  `project` Shared with a project. If set in a request, then specify `sharePermission.project` as well.\n *  `projectRole` Share with a project role in a project. This value is not returned in responses. It is used in requests, where it needs to be specify with `projectId` and `projectRoleId`.\n *  `global` Shared globally. If set in a request, no other `sharePermission` properties need to be specified.\n *  `loggedin` Shared with all logged-in users. Note: This value is set in a request by specifying `authenticated` as the `type`.\n *  `project-unknown` Shared with a project that the user does not have access to. Cannot be set in a request.",
                  "enum": [
                    "user",
                    "group",
                    "project",
                    "projectRole",
                    "global",
                    "loggedin",
                    "authenticated",
                    "project-unknown"
                  ],
                  "type": "string"
                },
                "user": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/UserBean"
                    }
                  ],
                  "description": "The user account ID that the filter is shared with. For a request, specify the `accountId` property for the user."
                }
              },
              "required": [
                "type"
              ],
              "type": "object"
            },
            "readOnly": true,
            "type": "array"
          },
          "systemDashboard": {
            "description": "Whether the current dashboard is system dashboard.",
            "readOnly": true,
            "type": "boolean"
          },
          "view": {
            "description": "The URL of the dashboard.",
            "readOnly": true,
            "type": "string"
          }
        },
        "type": "object"
      },
      "readOnly": true,
      "type": "array"
    },
    "maxResults": {
      "description": "The maximum number of results that could be on the page.",
      "format": "int32",
      "readOnly": true,
      "type": "integer"
    },
    "next": {
      "description": "The URL of the next page of results, if any.",
      "readOnly": true,
      "type": "string"
    },
    "prev": {
      "description": "The URL of the previous page of results, if any.",
      "readOnly": true,
      "type": "string"
    },
    "startAt": {
      "description": "The index of the first item returned on the page.",
      "format": "int32",
      "readOnly": true,
      "type": "integer"
    },
    "total": {
      "description": "The number of results on the page.",
      "format": "int32",
      "readOnly": true,
      "type": "integer"
    }
  },
  "type": "object"
}

Usage

from ocp_agent import OCPAgent

agent = OCPAgent()
await agent.register_api('jira')

# Call this tool
result = await agent.call_tool('getAllDashboards', {
    # Add required parameters here
})