-
Notifications
You must be signed in to change notification settings - Fork 5.2k
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Watcher resource swagger specs. For more details on the Usage of the resource: https://docs.microsoft.com/en-us/azure/automation/automation-watchers-tutorial #3102
Merged
Merged
Changes from 1 commit
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
72 changes: 72 additions & 0 deletions
72
...source-manager/Microsoft.Automation/stable/2015-10-31/examples/createOrUpdateWatcher.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,72 @@ | ||
{ | ||
"parameters": { | ||
"subscriptionId": "subid", | ||
"resourceGroupName": "rg", | ||
"automationAccountName": "MyTestAutomationAccount", | ||
"watcherName": "MyTestWatcher", | ||
"api-version": "2015-10-31", | ||
"parameters": { | ||
"name":"MyTestWatcher", | ||
"type":null, | ||
"location":null, | ||
"tags":{ }, | ||
"etag":null, | ||
"properties":{ | ||
"executionFrequencyInSeconds":60, | ||
"scriptName":"MyTestWatcherRunbook", | ||
"scriptParameters":null, | ||
"description":"This is a test watcher.", | ||
"scriptRunOn":"MyTestHybridWorkerGroup", | ||
"creationTime":"2016-11-01T04:22:47.7333333-07:00", | ||
"lastModifiedBy":null, | ||
"lastModifiedTime":"2016-11-01T04:22:47.7333333-07:00" | ||
} | ||
} | ||
}, | ||
"responses": { | ||
"201": { | ||
"headers": {}, | ||
"body": { | ||
"id":"/subscriptions/subId/resourceGroups/rg/providers/Microsoft.Automation/automationAccounts/MyTestAutomationAccount/watchers/MyTestWatcher", | ||
"name":"MyTestWatcher", | ||
"type":null, | ||
"location":null, | ||
"tags":{ }, | ||
"etag":null, | ||
"properties":{ | ||
"executionFrequencyInSeconds":60, | ||
"scriptName":"MyTestWatcherRunbook", | ||
"scriptParameters":null, | ||
"description":"This is a test watcher.", | ||
"status":"New", | ||
"scriptRunOn":"MyTestHybridWorkerGroup", | ||
"creationTime":"2018-05-14T21:14:09.607+00:00", | ||
"lastModifiedBy":null, | ||
"lastModifiedTime":"2018-05-14T21:14:09.607+00:00" | ||
} | ||
} | ||
}, | ||
"200": { | ||
"headers": {}, | ||
"body": { | ||
"id":"/subscriptions/subId/resourceGroups/rg/providers/Microsoft.Automation/automationAccounts/MyTestAutomationAccount/watchers/MyTestWatcher", | ||
"name":"MyTestWatcher", | ||
"type":null, | ||
"location":null, | ||
"tags":{ }, | ||
"etag":null, | ||
"properties":{ | ||
"executionFrequencyInSeconds":60, | ||
"scriptName":"MyTestWatcherRunbook", | ||
"scriptParameters":null, | ||
"description":"This is a test watcher.", | ||
"status":"New", | ||
"scriptRunOn":"MyTestHybridWorkerGroup", | ||
"creationTime":"2018-05-14T21:14:09.607+00:00", | ||
"lastModifiedBy":null, | ||
"lastModifiedTime":"2018-05-14T21:14:09.607+00:00" | ||
} | ||
} | ||
} | ||
} | ||
} |
12 changes: 12 additions & 0 deletions
12
...ation/resource-manager/Microsoft.Automation/stable/2015-10-31/examples/deleteWatcher.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": { | ||
"subscriptionId": "subid", | ||
"resourceGroupName": "rg", | ||
"automationAccountName": "MyTestAutomationAccount", | ||
"watcherName": "MyTestWatcher", | ||
"api-version": "2015-10-31" | ||
}, | ||
"responses": { | ||
"200": {} | ||
} | ||
} |
33 changes: 33 additions & 0 deletions
33
...tomation/resource-manager/Microsoft.Automation/stable/2015-10-31/examples/getWatcher.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,33 @@ | ||
{ | ||
"parameters": { | ||
"subscriptionId": "subid", | ||
"resourceGroupName": "rg", | ||
"automationAccountName": "MyTestAutomationAccount", | ||
"watcherName": "MyTestWatcher", | ||
"api-version": "2015-10-31" | ||
}, | ||
"responses":{ | ||
"200": { | ||
"headers": {}, | ||
"body": { | ||
"id":"/subscriptions/subId/resourceGroups/rg/providers/Microsoft.Automation/automationAccounts/MyTestAutomationAccount/watchers/MyTestWatcher", | ||
"name":"MyTestWatcher", | ||
"type":null, | ||
"location":null, | ||
"tags":{ }, | ||
"etag":null, | ||
"properties":{ | ||
"executionFrequencyInSeconds":60, | ||
"scriptName":"MyTestWatcherRunbook", | ||
"scriptParameters":{ }, | ||
"description":"", | ||
"status":"Running", | ||
"scriptRunOn":"MyTestHybridWorkerGroup", | ||
"creationTime":"2017-11-30T18:50:17.163+00:00", | ||
"lastModifiedBy":null, | ||
"lastModifiedTime":"2017-11-30T18:50:17.163+00:00" | ||
} | ||
} | ||
} | ||
} | ||
} |
62 changes: 62 additions & 0 deletions
62
...ager/Microsoft.Automation/stable/2015-10-31/examples/listWatchersByAutomationAccount.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,62 @@ | ||
{ | ||
"parameters": { | ||
"subscriptionId": "subid", | ||
"resourceGroupName": "rg", | ||
"automationAccountName": "MyTestAutomationAccount", | ||
"api-version": "2015-10-31" | ||
}, | ||
"responses": { | ||
"200": { | ||
"headers": {}, | ||
"body": { | ||
"value": [ | ||
{ | ||
"id":"/subscriptions/subid/resourceGroups/rg/providers/Microsoft.Automation/automationAccounts/MyTestAutomationAccount/watchers/MyTestWatcher", | ||
"name":"MyTestWatcher", | ||
"properties":{ | ||
"executionFrequencyInSeconds":60, | ||
"scriptName":"MyTestWatcher", | ||
"scriptParameters":null, | ||
"description":"This is a test watcher.", | ||
"status":null, | ||
"scriptRunOn":"MyTestHybridWorkerGroup", | ||
"creationTime":"2016-12-20T21:36:48.597+00:00", | ||
"lastModifiedBy":null, | ||
"lastModifiedTime":"2016-12-20T21:36:48.597+00:00" | ||
} | ||
}, | ||
{ | ||
"id":"/subscriptions/subid/resourceGroups/rg/providers/Microsoft.Automation/automationAccounts/MyTestAutomationAccount/watchers/MyTestWatcher01", | ||
"name":"MyTestWatcher01", | ||
"properties":{ | ||
"executionFrequencyInSeconds":60, | ||
"scriptName":"MyTestWatcher", | ||
"scriptParameters":null, | ||
"description":"This is a test watcher.", | ||
"status":null, | ||
"scriptRunOn":"MyTestHybridWorkerGroup", | ||
"creationTime":"2016-12-20T20:47:24.697+00:00", | ||
"lastModifiedBy":null, | ||
"lastModifiedTime":"2016-12-20T20:47:24.697+00:00" | ||
} | ||
}, | ||
{ | ||
"id":"/subscriptions/subid/resourceGroups/rg/providers/Microsoft.Automation/automationAccounts/MyTestAutomationAccount/watchers/MyTestWatcher02", | ||
"name":"MyTestWatcher02", | ||
"properties":{ | ||
"executionFrequencyInSeconds":60, | ||
"scriptName":"MyTestWatcher", | ||
"scriptParameters":null, | ||
"description":"This is a test watcher.", | ||
"status":null, | ||
"scriptRunOn":"MyTestHybridWorkerGroup", | ||
"creationTime":"2016-12-20T21:26:35.647+00:00", | ||
"lastModifiedBy":null, | ||
"lastModifiedTime":"2016-12-20T21:26:35.647+00:00" | ||
} | ||
} | ||
] | ||
} | ||
} | ||
} | ||
} |
12 changes: 12 additions & 0 deletions
12
...mation/resource-manager/Microsoft.Automation/stable/2015-10-31/examples/startWatcher.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": { | ||
"subscriptionId": "subid", | ||
"resourceGroupName": "rg", | ||
"automationAccountName": "MyTestAutomationAccount", | ||
"watcherName": "MyTestWatcher", | ||
"api-version": "2015-10-31" | ||
}, | ||
"responses": { | ||
"200": {} | ||
} | ||
} |
12 changes: 12 additions & 0 deletions
12
...omation/resource-manager/Microsoft.Automation/stable/2015-10-31/examples/stopWatcher.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": { | ||
"subscriptionId": "subid", | ||
"resourceGroupName": "rg", | ||
"automationAccountName": "MyTestAutomationAccount", | ||
"watcherName": "MyTestWatcher", | ||
"api-version": "2018-01-15" | ||
}, | ||
"responses": { | ||
"200": {} | ||
} | ||
} |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
name should not be updatable through the request body. read-only?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for reviewing Gaurav. As discussed, using the same Watcher model for get/put and also using the same model of input and output of the put request. Marking fields in the watcher model as readonly as required. using a different model for input for patch.