|
| 1 | +/** |
| 2 | + * SendinBlue API |
| 3 | + * SendinBlue provide a RESTFul API that can be used with any languages. With this API, you will be able to : - Manage your campaigns and get the statistics - Manage your contacts - Send transactional Emails and SMS - and much more... You can download our wrappers at https://github.com/orgs/sendinblue **Possible responses** | Code | Message | | :-------------: | ------------- | | 200 | OK. Successful Request | | 201 | OK. Successful Creation | | 202 | OK. Request accepted | | 204 | OK. Successful Update/Deletion | | 400 | Error. Bad Request | | 401 | Error. Authentication Needed | | 402 | Error. Not enough credit, plan upgrade needed | | 403 | Error. Permission denied | | 404 | Error. Object does not exist | | 405 | Error. Method not allowed | | 406 | Error. Not Acceptable | |
| 4 | + * |
| 5 | + * OpenAPI spec version: 3.0.0 |
| 6 | + |
| 7 | + * |
| 8 | + * NOTE: This class is auto generated by the swagger code generator program. |
| 9 | + * https://github.com/swagger-api/swagger-codegen.git |
| 10 | + * |
| 11 | + * Swagger Codegen version: 2.3.1 |
| 12 | + * |
| 13 | + * Do not edit the class manually. |
| 14 | + * |
| 15 | + */ |
| 16 | + |
| 17 | +(function(root, factory) { |
| 18 | + if (typeof define === 'function' && define.amd) { |
| 19 | + // AMD. Register as an anonymous module. |
| 20 | + define(['ApiClient'], factory); |
| 21 | + } else if (typeof module === 'object' && module.exports) { |
| 22 | + // CommonJS-like environments that support module.exports, like Node. |
| 23 | + module.exports = factory(require('../ApiClient')); |
| 24 | + } else { |
| 25 | + // Browser globals (root is window) |
| 26 | + if (!root.SibApiV3Sdk) { |
| 27 | + root.SibApiV3Sdk = {}; |
| 28 | + } |
| 29 | + root.SibApiV3Sdk.CreateDoiContact = factory(root.SibApiV3Sdk.ApiClient); |
| 30 | + } |
| 31 | +}(this, function(ApiClient) { |
| 32 | + 'use strict'; |
| 33 | + |
| 34 | + |
| 35 | + |
| 36 | + |
| 37 | + /** |
| 38 | + * The CreateDoiContact model module. |
| 39 | + * @module model/CreateDoiContact |
| 40 | + * @version 7.2.3 |
| 41 | + */ |
| 42 | + |
| 43 | + /** |
| 44 | + * Constructs a new <code>CreateDoiContact</code>. |
| 45 | + * @alias module:model/CreateDoiContact |
| 46 | + * @class |
| 47 | + * @param email {String} Email address where the confirmation email will be sent. This email address will be the identifier for all other contact attributes. |
| 48 | + * @param includeListIds {Array.<Number>} Lists under user account where contact should be added |
| 49 | + * @param templateId {Number} Id of the DOI template |
| 50 | + */ |
| 51 | + var exports = function(email, includeListIds, templateId) { |
| 52 | + var _this = this; |
| 53 | + |
| 54 | + _this['email'] = email; |
| 55 | + |
| 56 | + _this['includeListIds'] = includeListIds; |
| 57 | + |
| 58 | + _this['templateId'] = templateId; |
| 59 | + |
| 60 | + }; |
| 61 | + |
| 62 | + /** |
| 63 | + * Constructs a <code>CreateDoiContact</code> from a plain JavaScript object, optionally creating a new instance. |
| 64 | + * Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not. |
| 65 | + * @param {Object} data The plain JavaScript object bearing properties of interest. |
| 66 | + * @param {module:model/CreateDoiContact} obj Optional instance to populate. |
| 67 | + * @return {module:model/CreateDoiContact} The populated <code>CreateDoiContact</code> instance. |
| 68 | + */ |
| 69 | + exports.constructFromObject = function(data, obj) { |
| 70 | + if (data) { |
| 71 | + obj = obj || new exports(); |
| 72 | + |
| 73 | + if (data.hasOwnProperty('email')) { |
| 74 | + obj['email'] = ApiClient.convertToType(data['email'], 'String'); |
| 75 | + } |
| 76 | + if (data.hasOwnProperty('attributes')) { |
| 77 | + obj['attributes'] = ApiClient.convertToType(data['attributes'], Object); |
| 78 | + } |
| 79 | + if (data.hasOwnProperty('includeListIds')) { |
| 80 | + obj['includeListIds'] = ApiClient.convertToType(data['includeListIds'], ['Number']); |
| 81 | + } |
| 82 | + if (data.hasOwnProperty('excludeListIds')) { |
| 83 | + obj['excludeListIds'] = ApiClient.convertToType(data['excludeListIds'], ['Number']); |
| 84 | + } |
| 85 | + if (data.hasOwnProperty('templateId')) { |
| 86 | + obj['templateId'] = ApiClient.convertToType(data['templateId'], 'Number'); |
| 87 | + } |
| 88 | + if (data.hasOwnProperty('redirectionUrl')) { |
| 89 | + obj['redirectionUrl'] = ApiClient.convertToType(data['redirectionUrl'], 'String'); |
| 90 | + } |
| 91 | + } |
| 92 | + return obj; |
| 93 | + } |
| 94 | + |
| 95 | + /** |
| 96 | + * Email address where the confirmation email will be sent. This email address will be the identifier for all other contact attributes. |
| 97 | + * @member {String} email |
| 98 | + */ |
| 99 | + exports.prototype['email'] = undefined; |
| 100 | + /** |
| 101 | + * Pass the set of attributes and their values. These attributes must be present in your SendinBlue account. For eg. {"FNAME":"Elly", "LNAME":"Roger"} |
| 102 | + * @member {Object} attributes |
| 103 | + */ |
| 104 | + exports.prototype['attributes'] = undefined; |
| 105 | + /** |
| 106 | + * Lists under user account where contact should be added |
| 107 | + * @member {Array.<Number>} includeListIds |
| 108 | + */ |
| 109 | + exports.prototype['includeListIds'] = undefined; |
| 110 | + /** |
| 111 | + * Lists under user account where contact should not be added |
| 112 | + * @member {Array.<Number>} excludeListIds |
| 113 | + */ |
| 114 | + exports.prototype['excludeListIds'] = undefined; |
| 115 | + /** |
| 116 | + * Id of the DOI template |
| 117 | + * @member {Number} templateId |
| 118 | + */ |
| 119 | + exports.prototype['templateId'] = undefined; |
| 120 | + /** |
| 121 | + * URL of the web page that user will be redirected to after clicking on the double opt in URL. |
| 122 | + * @member {String} redirectionUrl |
| 123 | + */ |
| 124 | + exports.prototype['redirectionUrl'] = undefined; |
| 125 | + |
| 126 | + |
| 127 | + |
| 128 | + return exports; |
| 129 | +})); |
0 commit comments