Skip to content

The platform for continuously improving AI agents.

2.6 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 { RootSpanList } from './RootSpanList';
import {
    RootSpanListFromJSON,
    RootSpanListFromJSONTyped,
    RootSpanListToJSON,
    RootSpanListToJSONTyped,
} from './RootSpanList';

/**
 *
 * @export
 * @interface PaginatedRootSpanListList
 */
export interface PaginatedRootSpanListList {
    /**
     *
     * @type {number}
     * @memberof PaginatedRootSpanListList
     */
    count: number;
    /**
     *
     * @type {string}
     * @memberof PaginatedRootSpanListList
     */
    next?: string | null;
    /**
     *
     * @type {string}
     * @memberof PaginatedRootSpanListList
     */
    previous?: string | null;
    /**
     *
     * @type {Array<RootSpanList>}
     * @memberof PaginatedRootSpanListList
     */
    results: Array<RootSpanList>;
}

/**
 * Check if a given object implements the PaginatedRootSpanListList interface.
 */
export function instanceOfPaginatedRootSpanListList(value: object): value is PaginatedRootSpanListList {
    if (!('count' in value) || value['count'] === undefined) return false;
    if (!('results' in value) || value['results'] === undefined) return false;
    return true;
}

export function PaginatedRootSpanListListFromJSON(json: any): PaginatedRootSpanListList {
    return PaginatedRootSpanListListFromJSONTyped(json, false);
}

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

        'count': json['count'],
        'next': json['next'] == null ? undefined : json['next'],
        'previous': json['previous'] == null ? undefined : json['previous'],
        'results': ((json['results'] as Array<any>).map(RootSpanListFromJSON)),
    };
}

export function PaginatedRootSpanListListToJSON(json: any): PaginatedRootSpanListList {
    return PaginatedRootSpanListListToJSONTyped(json, false);
}

export function PaginatedRootSpanListListToJSONTyped(value?: PaginatedRootSpanListList | null, ignoreDiscriminator: boolean = false): any {
    if (value == null) {
        return value;
    }

    return {

        'count': value['count'],
        'next': value['next'],
        'previous': value['previous'],
        'results': ((value['results'] as Array<any>).map(RootSpanListToJSON)),
    };
}