Get canvases
post
/api/20210901/catalog/workbooks/{id}/actions/getCanvases
Get a list of canvases for workbook with a given ID.
Request
Path Parameters
-
id(required): string
Catalog item ID in base64url format.
Supported Media Types
- */*
Root Schema : schema
Type:
string
Allowed Values:
[
""
]
Response
Supported Media Types
- application/json
200 Response
Successful operation
Nested Schema : WorkbookCanvas
Type:
Show Source
object
-
canvasId: string
Canvas ID.
-
canvasName: string
Canvas name.
Nested Schema : WorkbookPresentCanvas-allOf[1]
Type:
Show Source
object
-
isEnabled: string
Indicates whether this canvas is enabled.
-
visualizeCanvasId: string
Visualize canvas ID.
400 Response
Bad Request (invalid query parameters, malformed headers, and so on).
Root Schema : Error
Type:
Show Source
object
-
code(required): string
Short error code that defines the error, meant for programmatic parsing.
-
message(required): string
Human-readable error string.
401 Response
Unauthorized (missing or expired credentials, and so on).
Root Schema : Error
Type:
Show Source
object
-
code(required): string
Short error code that defines the error, meant for programmatic parsing.
-
message(required): string
Human-readable error string.
403 Response
Forbidden (missing permissions for operation, request denied for unspecified reason, and so on).
Root Schema : Error
Type:
Show Source
object
-
code(required): string
Short error code that defines the error, meant for programmatic parsing.
-
message(required): string
Human-readable error string.
404 Response
Not Found. The requested resource was not found.
Root Schema : Error
Type:
Show Source
object
-
code(required): string
Short error code that defines the error, meant for programmatic parsing.
-
message(required): string
Human-readable error string.
500 Response
Internal Server Error. The server encountered an unexpected condition
preventing fulfilment of the request.
Root Schema : Error
Type:
Show Source
object
-
code(required): string
Short error code that defines the error, meant for programmatic parsing.
-
message(required): string
Human-readable error string.
Examples
In this example, you return the details of all canvases belonging to the
specified workbook ID. The object ID of the workbook is '/shared/Sales/Sales
Analysis' which has the Base64URL-safe encoded ID value:
L3NoYXJlZC9TYWxlcy9TYWxlcyBBbmFseXNpcw
. You can get the ID of a
workbook by using Get catalog items by type.
cURL Example:
curl --header 'Authorization: Bearer <token>' \ --request POST 'https://<hostname>/api/20210901/catalog/workbooks/L3NoYXJlZC9TYWxlcy9TYWxlcyBBbmFseXNpcw/actions/getCanvases'
Example of Request Body
Not applicable.
Example of Response Body
{ "visualizeCanvases": [ { "canvasId": 1, "canvasName": "Sales by Product Category" } ], "presentCanvases": [ { "canvasId": "snapshot!canvas!1", "visualizeCanvasId": 1, "isEnabled": true, "canvasName": "Sales by Product Category" } ] }