"use strict";
/* tslint:disable */
/* eslint-disable */
/**
 * authentik
 * Making authentication simple.
 *
 * The version of the OpenAPI document: 2026.2.2-rc1
 * Contact: hello@goauthentik.io
 *
 * 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.instanceOfTOTPDevice = instanceOfTOTPDevice;
exports.TOTPDeviceFromJSON = TOTPDeviceFromJSON;
exports.TOTPDeviceFromJSONTyped = TOTPDeviceFromJSONTyped;
exports.TOTPDeviceToJSON = TOTPDeviceToJSON;
exports.TOTPDeviceToJSONTyped = TOTPDeviceToJSONTyped;
const PartialUser_1 = require("./PartialUser");
/**
 * Check if a given object implements the TOTPDevice interface.
 */
function instanceOfTOTPDevice(value) {
    if (!('name' in value) || value['name'] === undefined)
        return false;
    if (!('pk' in value) || value['pk'] === undefined)
        return false;
    if (!('user' in value) || value['user'] === undefined)
        return false;
    return true;
}
function TOTPDeviceFromJSON(json) {
    return TOTPDeviceFromJSONTyped(json, false);
}
function TOTPDeviceFromJSONTyped(json, ignoreDiscriminator) {
    if (json == null) {
        return json;
    }
    return {
        'name': json['name'],
        'pk': json['pk'],
        'user': (0, PartialUser_1.PartialUserFromJSON)(json['user']),
    };
}
function TOTPDeviceToJSON(json) {
    return TOTPDeviceToJSONTyped(json, false);
}
function TOTPDeviceToJSONTyped(value, ignoreDiscriminator = false) {
    if (value == null) {
        return value;
    }
    return {
        'name': value['name'],
    };
}
//# sourceMappingURL=TOTPDevice.js.map