Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

sync with master #3153

Merged
merged 10 commits into from
May 30, 2018
Prev Previous commit
Next Next commit
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)

* Watcher specs

* using the same model for get/put input and output.
  • Loading branch information
mohanishpenta authored and lmazuel committed May 29, 2018
commit e6f31c080614ba3449e450e800bf0428edea3587
Original file line number Diff line number Diff line change
Expand Up @@ -3816,6 +3816,117 @@
}
},
"description": "The parameters supplied to the update webhook operation."
},
"WatcherProperties": {
"properties": {
"executionFrequencyInSeconds": {
"type": "integer",
"format": "int64",
"description": "Gets or sets the frequency at which the watcher is invoked."
},
"scriptName": {
"type": "string",
"description": "Gets or sets the name of the script the watcher is attached to, i.e. the name of an existing runbook."
},
"scriptParameters": {
"type": "object",
"additionalProperties": {
"type": "string"
},
"description": "Gets or sets the parameters of the script."
},
"scriptRunOn": {
"type": "string",
"description": "Gets or sets the name of the hybrid worker group the watcher will run on."
},
"status": {
"type": "string",
"readOnly": true,
"description": "Gets the current status of the watcher."
},
"creationTime": {
"type": "string",
"readOnly": true,
"format": "date-time",
"description": "Gets or sets the creation time.",
"x-nullable": false
},
"lastModifiedTime": {
"type": "string",
"readOnly": true,
"format": "date-time",
"description": "Gets or sets the last modified time.",
"x-nullable": false
},
"lastModifiedBy": {
"type": "string",
"readOnly": true,
"description": "Details of the user who last modified the watcher."
},
"description": {
"type": "string",
"description": "Gets or sets the description."
}
},
"description": "Definition of the watcher properties"
},
"Watcher": {
"properties": {
"properties": {
"$ref": "#/definitions/WatcherProperties",
"x-ms-client-flatten": true,
"description": "Gets or sets the watcher properties."
},
"etag": {
"type": "string",
"description": "Gets or sets the etag of the resource."
}
},
"description": "Definition of the watcher type.",
"allOf": [
{
"$ref": "#/definitions/TrackedResource"
}
]
},
"WatcherListResult": {
"properties": {
"value": {
"type": "array",
"items": {
"$ref": "#/definitions/Watcher"
},
"description": "Gets or sets a list of watchers."
},
"nextLink": {
"type": "string",
"description": "Gets or sets the next link."
}
},
"description": "The response model for the list watcher operation."
},
"WatcherUpdateParameters": {
"properties": {
"properties": {
"$ref": "#/definitions/WatcherUpdateProperties",
"x-ms-client-flatten": true,
"description": "Gets or sets the watcher update properties."
},
"name": {
"type": "string",
"description": "Gets or sets the name of the resource."
}
}
},
"WatcherUpdateProperties": {
"properties": {
"executionFrequencyInSeconds": {
"type": "integer",
"format": "int64",
"description": "Gets or sets the frequency at which the watcher is invoked."
}
},
"description": "The properties of the update watcher operation."
}
},
"parameters": {
Expand Down
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"
}
}
}
}
}
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": {}
}
}
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"
}
}
}
}
}
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"
}
}
]
}
}
}
}
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": {}
}
}
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": {}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
{
"parameters": {
"subscriptionId": "subid",
"resourceGroupName": "rg",
"automationAccountName": "MyTestAutomationAccount",
"watcherName": "MyTestWatcher",
"parameters": {
"name":"MyTestWatcher",
"properties":{
"executionFrequencyInSeconds":600
}
},
"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":600,
"scriptName":"MyTestWatcherRunbook",
"scriptParameters":{},
"description":"This is a test watcher.",
"status":"New",
"scriptRunOn":"MyTestHybridWorkerGroup",
"creationTime":"2018-05-14T21:33:02.197+00:00",
"lastModifiedBy":null,
"lastModifiedTime":"2018-05-14T22:29:57.65+00:00"
}
}
}
}
}
Loading