1. 1 : (function(root, factory) {
  2. 2 : if (typeof define === 'function' && define.amd) {
  3. 3 : // AMD. Register as an anonymous module.
  4. 4 : define(['ApiClient', 'models/AuditInfoVo', 'models/PaymentAuthCustomerAccountResponse', 'models/PaymentAuthCustomerResponse', 'models/PaymentAuthFundingAccountResponse', 'models/PaymentNetworkResponseVo'], factory);
  5. 5 : } else if (typeof module === 'object' && module.exports) {
  6. 6 : // CommonJS-like environments that support module.exports, like Node.
  7. 7 : module.exports = factory(require('../ApiClient'), require('./AuditInfoVo'), require('./PaymentAuthCustomerAccountResponse'), require('./PaymentAuthCustomerResponse'), require('./PaymentAuthFundingAccountResponse'), require('./PaymentNetworkResponseVo'));
  8. 8 : } else {
  9. 9 : // Browser globals (root is window)
  10. 10 : if (!root.OrbipayPaymentsapiClient) {
  11. 11 : root.OrbipayPaymentsapiClient = {};
  12. 12 : }
  13. 13 : root.OrbipayPaymentsapiClient.PaymentAuthorizationResponse = factory(root.OrbipayPaymentsapiClient.ApiClient, root.OrbipayPaymentsapiClient.AuditInfoVo, root.OrbipayPaymentsapiClient.PaymentAuthCustomerAccountResponse, root.OrbipayPaymentsapiClient.PaymentAuthCustomerResponse, root.OrbipayPaymentsapiClient.PaymentAuthFundingAccountResponse, root.OrbipayPaymentsapiClient.PaymentNetworkResponseVo);
  14. 14 : }
  15. 15 : }(this, function(ApiClient, AuditInfoVo, PaymentAuthCustomerAccountResponse, PaymentAuthCustomerResponse, PaymentAuthFundingAccountResponse, PaymentNetworkResponseVo) {
  16. 16 : 'use strict';
  17. 17 :
  18. 18 :
  19. 19 :
  20. 20 :
  21. 21 : /**
  22. 22 : * The PaymentAuthorizationResponse model module.
  23. 23 : * @module models/PaymentAuthorizationResponse
  24. 24 : */
  25. 25 :
  26. 26 : /**
  27. 27 : * <h3 style="color:red"> This class subject to change without prior notice, Please dont use this class directly. </h3>
  28. 28 :
  29. 29 : * Constructs a new <code>PaymentAuthorizationResponse</code>.
  30. 30 : * @alias module:models/PaymentAuthorizationResponse
  31. 31 : * @class
  32. 32 : */
  33. 33 : var exports = function() {
  34. 34 : var _this = this;
  35. 35 :
  36. 36 :
  37. 37 :
  38. 38 :
  39. 39 :
  40. 40 :
  41. 41 :
  42. 42 :
  43. 43 :
  44. 44 :
  45. 45 :
  46. 46 :
  47. 47 :
  48. 48 :
  49. 49 :
  50. 50 :
  51. 51 :
  52. 52 :
  53. 53 : };
  54. 54 :
  55. 55 : /**
  56. 56 : * Constructs a <code>PaymentAuthorizationResponse</code> from a plain JavaScript object, optionally creating a new instance.
  57. 57 : * Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
  58. 58 : * @param {Object} data The plain JavaScript object bearing properties of interest.
  59. 59 : * @param {module:models/PaymentAuthorizationResponse} obj Optional instance to populate.
  60. 60 : * @return {module:models/PaymentAuthorizationResponse} The populated <code>PaymentAuthorizationResponse</code> instance.
  61. 61 : */
  62. 62 : exports.constructFromObject = function(data, obj) {
  63. 63 : if (data) {
  64. 64 : obj = obj || new exports();
  65. 65 :
  66. 66 : if (data.hasOwnProperty('payment_auth_reference')) {
  67. 67 : obj['payment_auth_reference'] = ApiClient.convertToType(data['payment_auth_reference'], 'String');
  68. 68 : }
  69. 69 : if (data.hasOwnProperty('id')) {
  70. 70 : obj['id'] = ApiClient.convertToType(data['id'], 'String');
  71. 71 : }
  72. 72 : if (data.hasOwnProperty('url')) {
  73. 73 : obj['url'] = ApiClient.convertToType(data['url'], 'String');
  74. 74 : }
  75. 75 : if (data.hasOwnProperty('auth_amount')) {
  76. 76 : obj['auth_amount'] = ApiClient.convertToType(data['auth_amount'], 'String');
  77. 77 : }
  78. 78 : if (data.hasOwnProperty('status')) {
  79. 79 : obj['status'] = ApiClient.convertToType(data['status'], 'String');
  80. 80 : }
  81. 81 : if (data.hasOwnProperty('payment_method')) {
  82. 82 : obj['payment_method'] = ApiClient.convertToType(data['payment_method'], 'String');
  83. 83 : }
  84. 84 : if (data.hasOwnProperty('currency_code3d')) {
  85. 85 : obj['currency_code3d'] = ApiClient.convertToType(data['currency_code3d'], 'String');
  86. 86 : }
  87. 87 : if (data.hasOwnProperty('card_cvv_number')) {
  88. 88 : obj['card_cvv_number'] = ApiClient.convertToType(data['card_cvv_number'], 'String');
  89. 89 : }
  90. 90 : if (data.hasOwnProperty('entry_time')) {
  91. 91 : obj['entry_time'] = ApiClient.convertToType(data['entry_time'], 'String');
  92. 92 : }
  93. 93 : if (data.hasOwnProperty('captured_time')) {
  94. 94 : obj['captured_time'] = ApiClient.convertToType(data['captured_time'], 'String');
  95. 95 : }
  96. 96 : if (data.hasOwnProperty('comments')) {
  97. 97 : obj['comments'] = ApiClient.convertToType(data['comments'], 'String');
  98. 98 : }
  99. 99 : if (data.hasOwnProperty('custom_fields')) {
  100. 100 : obj['custom_fields'] = ApiClient.convertToType(data['custom_fields'], {'String': 'String'});
  101. 101 : }
  102. 102 : if (data.hasOwnProperty('customer')) {
  103. 103 : obj['customer'] = PaymentAuthCustomerResponse.constructFromObject(data['customer']);
  104. 104 : }
  105. 105 : if (data.hasOwnProperty('funding_account')) {
  106. 106 : obj['funding_account'] = PaymentAuthFundingAccountResponse.constructFromObject(data['funding_account']);
  107. 107 : }
  108. 108 : if (data.hasOwnProperty('customer_account')) {
  109. 109 : obj['customer_account'] = PaymentAuthCustomerAccountResponse.constructFromObject(data['customer_account']);
  110. 110 : }
  111. 111 : if (data.hasOwnProperty('payment_network_response')) {
  112. 112 : obj['payment_network_response'] = PaymentNetworkResponseVo.constructFromObject(data['payment_network_response']);
  113. 113 : }
  114. 114 : if (data.hasOwnProperty('audit_info')) {
  115. 115 : obj['audit_info'] = AuditInfoVo.constructFromObject(data['audit_info']);
  116. 116 : }
  117. 117 : }
  118. 118 : return obj;
  119. 119 : };
  120. 120 :
  121. 121 : /**
  122. 122 : * The unique identifier in the client system for the payment.
  123. 123 : * @member {String} payment_auth_reference
  124. 124 : */
  125. 125 : exports.prototype['payment_auth_reference'] = undefined;
  126. 126 : /**
  127. 127 : * The unique identifier assigned by EBPP to the payment authorization.
  128. 128 : * @member {String} id
  129. 129 : */
  130. 130 : exports.prototype['id'] = undefined;
  131. 131 : /**
  132. 132 : * This URL fetches the details of payment authorization.
  133. 133 : * @member {String} url
  134. 134 : */
  135. 135 : exports.prototype['url'] = undefined;
  136. 136 : /**
  137. 137 : * The amount being authorized.
  138. 138 : * @member {String} auth_amount
  139. 139 : */
  140. 140 : exports.prototype['auth_amount'] = undefined;
  141. 141 : /**
  142. 142 : * The status of the payment.
  143. 143 : * @member {module:models/PaymentAuthorizationResponse.StatusEnum} status
  144. 144 : */
  145. 145 : exports.prototype['status'] = undefined;
  146. 146 : /**
  147. 147 : * The fulfillment method for the payment authorization.
  148. 148 : * @member {module:models/PaymentAuthorizationResponse.PaymentMethodEnum} payment_method
  149. 149 : */
  150. 150 : exports.prototype['payment_method'] = undefined;
  151. 151 : /**
  152. 152 : * The three-letter currency code in the ISO4217 format, in uppercase, for the card account. It must be a currency supported by EBPP. This defaults to USD.
  153. 153 : * @member {String} currency_code3d
  154. 154 : */
  155. 155 : exports.prototype['currency_code3d'] = undefined;
  156. 156 : /**
  157. 157 : * This is never returned by EBPP. This needs to be passed to EBPP when making or editing a payment with a card funding account.
  158. 158 : * @member {String} card_cvv_number
  159. 159 : */
  160. 160 : exports.prototype['card_cvv_number'] = undefined;
  161. 161 : /**
  162. 162 : * The date on which the payment authorization created in UTC timestamp, with ISO8601 format. For e.g., 2019-08-13T09:21:34.359+0000.
  163. 163 : * @member {String} entry_time
  164. 164 : */
  165. 165 : exports.prototype['entry_time'] = undefined;
  166. 166 : /**
  167. 167 : * The date on which the payment authorization is captured in UTC timestamp, with ISO8601 format. For e.g., 2019-08-13T09:21:34.359+0000..
  168. 168 : * @member {String} captured_time
  169. 169 : */
  170. 170 : exports.prototype['captured_time'] = undefined;
  171. 171 : /**
  172. 172 : * Comments that can be used to recollect the operation performed on the resource object. API clients need to ensure that no sensitive information is passed in the memo. Alacriti (EBPP) is not responsible for the security of any sensitive information that may be passed as part of the memo.
  173. 173 : * @member {String} comments
  174. 174 : */
  175. 175 : exports.prototype['comments'] = undefined;
  176. 176 : /**
  177. 177 : * The additional information or meta-information that EBPP can accept, maintain and transmit back to the client. The custom fields need to be configured with EBPP before they can be accepted. EBPP would reject custom fields that are not pre-configured. Please contact <a href = \"mailto: support@billerpayments.com\">support@billerpayments.com</a> for more information on configuring and using custom fields. Only the custom fields enabled for the client, in EBPP, would be accepted in the requests.
  178. 178 : * @member {Object.<String, String>} custom_fields
  179. 179 : */
  180. 180 : exports.prototype['custom_fields'] = undefined;
  181. 181 : /**
  182. 182 : * @member {module:models/PaymentAuthCustomerResponse} customer
  183. 183 : */
  184. 184 : exports.prototype['customer'] = undefined;
  185. 185 : /**
  186. 186 : * @member {module:models/PaymentAuthFundingAccountResponse} funding_account
  187. 187 : */
  188. 188 : exports.prototype['funding_account'] = undefined;
  189. 189 : /**
  190. 190 : * @member {module:models/PaymentAuthCustomerAccountResponse} customer_account
  191. 191 : */
  192. 192 : exports.prototype['customer_account'] = undefined;
  193. 193 : /**
  194. 194 : * @member {module:models/PaymentNetworkResponseVo} payment_network_response
  195. 195 : */
  196. 196 : exports.prototype['payment_network_response'] = undefined;
  197. 197 : /**
  198. 198 : * @member {module:models/AuditInfoVo} audit_info
  199. 199 : */
  200. 200 : exports.prototype['audit_info'] = undefined;
  201. 201 :
  202. 202 :
  203. 203 : /**
  204. 204 : * Allowed values for the <code>status</code> property.
  205. 205 : * @enum {String}
  206. 206 : * @readonly
  207. 207 : */
  208. 208 : exports.StatusEnum = {
  209. 209 : /**
  210. 210 : * value: "approved"
  211. 211 : * @const
  212. 212 : */
  213. 213 : "approved": "approved",
  214. 214 : /**
  215. 215 : * value: "declined"
  216. 216 : * @const
  217. 217 : */
  218. 218 : "declined": "declined",
  219. 219 : /**
  220. 220 : * value: "error"
  221. 221 : * @const
  222. 222 : */
  223. 223 : "error": "error",
  224. 224 : /**
  225. 225 : * value: "cancelled"
  226. 226 : * @const
  227. 227 : */
  228. 228 : "cancelled": "cancelled",
  229. 229 : /**
  230. 230 : * value: "expired"
  231. 231 : * @const
  232. 232 : */
  233. 233 : "expired": "expired",
  234. 234 : /**
  235. 235 : * value: "reversed"
  236. 236 : * @const
  237. 237 : */
  238. 238 : "reversed": "reversed",
  239. 239 : /**
  240. 240 : * value: "processed"
  241. 241 : * @const
  242. 242 : */
  243. 243 : "processed": "processed" };
  244. 244 :
  245. 245 : /**
  246. 246 : * Allowed values for the <code>payment_method</code> property.
  247. 247 : * @enum {String}
  248. 248 : * @readonly
  249. 249 : */
  250. 250 : exports.PaymentMethodEnum = {
  251. 251 : /**
  252. 252 : * value: "voyager_fleet"
  253. 253 : * @const
  254. 254 : */
  255. 255 : "voyager_fleet": "voyager_fleet" };
  256. 256 :
  257. 257 :
  258. 258 : return exports;
  259. 259 : }));
  260. 260 :
  261. 261 :