Skip to content
Closed
Changes from 1 commit
Commits
Show all changes
54 commits
Select commit Hold shift + click to select a range
eb38dfb
Added Swagger entry for Workbook resource
ericc1103 Mar 14, 2018
ea82a68
Fixed all example related errors.
ericc1103 Mar 14, 2018
d869ce9
Added missing files
ericc1103 Mar 14, 2018
a17dde3
Fixed all reference issues
ericc1103 Mar 14, 2018
ed3d2c8
Updated a serializedData with the actual workbook content
ericc1103 Mar 14, 2018
28d306e
Fixed serializedData syntax erros
ericc1103 Mar 14, 2018
397df4f
Updated more on serializedData to use workbook content
ericc1103 Mar 15, 2018
0f29489
Added workbooks type into OperationList
ericc1103 Mar 15, 2018
5d4bc6e
Fixed a parameter name from ResourceGroupName to ResourceGroup for wo…
ericc1103 Mar 15, 2018
acd3d3a
Restored ResourceGroupNameParameter to the original value
ericc1103 Mar 15, 2018
6b77397
Removed SharedTypeParameter since we are not using it. Added 'x-ms-pa…
ericc1103 Mar 15, 2018
302d2ae
Added 'x-ms-parameter-location' to purgeId and body parameters in com…
ericc1103 Mar 15, 2018
cd35c44
Modified POST & PATCH so that Body and response uses the same type.
ericc1103 Mar 15, 2018
75ea99e
Merge remote-tracking branch 'upstream/master'
ericc1103 Mar 19, 2018
6472b25
Added {location} parameter in the path for GET
ericc1103 Mar 19, 2018
50fe051
Added missing parameters and response fields
ericc1103 Mar 19, 2018
edba30a
Fixed params issue again
ericc1103 Mar 19, 2018
ac48433
Added workbook entries to readme.md
ericc1103 Mar 20, 2018
056a8a4
Add files via upload
ericc1103 Mar 20, 2018
602ed11
Add files via upload
ericc1103 Mar 20, 2018
ef71f10
Merge remote-tracking branch 'upstream/master'
ericc1103 Mar 20, 2018
d917fb9
Merge remote-tracking branch 'upstream/master'
ericc1103 Mar 20, 2018
2e97001
Fixed all validation errors for examples
ericc1103 Mar 20, 2018
b8b0791
Merge branch 'master' of https://github.com/ericc1103/azure-rest-api-…
ericc1103 Mar 20, 2018
61a643f
Fixed all merge issues. (Fixed all validation errors for examples)
ericc1103 Mar 20, 2018
ab805ce
Update workbooks_API.json
ericc1103 Mar 20, 2018
4a2bf77
Update WorkbookAdd.json
ericc1103 Mar 20, 2018
0b960ec
Update WorkbookGet.json
ericc1103 Mar 20, 2018
7abe2b7
Update WorkbookResponseOnly.json
ericc1103 Mar 20, 2018
c33cb99
Update WorkbookUpdate.json
ericc1103 Mar 20, 2018
e55eef0
Update WorkbookUpdateLink.json
ericc1103 Mar 20, 2018
2add5e3
Update WorkbooksList.json
ericc1103 Mar 20, 2018
3dd49e7
Update WorkbooksListLink.json
ericc1103 Mar 20, 2018
a16b4b9
Removed linkedWorkbooks_API.json reference.
ericc1103 Mar 20, 2018
171ebd6
Update workbooks_API.json
ericc1103 Mar 20, 2018
8ee7a77
Update workbooks_API.json
ericc1103 Mar 29, 2018
7b0ce0c
Update WorkbookAddLink.json
ericc1103 Mar 29, 2018
5a69bbc
Update WorkbookResponseOnly.json
ericc1103 Mar 29, 2018
466e6f5
Update workbooks_API.json
ericc1103 Mar 29, 2018
cbc9a29
Update WorkbookAddLink.json
ericc1103 Mar 29, 2018
4b30d56
Update WorkbookResponseOnly.json
ericc1103 Mar 29, 2018
7a2eba6
Update workbooks_API.json
ericc1103 Mar 29, 2018
08eca8c
Update workbooks_API.json
ericc1103 Mar 29, 2018
64ac742
Update workbooks_API.json
ericc1103 Mar 29, 2018
80256d5
Update workbooks_API.json
ericc1103 Mar 29, 2018
344b07a
Update workbooks_API.json
ericc1103 Mar 29, 2018
d466710
Create workbookDelete.json
ericc1103 Mar 29, 2018
7c8c0b0
Update LinkedWorkbookResponseOnly.json
ericc1103 Mar 29, 2018
b3f35f4
Update WorkbookResponseOnly.json
ericc1103 Mar 29, 2018
847e7eb
Update workbooks_API.json
ericc1103 Mar 29, 2018
0efeae9
Update workbooks_API.json
ericc1103 Mar 29, 2018
d7bde1c
Create workbookDe
ericc1103 Mar 29, 2018
a957d1b
Update LinkedWorkbookResponseOnly.json
ericc1103 Mar 29, 2018
564b51f
Update WorkbookResponseOnly.json
ericc1103 Mar 29, 2018
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Update workbooks_API.json
  • Loading branch information
ericc1103 authored Mar 29, 2018
commit 466e6f539a438ebdd7421a5cd15d1617fac1337a
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
}
},
"paths": {
"/subscriptions/{subscriptionId}/resourceGroup/{resourceGroupName}/locations/{location}/providers/microsoft.insights/workbooks/category/{category}": {
"/subscriptions/{subscriptionId}/resourceGroup/{resourceGroupName}/providers/microsoft.insights/workbooks": {
"get": {
"description": "Get all Workbooks defined within a specified resource group and category.",
"operationId": "Workbooks_ListByResourceGroup",
Expand All @@ -45,7 +45,7 @@
{
"$ref": "#/parameters/ResourceGroupNameParameter"
},
{
{
"$ref": "#/parameters/LocationParameter"
},
{
Expand All @@ -70,6 +70,12 @@
"$ref": "#/definitions/Workbook"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should return a "value" array which will be a collection of workbooks. But anyway, as stated above the API signature does not indicate that. As per the API signature, customer is doing a GET on the category/{categoryName} and is expected to return a "category" entity

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Will fix so that it will return object that contains an array. A workbook contains a category in properties field.

}
}
},
"default": {
"description": "Error response describing why the operation failed.",
"schema": {
"$ref": "#/definitions/ErrorResponse"
}
}
},
"x-ms-examples": {
Expand All @@ -79,41 +85,7 @@
}
}
},
"/subscriptions/{subscriptionId}/resourceGroup/{resourceGroupName}/locations/{location}/providers/microsoft.insights/workbooks/{resourceName}": {
"get": {
"description": "Get a single workbook by its resourceName.",
"operationId": "Workbooks_Get",
"parameters": [
{
"$ref": "#/parameters/SubscriptionIdParameter"
},
{
"$ref": "#/parameters/ResourceGroupNameParameter"
},
{
"$ref": "#/parameters/LocationParameter"
},
{
"$ref": "#/parameters/WorkbookResourceNameParameter"
},
{
"$ref": "#/parameters/ApiVersionParameter"
}
],
"responses": {
"200": {
"description": "A workbook definition.",
"schema": {
"$ref": "#/definitions/Workbook"
}
}
},
"x-ms-examples": {
"WorkbookGet": {
"$ref": "./examples/WorkbookGet.json"
}
}
},
"/subscriptions/{subscriptionId}/resourceGroup/{resourceGroupName}/providers/microsoft.insights/workbooks/{resourceName}": {
"delete": {
"description": "Delete a workbook.",
"operationId": "Workbooks_Delete",
Expand All @@ -137,16 +109,23 @@
"responses": {
"200": {
"description": "The workbook has been successfully deleted."
},
"204": {
"description": "The resource doens't exisit."
},
"default": {
"description": "Error response describing why the operation failed.",
"schema": {
"$ref": "#/definitions/ErrorResponse"
}
}
},
"x-ms-examples": {
"WorkbookList": {
"$ref": "./examples/WorkbookResponseOnly.json"
}
}
}
},
"/subscriptions/{subscriptionId}/resourceGroup/{resourceGroupName}/providers/microsoft.insights/workbooks/{resourceName}": {
},
"put": {
"description": "Create a new workbook.",
"operationId": "Workbooks_Create",
Expand Down Expand Up @@ -179,6 +158,12 @@
"schema": {
"$ref": "#/definitions/Workbook"
}
},
"default": {
"description": "Error response describing why the operation failed.",
"schema": {
"$ref": "#/definitions/ErrorResponse"
}
}
},
"x-ms-examples": {
Expand Down Expand Up @@ -219,6 +204,12 @@
"schema": {
"$ref": "#/definitions/Workbook"
}
},
"default": {
"description": "Error response describing why the operation failed.",
"schema": {
"$ref": "#/definitions/ErrorResponse"
}
}
},
"x-ms-examples": {
Expand All @@ -228,7 +219,46 @@
}
}
},
"/providers/microsoft.insights/workbooks/category/{category}": {
"/subscriptions/{subscriptionId}/providers/microsoft.insights/workbooks/{resourceName}": {
"get": {
"description": "Get a single workbook by its resourceName.",
"operationId": "Workbooks_Get",
"parameters": [
{
"$ref": "#/parameters/SubscriptionIdParameter"
},
{
"$ref": "#/parameters/WorkbookResourceNameParameter"
},
{
"$ref": "#/parameters/LocationParameter"
},
{
"$ref": "#/parameters/ApiVersionParameter"
}
],
"responses": {
"200": {
"description": "A workbook definition.",
"schema": {
"$ref": "#/definitions/Workbook"
}
},
"default": {
"description": "Error response describing why the operation failed.",
"schema": {
"$ref": "#/definitions/ErrorResponse"
}
}
},
"x-ms-examples": {
"WorkbookGet": {
"$ref": "./examples/WorkbookGet.json"
}
}
}
},
"/providers/microsoft.insights/workbooks": {
"get": {
"description": "Gets a list of workbooks.",
"operationId": "Workbooks_ListBySourceId",
Expand Down Expand Up @@ -258,19 +288,23 @@
"$ref": "#/definitions/Workbook"
}
}
},
"default": {
"description": "Error response describing why the operation failed.",
"schema": {
"$ref": "#/definitions/ErrorResponse"
}
}
},
"x-ms-examples": {
"WorkbooksList": {
"$ref": "./examples/WorkbooksListLink.json"
}
}
}
},
"/subscriptions/{subscriptionId}/resourceGroup/{resourceGroupName}/resourceName/{resourceName}/providers/microsoft.insights/workbooks": {
},
"put": {
"description": "Create a new workbook.",
"operationId": "Workbook_CreateLink",
"operationId": "Workbooks_CreateLink",
"parameters": [
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

WHy does this not have a request/response body? The operation Id seems to indicate it is creating some link and not an actual workbook. What is this link?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We are just create a link between a source resource and a workbook resource. Therefore, just return 200 is enough.

{
"$ref": "#/parameters/SubscriptionIdParameter"
Expand All @@ -291,6 +325,12 @@
"responses": {
"200": {
"description": "The link has been created."
},
"default": {
"description": "Error response describing why the operation failed.",
"schema": {
"$ref": "#/definitions/ErrorResponse"
}
}
},
"x-ms-examples": {
Expand All @@ -301,7 +341,7 @@
},
"patch": {
"description": "Updates a workbook that has already been added.",
"operationId": "Workbook_UpdateLink",
"operationId": "Workbooks_UpdateLink",
"parameters": [
{
"$ref": "#/parameters/SubscriptionIdParameter"
Expand All @@ -325,6 +365,12 @@
"schema": {
"$ref": "#/definitions/Workbook"
}
},
"default": {
"description": "Error response describing why the operation failed.",
"schema": {
"$ref": "#/definitions/ErrorResponse"
}
}
},
"x-ms-examples": {
Expand All @@ -335,7 +381,7 @@
},
"delete": {
"description": "Delete a workbook.",
"operationId": "Workbook_DeleteLink",
"operationId": "Workbooks_DeleteLink",
"parameters": [
{
"$ref": "#/parameters/ResourceGroupNameParameter"
Expand All @@ -353,6 +399,15 @@
"responses": {
"200": {
"description": "The workbook link has been successfully deleted."
},
"204": {
"description": "The resource doens't exisit."
},
"default": {
"description": "Error response describing why the operation failed.",
"schema": {
"$ref": "#/definitions/ErrorResponse"
}
}
},
"x-ms-examples": {
Expand Down Expand Up @@ -492,6 +547,43 @@
"description": "Optional resourceId for a source resource."
}
}
},
"ErrorFieldContract": {
"properties": {
"code": {
"type": "string",
"description": "Property level error code."
},
"message": {
"type": "string",
"description": "Human-readable representation of property-level error."
},
"target": {
"type": "string",
"description": "Property name."
}
},
"description": "Error Field contract."
},
"ErrorResponse": {
"properties": {
"code": {
"type": "string",
"description": "Service-defined error code. This code serves as a sub-status for the HTTP error code specified in the response."
},
"message": {
"type": "string",
"description": "Human-readable representation of the error."
},
"details": {
"type": "array",
"items": {
"$ref": "#/definitions/ErrorFieldContract"
},
"description": "The list of invalid fields send in request, in case of validation error."
}
},
"description": "Error Body contract."
}
},
"parameters": {
Expand Down Expand Up @@ -527,15 +619,15 @@
},
"LocationParameter": {
"name": "location",
"in": "path",
"in": "query",
"required": true,
"type": "string",
"description": "The name of location where workbook is stored.",
"x-ms-parameter-location": "method"
},
"CategoryParameter": {
"name": "category",
"in": "path",
"in": "query",
"required": true,
"type": "string",
"enum": [
Expand Down