Skip to main content

workbooks

Creates, updates, deletes, gets or lists a workbooks resource.

Overview

Nameworkbooks
TypeResource
Idazure.application_insights.workbooks

Fields

The following fields are returned by SELECT queries:

A workbook definition.

NameDatatypeDescription
etagstringResource etag
identityobjectManaged service identity (system assigned and/or user assigned identities)
kindstringThe kind of workbook. Only valid value is shared.
propertiesobjectMetadata describing a workbook for an Azure resource.
systemDataobjectMetadata pertaining to creation and last modification of the resource.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectsubscriptionId, resourceGroupName, resourceNamecanFetchContentGet a single workbook by its resourceName.
list_by_resource_groupselectsubscriptionId, resourceGroupName, categorytags, sourceId, canFetchContentGet all Workbooks defined within a specified resource group and category.
list_by_subscriptionselectsubscriptionId, categorytags, canFetchContentGet all Workbooks defined within a specified subscription and category.
create_or_updateinsertsubscriptionId, resourceGroupName, resourceNamesourceIdCreate a new workbook.
updateupdatesubscriptionId, resourceGroupName, resourceNamesourceIdUpdates a workbook that has already been added.
deletedeletesubscriptionId, resourceGroupName, resourceNameDelete a workbook.
revisions_listexecsubscriptionId, resourceGroupName, resourceNameGet the revisions for the workbook defined by its resourceName.
revision_getexecsubscriptionId, resourceGroupName, resourceName, revisionIdGet a single workbook revision defined by its revisionId.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
categorystringCategory of workbook to return.
resourceGroupNamestringThe name of the resource group. The name is case insensitive.
resourceNamestringThe name of the workbook resource. The value must be an UUID.
revisionIdstringThe id of the workbook's revision.
subscriptionIdstring (uuid)The ID of the target subscription. The value must be an UUID.
canFetchContentbooleanFlag indicating whether or not to return the full content for each applicable workbook. If false, only return summary content for workbooks.
sourceIdstringAzure Resource Id that will fetch all linked workbooks.
tagsarrayTags presents on each workbook returned.

SELECT examples

Get a single workbook by its resourceName.

SELECT
etag,
identity,
kind,
properties,
systemData
FROM azure.application_insights.workbooks
WHERE subscriptionId = '{{ subscriptionId }}' -- required
AND resourceGroupName = '{{ resourceGroupName }}' -- required
AND resourceName = '{{ resourceName }}' -- required
AND canFetchContent = '{{ canFetchContent }}'
;

INSERT examples

Create a new workbook.

INSERT INTO azure.application_insights.workbooks (
data__identity,
data__kind,
data__etag,
data__properties,
subscriptionId,
resourceGroupName,
resourceName,
sourceId
)
SELECT
'{{ identity }}',
'{{ kind }}',
'{{ etag }}',
'{{ properties }}',
'{{ subscriptionId }}',
'{{ resourceGroupName }}',
'{{ resourceName }}',
'{{ sourceId }}'
RETURNING
etag,
identity,
kind,
properties,
systemData
;

UPDATE examples

Updates a workbook that has already been added.

UPDATE azure.application_insights.workbooks
SET
data__kind = '{{ kind }}',
data__tags = '{{ tags }}',
data__properties = '{{ properties }}'
WHERE
subscriptionId = '{{ subscriptionId }}' --required
AND resourceGroupName = '{{ resourceGroupName }}' --required
AND resourceName = '{{ resourceName }}' --required
AND sourceId = '{{ sourceId}}'
RETURNING
etag,
identity,
kind,
properties,
systemData;

DELETE examples

Delete a workbook.

DELETE FROM azure.application_insights.workbooks
WHERE subscriptionId = '{{ subscriptionId }}' --required
AND resourceGroupName = '{{ resourceGroupName }}' --required
AND resourceName = '{{ resourceName }}' --required
;

Lifecycle Methods

Get the revisions for the workbook defined by its resourceName.

EXEC azure.application_insights.workbooks.revisions_list 
@subscriptionId='{{ subscriptionId }}' --required,
@resourceGroupName='{{ resourceGroupName }}' --required,
@resourceName='{{ resourceName }}' --required
;