appcenter-cli
Version:
Command line tool for Visual Studio App Center
95 lines (90 loc) • 2.21 kB
JavaScript
/*
* 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.
*/
;
/**
* Alerting webhook
*
*/
class AlertWebhook {
/**
* Create a AlertWebhook.
* @property {string} [id] The unique id (UUID) of the webhook
* @property {string} name display name of the webhook
* @property {string} url target url of the webhook
* @property {boolean} [enabled] Allows eanble/disable webhook
* @property {array} eventTypes Event types enabled for webhook
*/
constructor() {
}
/**
* Defines the metadata of AlertWebhook
*
* @returns {object} metadata of AlertWebhook
*
*/
mapper() {
return {
required: false,
serializedName: 'AlertWebhook',
type: {
name: 'Composite',
className: 'AlertWebhook',
modelProperties: {
id: {
required: false,
serializedName: 'id',
type: {
name: 'String'
}
},
name: {
required: true,
serializedName: 'name',
constraints: {
MaxLength: 512
},
type: {
name: 'String'
}
},
url: {
required: true,
serializedName: 'url',
type: {
name: 'String'
}
},
enabled: {
required: false,
serializedName: 'enabled',
type: {
name: 'Boolean'
}
},
eventTypes: {
required: true,
serializedName: 'event_types',
type: {
name: 'Sequence',
element: {
required: false,
serializedName: 'StringElementType',
type: {
name: 'String'
}
}
}
}
}
}
};
}
}
module.exports = AlertWebhook;