Skip to content
This repository has been archived by the owner on May 5, 2023. It is now read-only.

Commit

Permalink
generating from 2018-05-01-preview version of the swagger spec.
Browse files Browse the repository at this point in the history
  • Loading branch information
amarzavery committed May 16, 2018
1 parent 9047f97 commit 982f736
Show file tree
Hide file tree
Showing 23 changed files with 1,789 additions and 185 deletions.
42 changes: 21 additions & 21 deletions lib/services/eventgridManagement/LICENSE.txt
Original file line number Diff line number Diff line change
@@ -1,21 +1,21 @@
The MIT License (MIT)

Copyright (c) 2018 Microsoft

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
The MIT License (MIT)
Copyright (c) 2018 Microsoft
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
84 changes: 42 additions & 42 deletions lib/services/eventgridManagement/README.md
Original file line number Diff line number Diff line change
@@ -1,42 +1,42 @@
---
uid: azure-arm-eventgrid
summary: *content

---
# Microsoft Azure SDK for Node.js - EventGridManagementClient
This project provides a Node.js package for accessing Azure. Right now it supports:
- **Node.js version 6.x.x or higher**

## Features


## How to Install

```bash
npm install azure-arm-eventgrid
```

## How to use

### Authentication, client creation and get eventSubscriptions as an example.

```javascript
const msRestAzure = require("ms-rest-azure");
const EventGridManagementClient = require("azure-arm-eventgrid");
msRestAzure.interactiveLogin().then((creds) => {
const subscriptionId = "<Subscription_Id>";
const client = new EventGridManagementClient(creds, subscriptionId);
const scope = "testscope";
const eventSubscriptionName = "testeventSubscriptionName";
return client.eventSubscriptions.get(scope, eventSubscriptionName).then((result) => {
console.log("The result is:");
console.log(result);
});
}).catch((err) => {
console.log('An error occurred:');
console.dir(err, {depth: null, colors: true});
});

## Related projects

- [Microsoft Azure SDK for Node.js](https://github.com/Azure/azure-sdk-for-node)
---
uid: azure-arm-eventgrid
summary: *content

---
# Microsoft Azure SDK for Node.js - EventGridManagementClient
This project provides a Node.js package for accessing Azure. Right now it supports:
- **Node.js version 6.x.x or higher**

## Features


## How to Install

```bash
npm install azure-arm-eventgrid
```

## How to use

### Authentication, client creation and get eventSubscriptions as an example.

```javascript
const msRestAzure = require("ms-rest-azure");
const EventGridManagementClient = require("azure-arm-eventgrid");
msRestAzure.interactiveLogin().then((creds) => {
const subscriptionId = "<Subscription_Id>";
const client = new EventGridManagementClient(creds, subscriptionId);
const scope = "testscope";
const eventSubscriptionName = "testeventSubscriptionName";
return client.eventSubscriptions.get(scope, eventSubscriptionName).then((result) => {
console.log("The result is:");
console.log(result);
});
}).catch((err) => {
console.log('An error occurred:');
console.dir(err, {depth: null, colors: true});
});

## Related projects

- [Microsoft Azure SDK for Node.js](https://github.com/Azure/azure-sdk-for-node)
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ class EventGridManagementClient extends ServiceClient {

super(credentials, options);

this.apiVersion = '2018-01-01';
this.apiVersion = '2018-05-01-preview';
this.acceptLanguage = 'en-US';
this.longRunningOperationRetryTimeout = 30;
this.generateClientRequestId = true;
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
/*
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for
* license information.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is
* regenerated.
*/

'use strict';

/**
* Information about the dead letter destination for an event subscription. To
* configure a deadletter destination, do not directly instantiate an object of
* this class. Instead, instantiate an object of a derived class. Currently,
* StorageBlobDeadLetterDestination is the only class that derives from this
* class.
*
*/
class DeadLetterDestination {
/**
* Create a DeadLetterDestination.
* @member {string} endpointType Polymorphic Discriminator
*/
constructor() {
}

/**
* Defines the metadata of DeadLetterDestination
*
* @returns {object} metadata of DeadLetterDestination
*
*/
mapper() {
return {
required: false,
serializedName: 'DeadLetterDestination',
type: {
name: 'Composite',
polymorphicDiscriminator: {
serializedName: 'endpointType',
clientName: 'endpointType'
},
uberParent: 'DeadLetterDestination',
className: 'DeadLetterDestination',
modelProperties: {
endpointType: {
required: true,
serializedName: 'endpointType',
isPolymorphicDiscriminator: true,
type: {
name: 'String'
}
}
}
}
};
}
}

module.exports = DeadLetterDestination;
46 changes: 45 additions & 1 deletion lib/services/eventgridManagement/lib/models/eventSubscription.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ class EventSubscription extends models['Resource'] {
* @member {string} [topic] Name of the topic of the event subscription.
* @member {string} [provisioningState] Provisioning state of the event
* subscription. Possible values include: 'Creating', 'Updating', 'Deleting',
* 'Succeeded', 'Canceled', 'Failed'
* 'Succeeded', 'Canceled', 'Failed', 'AwaitingManualAction'
* @member {object} [destination] Information about the destination where
* events have to be delivered for the event subscription.
* @member {string} [destination.endpointType] Polymorphic Discriminator
Expand All @@ -44,6 +44,21 @@ class EventSubscription extends models['Resource'] {
* SubjectBeginsWith and SubjectEndsWith properties of the filter
* should be compared in a case sensitive manner.
* @member {array} [labels] List of user defined labels.
* @member {string} [eventDeliverySchema] The event delivery schema for the
* event subscription. Possible values include: 'EventGridSchema',
* 'InputEventSchema', 'CloudEventV01Schema'. Default value:
* 'EventGridSchema' .
* @member {object} [retryPolicy] The retry policy for events. This can be
* used to configure maximum number of delivery attempts and time to live for
* events.
* @member {number} [retryPolicy.maxDeliveryAttempts] Maximum number of
* delivery retry attempts for events.
* @member {number} [retryPolicy.eventTimeToLiveInMinutes] Time To Live (in
* minutes) for events.
* @member {object} [deadLetterDestination] The DeadLetter destination of the
* event subscription.
* @member {string} [deadLetterDestination.endpointType] Polymorphic
* Discriminator
*/
constructor() {
super();
Expand Down Expand Up @@ -137,6 +152,35 @@ class EventSubscription extends models['Resource'] {
}
}
}
},
eventDeliverySchema: {
required: false,
serializedName: 'properties.eventDeliverySchema',
defaultValue: 'EventGridSchema',
type: {
name: 'String'
}
},
retryPolicy: {
required: false,
serializedName: 'properties.retryPolicy',
type: {
name: 'Composite',
className: 'RetryPolicy'
}
},
deadLetterDestination: {
required: false,
serializedName: 'properties.deadLetterDestination',
type: {
name: 'Composite',
polymorphicDiscriminator: {
serializedName: 'endpointType',
clientName: 'endpointType'
},
uberParent: 'DeadLetterDestination',
className: 'DeadLetterDestination'
}
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,21 @@ class EventSubscriptionUpdateParameters {
* SubjectBeginsWith and SubjectEndsWith properties of the filter
* should be compared in a case sensitive manner.
* @member {array} [labels] List of user defined labels.
* @member {string} [eventDeliverySchema] The event delivery schema for the
* event subscription. Possible values include: 'EventGridSchema',
* 'InputEventSchema', 'CloudEventV01Schema'. Default value:
* 'EventGridSchema' .
* @member {object} [retryPolicy] The retry policy for events. This can be
* used to configure maximum number of delivery attempts and time to live for
* events.
* @member {number} [retryPolicy.maxDeliveryAttempts] Maximum number of
* delivery retry attempts for events.
* @member {number} [retryPolicy.eventTimeToLiveInMinutes] Time To Live (in
* minutes) for events.
* @member {object} [deadLetterDestination] The DeadLetter destination of the
* event subscription.
* @member {string} [deadLetterDestination.endpointType] Polymorphic
* Discriminator
*/
constructor() {
}
Expand Down Expand Up @@ -91,6 +106,35 @@ class EventSubscriptionUpdateParameters {
}
}
}
},
eventDeliverySchema: {
required: false,
serializedName: 'eventDeliverySchema',
defaultValue: 'EventGridSchema',
type: {
name: 'String'
}
},
retryPolicy: {
required: false,
serializedName: 'retryPolicy',
type: {
name: 'Composite',
className: 'RetryPolicy'
}
},
deadLetterDestination: {
required: false,
serializedName: 'deadLetterDestination',
type: {
name: 'Composite',
polymorphicDiscriminator: {
serializedName: 'endpointType',
clientName: 'endpointType'
},
uberParent: 'DeadLetterDestination',
className: 'DeadLetterDestination'
}
}
}
}
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,71 @@
/*
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for
* license information.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is
* regenerated.
*/

'use strict';

const models = require('./index');

/**
* Information about the HybridConnection destination for an event
* subscription.
*
* @extends models['EventSubscriptionDestination']
*/
class HybridConnectionEventSubscriptionDestination extends models['EventSubscriptionDestination'] {
/**
* Create a HybridConnectionEventSubscriptionDestination.
* @member {string} [resourceId] The Azure Resource ID of an hybrid
* connection that is the destination of an event subscription.
*/
constructor() {
super();
}

/**
* Defines the metadata of HybridConnectionEventSubscriptionDestination
*
* @returns {object} metadata of HybridConnectionEventSubscriptionDestination
*
*/
mapper() {
return {
required: false,
serializedName: 'HybridConnection',
type: {
name: 'Composite',
polymorphicDiscriminator: {
serializedName: 'endpointType',
clientName: 'endpointType'
},
uberParent: 'EventSubscriptionDestination',
className: 'HybridConnectionEventSubscriptionDestination',
modelProperties: {
endpointType: {
required: true,
serializedName: 'endpointType',
isPolymorphicDiscriminator: true,
type: {
name: 'String'
}
},
resourceId: {
required: false,
serializedName: 'properties.resourceId',
type: {
name: 'String'
}
}
}
}
};
}
}

module.exports = HybridConnectionEventSubscriptionDestination;
Loading

0 comments on commit 982f736

Please sign in to comment.