cybersource-rest-client
Version:
Node.js SDK for the CyberSource REST API
92 lines (74 loc) • 4.98 kB
JavaScript
/**
* CyberSource Merged Spec
* All CyberSource API specs merged together. These are available at https://developer.cybersource.com/api/reference/api-reference.html
*
* OpenAPI spec version: 0.0.1
*
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
*
* Swagger Codegen version: 2.4.38
*
* Do not edit the class manually.
*
*/
(function(root, factory) {
if (typeof define === 'function' && define.amd) {
// AMD. Register as an anonymous module.
define(['ApiClient'], factory);
} else if (typeof module === 'object' && module.exports) {
// CommonJS-like environments that support module.exports, like Node.
module.exports = factory(require('../ApiClient'));
} else {
// Browser globals (root is window)
if (!root.CyberSource) {
root.CyberSource = {};
}
root.CyberSource.VasV2PaymentsPost201ResponseTaxInformation = factory(root.CyberSource.ApiClient);
}
}(this, function(ApiClient) {
'use strict';
/**
* The VasV2PaymentsPost201ResponseTaxInformation model module.
* @module model/VasV2PaymentsPost201ResponseTaxInformation
* @version 0.0.1
*/
/**
* Constructs a new <code>VasV2PaymentsPost201ResponseTaxInformation</code>.
* @alias module:model/VasV2PaymentsPost201ResponseTaxInformation
* @class
*/
var exports = function() {
var _this = this;
};
/**
* Constructs a <code>VasV2PaymentsPost201ResponseTaxInformation</code> from a plain JavaScript object, optionally creating a new instance.
* Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
* @param {Object} data The plain JavaScript object bearing properties of interest.
* @param {module:model/VasV2PaymentsPost201ResponseTaxInformation} obj Optional instance to populate.
* @return {module:model/VasV2PaymentsPost201ResponseTaxInformation} The populated <code>VasV2PaymentsPost201ResponseTaxInformation</code> instance.
*/
exports.constructFromObject = function(data, obj) {
if (data) {
obj = obj || new exports();
if (data.hasOwnProperty('commitIndicator')) {
obj['commitIndicator'] = ApiClient.convertToType(data['commitIndicator'], 'Boolean');
}
if (data.hasOwnProperty('refundIndicator')) {
obj['refundIndicator'] = ApiClient.convertToType(data['refundIndicator'], 'Boolean');
}
}
return obj;
}
/**
* Indicates whether this is a committed tax transaction. For a committed tax transaction, the status in the Tax Detail Report is \"Committed.\" For an uncommitted tax transaction, the status in the Tax Detail Report is \"Uncommitted.\" Possible values: - `true`: This is a committed tax transaction. - `false` (default): This is not a committed tax transaction. A committed tax request is a tax service request that sets the status field in the Tax Detail Report to committed. The committed status indicates that the amount calculated by the tax service is included in the amount of a capture or credit. Use a void service request to cancel a committed tax request or a committed refund tax request. The void transaction is included as a separate entry in the Tax Detail Report. The value of the status field is cancelled. The value of the link ID is the request ID of the committed tax request or refund tax request that was voided. You can use the value of the link ID to reconcile your orders. Optional for U.S., Canadian, international tax, and value added taxes. For more information on Tax Detail Report features refer the [Tax Service Guide](https://developer.cybersource.com/docs/cybs/en-us/tax-calculation/developer/all/rest/tax-calculation/tax-overview.html).
* @member {Boolean} commitIndicator
*/
exports.prototype['commitIndicator'] = undefined;
/**
* Indicates whether this is a refund tax transaction. For a refund tax transaction, amounts in the Tax Detail Report will be negative. Possible values: - `true`: This is a refund tax transaction. - `false` (default): This is not a refund tax transaction. A refund tax request is a tax service request that sets the transaction type field in the Tax Detail Report to refunded and makes the reported amount negative. Tax amounts are returned as positive amounts in reply messages, but they are saved in reports as negative amounts which enables the reporting software to accurately calculate the aggregate amounts. Optional for U.S., Canadian, international tax, and value added taxes. For more information on Tax Detail Report features refer the [Tax Service Guide](https://developer.cybersource.com/docs/cybs/en-us/tax-calculation/developer/all/rest/tax-calculation/tax-overview.html).
* @member {Boolean} refundIndicator
*/
exports.prototype['refundIndicator'] = undefined;
return exports;
}));