"use strict";
/* tslint:disable */
/* eslint-disable */
/**
 * authentik
 * Making authentication simple.
 *
 * The version of the OpenAPI document: 2025.10.0-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.instanceOfPatchedPromptRequest = instanceOfPatchedPromptRequest;
exports.PatchedPromptRequestFromJSON = PatchedPromptRequestFromJSON;
exports.PatchedPromptRequestFromJSONTyped = PatchedPromptRequestFromJSONTyped;
exports.PatchedPromptRequestToJSON = PatchedPromptRequestToJSON;
exports.PatchedPromptRequestToJSONTyped = PatchedPromptRequestToJSONTyped;
const StageRequest_1 = require("./StageRequest");
const PromptTypeEnum_1 = require("./PromptTypeEnum");
/**
 * Check if a given object implements the PatchedPromptRequest interface.
 */
function instanceOfPatchedPromptRequest(value) {
    return true;
}
function PatchedPromptRequestFromJSON(json) {
    return PatchedPromptRequestFromJSONTyped(json, false);
}
function PatchedPromptRequestFromJSONTyped(json, ignoreDiscriminator) {
    if (json == null) {
        return json;
    }
    return {
        'name': json['name'] == null ? undefined : json['name'],
        'fieldKey': json['field_key'] == null ? undefined : json['field_key'],
        'label': json['label'] == null ? undefined : json['label'],
        'type': json['type'] == null ? undefined : (0, PromptTypeEnum_1.PromptTypeEnumFromJSON)(json['type']),
        'required': json['required'] == null ? undefined : json['required'],
        'placeholder': json['placeholder'] == null ? undefined : json['placeholder'],
        'initialValue': json['initial_value'] == null ? undefined : json['initial_value'],
        'order': json['order'] == null ? undefined : json['order'],
        'promptstageSet': json['promptstage_set'] == null ? undefined : (json['promptstage_set'].map(StageRequest_1.StageRequestFromJSON)),
        'subText': json['sub_text'] == null ? undefined : json['sub_text'],
        'placeholderExpression': json['placeholder_expression'] == null ? undefined : json['placeholder_expression'],
        'initialValueExpression': json['initial_value_expression'] == null ? undefined : json['initial_value_expression'],
    };
}
function PatchedPromptRequestToJSON(json) {
    return PatchedPromptRequestToJSONTyped(json, false);
}
function PatchedPromptRequestToJSONTyped(value, ignoreDiscriminator = false) {
    if (value == null) {
        return value;
    }
    return {
        'name': value['name'],
        'field_key': value['fieldKey'],
        'label': value['label'],
        'type': (0, PromptTypeEnum_1.PromptTypeEnumToJSON)(value['type']),
        'required': value['required'],
        'placeholder': value['placeholder'],
        'initial_value': value['initialValue'],
        'order': value['order'],
        'promptstage_set': value['promptstageSet'] == null ? undefined : (value['promptstageSet'].map(StageRequest_1.StageRequestToJSON)),
        'sub_text': value['subText'],
        'placeholder_expression': value['placeholderExpression'],
        'initial_value_expression': value['initialValueExpression'],
    };
}
//# sourceMappingURL=PatchedPromptRequest.js.map