@getopenpay/client
Version:
OpenPay API TypeScript SDK
57 lines (56 loc) • 2.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.instanceOfCheckoutProcessorsPreferencesInput = instanceOfCheckoutProcessorsPreferencesInput;
exports.CheckoutProcessorsPreferencesInputFromJSON = CheckoutProcessorsPreferencesInputFromJSON;
exports.CheckoutProcessorsPreferencesInputFromJSONTyped = CheckoutProcessorsPreferencesInputFromJSONTyped;
exports.CheckoutProcessorsPreferencesInputToJSON = CheckoutProcessorsPreferencesInputToJSON;
exports.CheckoutProcessorsPreferencesInputToJSONTyped = CheckoutProcessorsPreferencesInputToJSONTyped;
const PaymentProviderType_1 = require("./PaymentProviderType");
const ProcessorProviderPair_1 = require("./ProcessorProviderPair");
/**
* Check if a given object implements the CheckoutProcessorsPreferencesInput interface.
*/
function instanceOfCheckoutProcessorsPreferencesInput(value) {
return true;
}
function CheckoutProcessorsPreferencesInputFromJSON(json) {
return CheckoutProcessorsPreferencesInputFromJSONTyped(json, false);
}
function CheckoutProcessorsPreferencesInputFromJSONTyped(json, ignoreDiscriminator) {
if (json == null) {
return json;
}
return {
'filterProviders': json['filter_providers'] == null ? undefined : (json['filter_providers'].map(PaymentProviderType_1.PaymentProviderTypeFromJSON)),
'idsWhitelist': json['ids_whitelist'] == null ? undefined : json['ids_whitelist'],
'namesWhitelist': json['names_whitelist'] == null ? undefined : json['names_whitelist'],
'processorProviderPairsWhitelist': json['processor_provider_pairs_whitelist'] == null ? undefined : (json['processor_provider_pairs_whitelist'].map(ProcessorProviderPair_1.ProcessorProviderPairFromJSON)),
};
}
function CheckoutProcessorsPreferencesInputToJSON(json) {
return CheckoutProcessorsPreferencesInputToJSONTyped(json, false);
}
function CheckoutProcessorsPreferencesInputToJSONTyped(value, ignoreDiscriminator = false) {
if (value == null) {
return value;
}
return {
'filter_providers': value['filterProviders'] == null ? undefined : (value['filterProviders'].map(PaymentProviderType_1.PaymentProviderTypeToJSON)),
'ids_whitelist': value['idsWhitelist'],
'names_whitelist': value['namesWhitelist'],
'processor_provider_pairs_whitelist': value['processorProviderPairsWhitelist'] == null ? undefined : (value['processorProviderPairsWhitelist'].map(ProcessorProviderPair_1.ProcessorProviderPairToJSON)),
};
}