Record Class AnthropicApi.FileMetadata
java.lang.Object
java.lang.Record
org.springframework.ai.anthropic.api.AnthropicApi.FileMetadata
- Record Components:
id- Unique file identifier (format: file_*)filename- Original filename with extensionsize- File size in bytesmimeType- MIME type (e.g., application/vnd.openxmlformats-officedocument.spreadsheetml.sheet)createdAt- When the file was created (ISO 8601 timestamp)expiresAt- When the file will be automatically deleted (ISO 8601 timestamp)
- Enclosing class:
AnthropicApi
public static record AnthropicApi.FileMetadata(String id, String filename, Long size, String mimeType, String createdAt, String expiresAt)
extends Record
Metadata for a file generated by Claude Skills or uploaded via Files API.
Files expire after a certain period (typically 24 hours).
- Since:
- 1.0.0
- Author:
- Christian Tzolov, Mariusz Bernacki, Thomas Vitale, Jihoon Kim, Alexandros Pappas, Jonghoon Park, Claudio Silva Junior, Filip Hrisafov, Soby Chacko, Austin Dase
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of thecreatedAtrecord component.final booleanIndicates whether some other object is "equal to" this one.Returns the value of theexpiresAtrecord component.filename()Returns the value of thefilenamerecord component.final inthashCode()Returns a hash code value for this object.id()Returns the value of theidrecord component.mimeType()Returns the value of themimeTyperecord component.size()Returns the value of thesizerecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
FileMetadata
public FileMetadata(String id, String filename, Long size, String mimeType, String createdAt, String expiresAt) Creates an instance of aFileMetadatarecord class.- Parameters:
id- the value for theidrecord componentfilename- the value for thefilenamerecord componentsize- the value for thesizerecord componentmimeType- the value for themimeTyperecord componentcreatedAt- the value for thecreatedAtrecord componentexpiresAt- the value for theexpiresAtrecord component
-
-
Method Details
-
toString
-
hashCode
-
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object). -
id
-
filename
-
size
-
mimeType
-
createdAt
-
expiresAt
-