objectiveai_sdk/functions/profiles/
response.rs1use crate::functions;
4use schemars::JsonSchema;
5use serde::{Deserialize, Serialize};
6
7#[derive(Debug, Clone, Serialize, Deserialize, JsonSchema)]
9#[schemars(rename = "functions.profiles.ListProfileResponse")]
10pub struct ListProfileResponse {
11 pub data: Vec<ListProfileItem>,
13}
14
15pub type ListProfileItem = crate::RemotePath;
17
18#[derive(Debug, Clone, PartialEq, Serialize, Deserialize, JsonSchema)]
19#[schemars(rename = "functions.profiles.GetProfileResponse")]
20pub struct GetProfileResponse {
21 #[serde(flatten)]
22 #[schemars(schema_with = "crate::flatten_schema::<crate::RemotePath>")]
23 pub path: crate::RemotePath,
24 #[serde(flatten)]
25 #[schemars(
26 schema_with = "crate::flatten_schema::<functions::RemoteProfile>"
27 )]
28 pub inner: functions::RemoteProfile,
29}
30
31#[derive(Debug, Clone, Serialize, Deserialize, JsonSchema)]
33#[schemars(rename = "functions.profiles.UsageProfileResponse")]
34pub struct UsageProfileResponse {
35 pub requests: u64,
37 pub completion_tokens: u64,
39 pub prompt_tokens: u64,
41 #[serde(deserialize_with = "crate::serde_util::decimal")]
43 #[schemars(with = "f64")]
44 pub total_cost: rust_decimal::Decimal,
45}