@getopenpay/client
Version:
OpenPay API TypeScript SDK
59 lines (58 loc) • 2.09 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.instanceOfCreateProductFamilyRequest = instanceOfCreateProductFamilyRequest;
exports.CreateProductFamilyRequestFromJSON = CreateProductFamilyRequestFromJSON;
exports.CreateProductFamilyRequestFromJSONTyped = CreateProductFamilyRequestFromJSONTyped;
exports.CreateProductFamilyRequestToJSON = CreateProductFamilyRequestToJSON;
exports.CreateProductFamilyRequestToJSONTyped = CreateProductFamilyRequestToJSONTyped;
/**
* Check if a given object implements the CreateProductFamilyRequest interface.
*/
function instanceOfCreateProductFamilyRequest(value) {
if (!('name' in value) || value['name'] === undefined)
return false;
if (!('products' in value) || value['products'] === undefined)
return false;
return true;
}
function CreateProductFamilyRequestFromJSON(json) {
return CreateProductFamilyRequestFromJSONTyped(json, false);
}
function CreateProductFamilyRequestFromJSONTyped(json, ignoreDiscriminator) {
if (json == null) {
return json;
}
return {
'description': json['description'] == null ? undefined : json['description'],
'hierarchy': json['hierarchy'] == null ? undefined : json['hierarchy'],
'name': json['name'],
'products': json['products'],
};
}
function CreateProductFamilyRequestToJSON(json) {
return CreateProductFamilyRequestToJSONTyped(json, false);
}
function CreateProductFamilyRequestToJSONTyped(value, ignoreDiscriminator = false) {
if (value == null) {
return value;
}
return {
'description': value['description'],
'hierarchy': value['hierarchy'],
'name': value['name'],
'products': value['products'],
};
}