pub struct FileObject {
pub id: String,
pub object: String,
pub bytes: u64,
pub created_at: u64,
pub filename: String,
pub purpose: String,
pub status: Option<String>,
pub status_details: Option<String>,
}
Expand description
Represents a file object in OpenAI.
For example, when you upload a file via POST /v1/files
, the API responds with
this structure containing metadata about the file.
Fields§
§id: String
The ID of the file, e.g. “file-abc123”.
object: String
The object type, usually “file”.
bytes: u64
The size of the file in bytes.
created_at: u64
The time (in epoch seconds) when the file was uploaded.
filename: String
The filename you provided during upload.
purpose: String
The purpose for which the file was uploaded (e.g. “fine-tune”).
status: Option<String>
The current status of the file, e.g. “uploaded”.
status_details: Option<String>
More detailed status information, if available.
Trait Implementations§
Source§impl Debug for FileObject
impl Debug for FileObject
Source§impl<'de> Deserialize<'de> for FileObject
impl<'de> Deserialize<'de> for FileObject
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for FileObject
impl RefUnwindSafe for FileObject
impl Send for FileObject
impl Sync for FileObject
impl Unpin for FileObject
impl UnwindSafe for FileObject
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more