forked from Azure/azure-sdk-for-python
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
stable 2020-11-20 workbooktemplates (Azure#13793)
* stable 2020-11-20 workbooktemplates * ref examples in readme * fix path * add swagger 2.0 * fix lintdiff failures * update name * Update readme.python.md * Update readme.md * Update readme.md * Update readme.python.md * Update readme.python.md * update WorkbookError to WorkbookTemplateError * Update readme.md * add templateData examples * Update specification/applicationinsights/resource-manager/Microsoft.Insights/stable/2020-11-20/workbookTemplates_API.json Co-authored-by: kai ru <69238381+kairu-ms@users.noreply.github.com> * Update specification/applicationinsights/resource-manager/Microsoft.Insights/stable/2020-11-20/workbookTemplates_API.json Co-authored-by: kai ru <69238381+kairu-ms@users.noreply.github.com> * updated errorfiledcontract name * make prettier * added templateData samples * update to only workbooktemplates * rename package-2020-11-20 to package-2020-11-only Co-authored-by: kai ru <69238381+kairu-ms@users.noreply.github.com>
- Loading branch information
Showing
8 changed files
with
1,092 additions
and
1 deletion.
There are no files selected for viewing
151 changes: 151 additions & 0 deletions
151
...s/resource-manager/Microsoft.Insights/stable/2020-11-20/examples/WorkbookTemplateAdd.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,151 @@ | ||
{ | ||
"parameters": { | ||
"api-version": "2020-11-20", | ||
"resourceGroupName": "my-resource-group", | ||
"resourceName": "testtemplate2", | ||
"subscriptionId": "subid", | ||
"workbookTemplateProperties": { | ||
"location": "west us", | ||
"properties": { | ||
"priority": 1, | ||
"author": "Contoso", | ||
"galleries": [ | ||
{ | ||
"name": "Simple Template", | ||
"category": "Failures", | ||
"type": "tsg", | ||
"resourceType": "microsoft.insights/components", | ||
"order": 100 | ||
} | ||
], | ||
"templateData": { | ||
"version": "Notebook/1.0", | ||
"items": [ | ||
{ | ||
"type": 1, | ||
"content": { | ||
"json": "## New workbook\n---\n\nWelcome to your new workbook. This area will display text formatted as markdown.\n\n\nWe've included a basic analytics query to get you started. Use the `Edit` button below each section to configure it or add more sections." | ||
}, | ||
"name": "text - 2" | ||
}, | ||
{ | ||
"type": 3, | ||
"content": { | ||
"version": "KqlItem/1.0", | ||
"query": "union withsource=TableName *\n| summarize Count=count() by TableName\n| render barchart", | ||
"size": 1, | ||
"exportToExcelOptions": "visible", | ||
"queryType": 0, | ||
"resourceType": "microsoft.operationalinsights/workspaces" | ||
}, | ||
"name": "query - 2" | ||
} | ||
], | ||
"styleSettings": {}, | ||
"$schema": "https://github.com/Microsoft/Application-Insights-Workbooks/blob/master/schema/workbook.json" | ||
} | ||
}, | ||
"tags": null | ||
} | ||
}, | ||
"responses": { | ||
"200": { | ||
"body": { | ||
"name": "testtemplate2", | ||
"location": "westeurope", | ||
"tags": null, | ||
"type": "microsoft.insights/workbooktemplates", | ||
"id": "/subscriptions/50359d91-7b9d-4823-85af-eb298a61ba95/resourceGroups/testrg/providers/microsoft.insights/workbooktemplates/testtemplate2", | ||
"properties": { | ||
"priority": 1, | ||
"author": "Contoso", | ||
"templateData": { | ||
"version": "Notebook/1.0", | ||
"items": [ | ||
{ | ||
"type": 1, | ||
"content": { | ||
"json": "## New workbook\n---\n\nWelcome to your new workbook. This area will display text formatted as markdown.\n\n\nWe've included a basic analytics query to get you started. Use the `Edit` button below each section to configure it or add more sections." | ||
}, | ||
"name": "text - 2" | ||
}, | ||
{ | ||
"type": 3, | ||
"content": { | ||
"version": "KqlItem/1.0", | ||
"query": "union withsource=TableName *\n| summarize Count=count() by TableName\n| render barchart", | ||
"size": 1, | ||
"exportToExcelOptions": "visible", | ||
"queryType": 0, | ||
"resourceType": "microsoft.operationalinsights/workspaces" | ||
}, | ||
"name": "query - 2" | ||
} | ||
], | ||
"styleSettings": {}, | ||
"$schema": "https://github.com/Microsoft/Application-Insights-Workbooks/blob/master/schema/workbook.json" | ||
}, | ||
"galleries": [ | ||
{ | ||
"name": "Simple Template", | ||
"category": "Failures", | ||
"order": 100, | ||
"type": "tsg", | ||
"resourceType": "microsoft.insights/components" | ||
} | ||
], | ||
"localized": null | ||
} | ||
} | ||
}, | ||
"201": { | ||
"body": { | ||
"name": "testtemplate2", | ||
"location": "westeurope", | ||
"tags": null, | ||
"type": "microsoft.insights/workbooktemplates", | ||
"id": "/subscriptions/50359d91-7b9d-4823-85af-eb298a61ba95/resourceGroups/testrg/providers/microsoft.insights/workbooktemplates/testtemplate2", | ||
"properties": { | ||
"priority": 1, | ||
"author": "Contoso", | ||
"templateData": { | ||
"version": "Notebook/1.0", | ||
"items": [ | ||
{ | ||
"type": 1, | ||
"content": { | ||
"json": "## New workbook\n---\n\nWelcome to your new workbook. This area will display text formatted as markdown.\n\n\nWe've included a basic analytics query to get you started. Use the `Edit` button below each section to configure it or add more sections." | ||
}, | ||
"name": "text - 2" | ||
}, | ||
{ | ||
"type": 3, | ||
"content": { | ||
"version": "KqlItem/1.0", | ||
"query": "union withsource=TableName *\n| summarize Count=count() by TableName\n| render barchart", | ||
"size": 1, | ||
"exportToExcelOptions": "visible", | ||
"queryType": 0, | ||
"resourceType": "microsoft.operationalinsights/workspaces" | ||
}, | ||
"name": "query - 2" | ||
} | ||
], | ||
"styleSettings": {}, | ||
"$schema": "https://github.com/Microsoft/Application-Insights-Workbooks/blob/master/schema/workbook.json" | ||
}, | ||
"galleries": [ | ||
{ | ||
"name": "Simple Template", | ||
"category": "Failures", | ||
"order": 100, | ||
"type": "tsg", | ||
"resourceType": "microsoft.insights/components" | ||
} | ||
], | ||
"localized": null | ||
} | ||
} | ||
} | ||
} | ||
} |
12 changes: 12 additions & 0 deletions
12
...esource-manager/Microsoft.Insights/stable/2020-11-20/examples/WorkbookTemplateDelete.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
{ | ||
"parameters": { | ||
"api-version": "2020-11-20", | ||
"subscriptionId": "subid", | ||
"resourceGroupName": "my-resource-group", | ||
"resourceName": "my-template-resource" | ||
}, | ||
"responses": { | ||
"200": {}, | ||
"204": {} | ||
} | ||
} |
58 changes: 58 additions & 0 deletions
58
...s/resource-manager/Microsoft.Insights/stable/2020-11-20/examples/WorkbookTemplateGet.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
{ | ||
"parameters": { | ||
"api-version": "2020-11-20", | ||
"subscriptionId": "6b643656-33eb-422f-aee8-3ac145d124af", | ||
"resourceGroupName": "my-resource-group", | ||
"resourceName": "my-resource-name" | ||
}, | ||
"responses": { | ||
"200": { | ||
"body": { | ||
"name": "my-resource-name", | ||
"type": "microsoft.insights/workbooktemplate", | ||
"location": "westus", | ||
"id": "/subscriptions/6b643656-33eb-422f-aee8-3ac145d124af/resourceGroups/my-resource-group/providers/microsoft.insights/workbooktemplates/my-resource-name", | ||
"properties": { | ||
"priority": 1, | ||
"author": "Contoso", | ||
"galleries": [ | ||
{ | ||
"name": "Simple Template", | ||
"category": "Failures", | ||
"type": "tsg", | ||
"resourceType": "microsoft.insights/components", | ||
"order": 100 | ||
} | ||
], | ||
"templateData": { | ||
"version": "Notebook/1.0", | ||
"items": [ | ||
{ | ||
"type": 1, | ||
"content": { | ||
"json": "## New workbook\n---\n\nWelcome to your new workbook. This area will display text formatted as markdown.\n\n\nWe've included a basic analytics query to get you started. Use the `Edit` button below each section to configure it or add more sections." | ||
}, | ||
"name": "text - 2" | ||
}, | ||
{ | ||
"type": 3, | ||
"content": { | ||
"version": "KqlItem/1.0", | ||
"query": "union withsource=TableName *\n| summarize Count=count() by TableName\n| render barchart", | ||
"size": 1, | ||
"exportToExcelOptions": "visible", | ||
"queryType": 0, | ||
"resourceType": "microsoft.operationalinsights/workspaces" | ||
}, | ||
"name": "query - 2" | ||
} | ||
], | ||
"styleSettings": {}, | ||
"$schema": "https://github.com/Microsoft/Application-Insights-Workbooks/blob/master/schema/workbook.json" | ||
} | ||
}, | ||
"tags": null | ||
} | ||
} | ||
} | ||
} |
104 changes: 104 additions & 0 deletions
104
...esource-manager/Microsoft.Insights/stable/2020-11-20/examples/WorkbookTemplateUpdate.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,104 @@ | ||
{ | ||
"parameters": { | ||
"api-version": "2020-11-20", | ||
"subscriptionId": "6b643656-33eb-422f-aee8-3ac145d124af", | ||
"resourceGroupName": "my-resource-group", | ||
"resourceName": "my-template-resource", | ||
"workbookTemplateProperties": { | ||
"name": "display-name-of-template", | ||
"location": "west us", | ||
"type": "microsoft.insights/workbooktemplates", | ||
"properties": { | ||
"priority": 1, | ||
"author": "Contoso", | ||
"galleries": [ | ||
{ | ||
"name": "Simple Template", | ||
"category": "Failures", | ||
"type": "tsg", | ||
"resourceType": "microsoft.insights/components", | ||
"order": 100 | ||
} | ||
], | ||
"templateData": { | ||
"version": "Notebook/1.0", | ||
"items": [ | ||
{ | ||
"type": 1, | ||
"content": { | ||
"json": "## New workbook\n---\n\nWelcome to your new workbook. This area will display text formatted as markdown.\n\n\nWe've included a basic analytics query to get you started. Use the `Edit` button below each section to configure it or add more sections." | ||
}, | ||
"name": "text - 2" | ||
}, | ||
{ | ||
"type": 3, | ||
"content": { | ||
"version": "KqlItem/1.0", | ||
"query": "union withsource=TableName *\n| summarize Count=count() by TableName\n| render barchart", | ||
"size": 1, | ||
"exportToExcelOptions": "visible", | ||
"queryType": 0, | ||
"resourceType": "microsoft.operationalinsights/workspaces" | ||
}, | ||
"name": "query - 2" | ||
} | ||
], | ||
"styleSettings": {}, | ||
"$schema": "https://github.com/Microsoft/Application-Insights-Workbooks/blob/master/schema/workbook.json" | ||
} | ||
}, | ||
"tags": null | ||
} | ||
}, | ||
"responses": { | ||
"200": { | ||
"body": { | ||
"name": "testtemplate2", | ||
"location": "westeurope", | ||
"tags": null, | ||
"type": "microsoft.insights/workbooktemplates", | ||
"id": "/subscriptions/50359d91-7b9d-4823-85af-eb298a61ba95/resourceGroups/testrg/providers/microsoft.insights/workbooktemplates/testtemplate2", | ||
"properties": { | ||
"priority": 1, | ||
"author": "Contoso", | ||
"templateData": { | ||
"version": "Notebook/1.0", | ||
"items": [ | ||
{ | ||
"type": 1, | ||
"content": { | ||
"json": "## New workbook\n---\n\nWelcome to your new workbook. This area will display text formatted as markdown.\n\n\nWe've included a basic analytics query to get you started. Use the `Edit` button below each section to configure it or add more sections." | ||
}, | ||
"name": "text - 2" | ||
}, | ||
{ | ||
"type": 3, | ||
"content": { | ||
"version": "KqlItem/1.0", | ||
"query": "union withsource=TableName *\n| summarize Count=count() by TableName\n| render barchart", | ||
"size": 1, | ||
"exportToExcelOptions": "visible", | ||
"queryType": 0, | ||
"resourceType": "microsoft.operationalinsights/workspaces" | ||
}, | ||
"name": "query - 2" | ||
} | ||
], | ||
"styleSettings": {}, | ||
"$schema": "https://github.com/Microsoft/Application-Insights-Workbooks/blob/master/schema/workbook.json" | ||
}, | ||
"galleries": [ | ||
{ | ||
"name": "Simple Template", | ||
"category": "Failures", | ||
"order": 100, | ||
"type": "tsg", | ||
"resourceType": "microsoft.insights/components" | ||
} | ||
], | ||
"localized": null | ||
} | ||
} | ||
} | ||
} | ||
} |
Oops, something went wrong.