Skip to content

The platform for continuously improving AI agents.

3.3 KB
Raw Blame
/* tslint:disable */
/* eslint-disable */
/**
 * Overbae API
 * Backend API for the Overclaw / Overmind platform.
 *
 * The version of the OpenAPI document: 2.0.0
 *
 *
 * 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';
import type { ModelActivationStageEnum } from './ModelActivationStageEnum';
import {
    ModelActivationStageEnumFromJSON,
    ModelActivationStageEnumFromJSONTyped,
    ModelActivationStageEnumToJSON,
    ModelActivationStageEnumToJSONTyped,
} from './ModelActivationStageEnum';

/**
 *
 * @export
 * @interface ModelActivation
 */
export interface ModelActivation {
    /**
     *
     * @type {string}
     * @memberof ModelActivation
     */
    readonly id: string;
    /**
     *
     * @type {string}
     * @memberof ModelActivation
     */
    readonly target: string | null;
    /**
     *
     * @type {ModelActivationStageEnum}
     * @memberof ModelActivation
     */
    readonly stage: ModelActivationStageEnum;
    /**
     *
     * @type {string}
     * @memberof ModelActivation
     */
    readonly failedStage: string;
    /**
     *
     * @type {string}
     * @memberof ModelActivation
     */
    readonly error: string;
    /**
     *
     * @type {Date}
     * @memberof ModelActivation
     */
    readonly startedAt: Date;
    /**
     *
     * @type {Date}
     * @memberof ModelActivation
     */
    readonly completedAt: Date | null;
}



/**
 * Check if a given object implements the ModelActivation interface.
 */
export function instanceOfModelActivation(value: object): value is ModelActivation {
    if (!('id' in value) || value['id'] === undefined) return false;
    if (!('target' in value) || value['target'] === undefined) return false;
    if (!('stage' in value) || value['stage'] === undefined) return false;
    if (!('failedStage' in value) || value['failedStage'] === undefined) return false;
    if (!('error' in value) || value['error'] === undefined) return false;
    if (!('startedAt' in value) || value['startedAt'] === undefined) return false;
    if (!('completedAt' in value) || value['completedAt'] === undefined) return false;
    return true;
}

export function ModelActivationFromJSON(json: any): ModelActivation {
    return ModelActivationFromJSONTyped(json, false);
}

export function ModelActivationFromJSONTyped(json: any, ignoreDiscriminator: boolean): ModelActivation {
    if (json == null) {
        return json;
    }
    return {

        'id': json['id'],
        'target': json['target'],
        'stage': ModelActivationStageEnumFromJSON(json['stage']),
        'failedStage': json['failed_stage'],
        'error': json['error'],
        'startedAt': (new Date(json['started_at'])),
        'completedAt': (json['completed_at'] == null ? null : new Date(json['completed_at'])),
    };
}

export function ModelActivationToJSON(json: any): ModelActivation {
    return ModelActivationToJSONTyped(json, false);
}

export function ModelActivationToJSONTyped(value?: Omit<ModelActivation, 'id'|'target'|'stage'|'failed_stage'|'error'|'started_at'|'completed_at'> | null, ignoreDiscriminator: boolean = false): any {
    if (value == null) {
        return value;
    }

    return {

    };
}