@getopenpay/client
Version:
OpenPay API TypeScript SDK
54 lines (53 loc) • 1.83 kB
JavaScript
;
/* tslint:disable */
/* eslint-disable */
/**
* OpenPay API
* super charge your subscription management.
*
* The version of the OpenAPI document: 1.2.1
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
Object.defineProperty(exports, "__esModule", { value: true });
exports.instanceOfCustomerTotalAmount = instanceOfCustomerTotalAmount;
exports.CustomerTotalAmountFromJSON = CustomerTotalAmountFromJSON;
exports.CustomerTotalAmountFromJSONTyped = CustomerTotalAmountFromJSONTyped;
exports.CustomerTotalAmountToJSON = CustomerTotalAmountToJSON;
exports.CustomerTotalAmountToJSONTyped = CustomerTotalAmountToJSONTyped;
const CurrencyEnum_1 = require("./CurrencyEnum");
/**
* Check if a given object implements the CustomerTotalAmount interface.
*/
function instanceOfCustomerTotalAmount(value) {
if (!('currency' in value) || value['currency'] === undefined)
return false;
return true;
}
function CustomerTotalAmountFromJSON(json) {
return CustomerTotalAmountFromJSONTyped(json, false);
}
function CustomerTotalAmountFromJSONTyped(json, ignoreDiscriminator) {
if (json == null) {
return json;
}
return {
'amountAtom': json['amount_atom'] == null ? undefined : json['amount_atom'],
'currency': (0, CurrencyEnum_1.CurrencyEnumFromJSON)(json['currency']),
};
}
function CustomerTotalAmountToJSON(json) {
return CustomerTotalAmountToJSONTyped(json, false);
}
function CustomerTotalAmountToJSONTyped(value, ignoreDiscriminator = false) {
if (value == null) {
return value;
}
return {
'amount_atom': value['amountAtom'],
'currency': (0, CurrencyEnum_1.CurrencyEnumToJSON)(value['currency']),
};
}