langfuse_client_base/models/
ingestion_error.rs1use crate::models;
12use serde::{Deserialize, Serialize};
13
14#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize, bon::Builder)]
15pub struct IngestionError {
16 #[serde(rename = "id")]
17 pub id: String,
18 #[serde(rename = "status")]
19 pub status: i32,
20 #[serde(
21 rename = "message",
22 default,
23 with = "::serde_with::rust::double_option",
24 skip_serializing_if = "Option::is_none"
25 )]
26 pub message: Option<Option<String>>,
27 #[serde(
28 rename = "error",
29 default,
30 with = "::serde_with::rust::double_option",
31 skip_serializing_if = "Option::is_none"
32 )]
33 pub error: Option<Option<serde_json::Value>>,
34}
35
36impl IngestionError {
37 pub fn new(id: String, status: i32) -> IngestionError {
38 IngestionError {
39 id,
40 status,
41 message: None,
42 error: None,
43 }
44 }
45}