/* tslint:disable */
/* eslint-disable */
/**
 * UCX Proxy
 * A single use API for the UCX Proxy.
 *
 * The version of the OpenAPI document: 0.0.12
 * Contact: customersuccess@equisoft.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 { AuthenticationConfigSchemaFromJSON, AuthenticationConfigSchemaToJSON, } from './AuthenticationConfigSchema';
import { UserSourceStatusFromJSON, UserSourceStatusToJSON, } from './UserSourceStatus';
/**
 * Check if a given object implements the UserSourceAuthenticationSchema interface.
 */
export function instanceOfUserSourceAuthenticationSchema(value) {
    if (!('userId' in value) || value['userId'] === undefined)
        return false;
    if (!('sourceKey' in value) || value['sourceKey'] === undefined)
        return false;
    if (!('authenticationConfig' in value) || value['authenticationConfig'] === undefined)
        return false;
    if (!('dateModified' in value) || value['dateModified'] === undefined)
        return false;
    if (!('status' in value) || value['status'] === undefined)
        return false;
    return true;
}
export function UserSourceAuthenticationSchemaFromJSON(json) {
    return UserSourceAuthenticationSchemaFromJSONTyped(json, false);
}
export function UserSourceAuthenticationSchemaFromJSONTyped(json, ignoreDiscriminator) {
    if (json == null) {
        return json;
    }
    return {
        'userId': json['userId'],
        'sourceKey': json['sourceKey'],
        'authenticationConfig': AuthenticationConfigSchemaFromJSON(json['authenticationConfig']),
        'dateModified': (new Date(json['dateModified'])),
        'status': UserSourceStatusFromJSON(json['status']),
    };
}
export function UserSourceAuthenticationSchemaToJSON(json) {
    return UserSourceAuthenticationSchemaToJSONTyped(json, false);
}
export function UserSourceAuthenticationSchemaToJSONTyped(value, ignoreDiscriminator = false) {
    if (value == null) {
        return value;
    }
    return {
        'userId': value['userId'],
        'sourceKey': value['sourceKey'],
        'authenticationConfig': AuthenticationConfigSchemaToJSON(value['authenticationConfig']),
        'dateModified': value['dateModified'].toISOString(),
        'status': UserSourceStatusToJSON(value['status']),
    };
}
