/* tslint:disable */
/* eslint-disable */
/**
 * Paystack
 * The OpenAPI specification of the Paystack API that merchants and developers can harness to build financial solutions in Africa.
 *
 * The version of the Paystack Node library: 1.0.0
 * Contact: techsupport@paystack.com
 *
 * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
 * https://openapi-generator.tech
 * Do not edit the class manually.
 */

import { exists, mapValues } from '../runtime';
/**
 * 
 * @export
 * @interface SplitSubaccounts
 */
export interface SplitSubaccounts {
    /**
     * Subaccount code of the customer or partner
     * @type {string}
     * @memberof SplitSubaccounts
     */
    subaccount?: string;
    /**
     * The percentage or flat quota of the customer or partner
     * @type {string}
     * @memberof SplitSubaccounts
     */
    share?: string;
}

export function SplitSubaccountsFromJSON(json: any): SplitSubaccounts {
    return SplitSubaccountsFromJSONTyped(json, false);
}

export function SplitSubaccountsFromJSONTyped(json: any, ignoreDiscriminator: boolean): SplitSubaccounts {
    if ((json === undefined) || (json === null)) {
        return json;
    }
    return {
        
        'subaccount': !exists(json, 'subaccount') ? undefined : json['subaccount'],
        'share': !exists(json, 'share') ? undefined : json['share'],
    };
}

export function SplitSubaccountsToJSON(value?: SplitSubaccounts | null): any {
    if (value === undefined) {
        return undefined;
    }
    if (value === null) {
        return null;
    }
    return {
        
        'subaccount': value.subaccount,
        'share': value.share,
    };
}


