/* tslint:disable */
/* eslint-disable */
/**
 * AskNews API
 * AskNews API
 *
 * The version of the OpenAPI document: 0.18.6
 * Contact: contact@emergentmethods.ai
 *
 * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
 * https://openapi-generator.tech
 * Do not edit the class manually.
 */

import { mapValues } from '../runtime';
/**
 * 
 * @export
 * @interface CreateDeepNewsRequestMessage1
 */
export interface CreateDeepNewsRequestMessage1 {
    /**
     * 
     * @type {string}
     * @memberof CreateDeepNewsRequestMessage1
     */
    role: string;
    /**
     * 
     * @type {string}
     * @memberof CreateDeepNewsRequestMessage1
     */
    content: string;
    /**
     * 
     * @type {string}
     * @memberof CreateDeepNewsRequestMessage1
     */
    name?: string;
    /**
     * 
     * @type {object}
     * @memberof CreateDeepNewsRequestMessage1
     */
    functionCall?: object;
}

/**
 * Check if a given object implements the CreateDeepNewsRequestMessage1 interface.
 */
export function instanceOfCreateDeepNewsRequestMessage1(value: object): boolean {
    if (!('role' in value)) return false;
    if (!('content' in value)) return false;
    return true;
}

export function CreateDeepNewsRequestMessage1FromJSON(json: any): CreateDeepNewsRequestMessage1 {
    return CreateDeepNewsRequestMessage1FromJSONTyped(json, false);
}

export function CreateDeepNewsRequestMessage1FromJSONTyped(json: any, ignoreDiscriminator: boolean): CreateDeepNewsRequestMessage1 {
    if (json == null) {
        return json;
    }
    return {
        
        'role': json['role'],
        'content': json['content'],
        'name': json['name'] == null ? undefined : json['name'],
        'functionCall': json['function_call'] == null ? undefined : json['function_call'],
    };
}

export function CreateDeepNewsRequestMessage1ToJSON(value?: CreateDeepNewsRequestMessage1 | null): any {
    if (value == null) {
        return value;
    }
    return {
        
        'role': value['role'],
        'content': value['content'],
        'name': value['name'],
        'function_call': value['functionCall'],
    };
}

