/* tslint:disable */
/* eslint-disable */
/**
 * Jellyfin API
 * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
 *
 * The version of the OpenAPI document: 10.8.9
 * 
 *
 * 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';
/**
 * The authenticate user by name request body.
 * @export
 * @interface AuthenticateUserByName
 */
export interface AuthenticateUserByName {
    /**
     * Gets or sets the username.
     * @type {string}
     * @memberof AuthenticateUserByName
     */
    username?: string | null;
    /**
     * Gets or sets the plain text password.
     * @type {string}
     * @memberof AuthenticateUserByName
     */
    pw?: string | null;
    /**
     * Gets or sets the sha1-hashed password.
     * @type {string}
     * @memberof AuthenticateUserByName
     * @deprecated
     */
    password?: string | null;
}

/**
 * Check if a given object implements the AuthenticateUserByName interface.
 */
export function instanceOfAuthenticateUserByName(value: object): boolean {
    let isInstance = true;

    return isInstance;
}

export function AuthenticateUserByNameFromJSON(json: any): AuthenticateUserByName {
    return AuthenticateUserByNameFromJSONTyped(json, false);
}

export function AuthenticateUserByNameFromJSONTyped(json: any, ignoreDiscriminator: boolean): AuthenticateUserByName {
    if ((json === undefined) || (json === null)) {
        return json;
    }
    return {
        
        'username': !exists(json, 'Username') ? undefined : json['Username'],
        'pw': !exists(json, 'Pw') ? undefined : json['Pw'],
        'password': !exists(json, 'Password') ? undefined : json['Password'],
    };
}

export function AuthenticateUserByNameToJSON(value?: AuthenticateUserByName | null): any {
    if (value === undefined) {
        return undefined;
    }
    if (value === null) {
        return null;
    }
    return {
        
        'Username': value.username,
        'Pw': value.pw,
        'Password': value.password,
    };
}

