Public API v2 → Dashboard Prompts Endpoint

About the /dashboards/{dashboardGuid}/prompts endpoint

The /dashboards/{dashboardGuid}/prompts endpoint will return a list of all prompts and presentation variables in a requested dashboard. If the dashboard does not contain prompts or presentation variables, the endpoint will return a list of the dashboard’s dimension values. This endpoint is accessed with a GET request.

For information about how to get started with Public API v2, refer to References → Public API v2.

Note

Use the HTTPS or HTTP scheme according to your installation. You must use the HTTPS scheme to successfully run the API endpoints on Cloud installations. Additionally, you must specify the tenant name (case-sensitive) in the endpoint request URL.

Header requirements

In the request header you will need to include your access token with a type of Bearer.

For information about how to create an access token, refer to Public API v2 → Create an API access token.

Following is an example of the authorization line required in the request header:

"Authorization": "Bearer ABC123456789"

Request URL

Following is the URL to call the /dashboards/{dashboardGuid}/prompts endpoint.

https://<cluster_URL>/incorta/api/v2/{tenantName}/dashboards/{dashboardGuid}/prompts

The dashboardGuid is located in the URL of the desired dashboard. It is required in the /dashboards/{dashboardGuid}/prompts endpoint URL. The following are instructions on where to locate the dashboardGuid:

  • As the user that wants to access the public API of a dashboard, sign into the Incorta Direct Data Platform™.
  • In the navigation bar, select Content.
  • Select the desired dashboard.
  • In your browser URL, locate the dashboardGuid in the URL.

Following is an example of where to locate the dashboardGuid in a dashboard URL:

https://<cluster_URL>/incorta/#/dashboard/<dashboardGuid>

Endpoint request

The /dashboards/{dashboardGuid}/prompts endpoint does not require any request payload. The required information for the endpoint, the access token and dasboardGuid is located in the header and URL path.

Endpoint response

The /dashboards/{dashboardGuid}/prompts endpoint has three possible response codes and payloads.

CodeDescriptionPayload Response
200OKSee Endpoint 200 Response
401Unauthorized
  ●  Invalid or expired access token.
  ●  The tenant name doesn’t match the tenant in the access token.
{"message": "string"}
Example:
"INC_09030108: Invalid authentication header. Invalid Token [abc123]"
404Not Found
  ●  The dashboard does not exist.
  ●  The tenant doesn't exist or is disabled.
{"message": "string"}
Examples:
"Invalid [Demo] tenant in resource path"
"INC_09040201: Dashboard not found."
500Internal Server Error{"message": "string"}

Endpoint 200 response

{
"prompts": [
{
"dataType": "string",
"field": "string",
"function": "string",
"label": "string",
"operator": "string",
"defaultValues": [
"string"
],
"values": [
"string"
],
"variable": "string"
}
]
}