Langfuse JS/TS SDKs
    Preparing search index...

    Interface ObservationsView

    interface ObservationsView {
        calculatedInputCost?: number;
        calculatedOutputCost?: number;
        calculatedTotalCost?: number;
        completionStartTime?: string;
        costDetails?: Record<string, number>;
        endTime?: string;
        environment?: string;
        id: string;
        input?: unknown;
        inputPrice?: number;
        latency?: number;
        level: ObservationLevel;
        metadata?: unknown;
        model?: string;
        modelId?: string;
        modelParameters?: Record<string, MapValue>;
        name?: string;
        output?: unknown;
        outputPrice?: number;
        parentObservationId?: string;
        promptId?: string;
        promptName?: string;
        promptVersion?: number;
        startTime: string;
        statusMessage?: string;
        timeToFirstToken?: number;
        totalPrice?: number;
        traceId?: string;
        type: string;
        usage?: Usage;
        usageDetails?: Record<string, number>;
        version?: string;
    }

    Hierarchy (View Summary)

    Index

    Properties

    calculatedInputCost?: number

    (Deprecated. Use usageDetails and costDetails instead.) The calculated cost of the input in USD

    calculatedOutputCost?: number

    (Deprecated. Use usageDetails and costDetails instead.) The calculated cost of the output in USD

    calculatedTotalCost?: number

    (Deprecated. Use usageDetails and costDetails instead.) The calculated total cost in USD

    completionStartTime?: string

    The completion start time of the observation

    costDetails?: Record<string, number>

    The cost details of the observation. Key is the name of the cost metric, value is the cost in USD. The total key is the sum of all (non-total) cost metrics or the total value ingested.

    endTime?: string

    The end time of the observation.

    environment?: string

    The environment from which this observation originated. Can be any lowercase alphanumeric string with hyphens and underscores that does not start with 'langfuse'.

    id: string

    The unique identifier of the observation

    input?: unknown

    The input data of the observation

    inputPrice?: number

    The price of the input in USD

    latency?: number

    The latency in seconds.

    The level of the observation

    metadata?: unknown

    Additional metadata of the observation

    model?: string

    The model used for the observation

    modelId?: string

    The unique identifier of the model

    modelParameters?: Record<string, MapValue>

    The parameters of the model used for the observation

    name?: string

    The name of the observation

    output?: unknown

    The output data of the observation

    outputPrice?: number

    The price of the output in USD.

    parentObservationId?: string

    The parent observation ID

    promptId?: string

    The prompt ID associated with the observation

    promptName?: string

    The name of the prompt associated with the observation

    promptVersion?: number

    The version of the prompt associated with the observation

    startTime: string

    The start time of the observation

    statusMessage?: string

    The status message of the observation

    timeToFirstToken?: number

    The time to the first token in seconds

    totalPrice?: number

    The total price in USD.

    traceId?: string

    The trace ID associated with the observation

    type: string

    The type of the observation

    usage?: Usage

    (Deprecated. Use usageDetails and costDetails instead.) The usage data of the observation

    usageDetails?: Record<string, number>

    The usage details of the observation. Key is the name of the usage metric, value is the number of units consumed. The total key is the sum of all (non-total) usage metrics or the total value ingested.

    version?: string

    The version of the observation