Skip to main content

Retrieve File

GET 

/files/:file_id

Returns information about a specific file.

Request

Path Parameters

    file_id stringrequired

    The ID of the file to retrieve.

Responses

OK, returns the file object.

Schema

    id stringrequired

    The file identifier, of the form file-api-..., which can be referenced in chat completion requests.

    object stringrequired

    Possible values: [file]

    The object type, which is always file.

    bytes integerrequired

    The size of the file in bytes.

    created_at integerrequired

    The Unix timestamp (in seconds) of when the file was created.

    filename stringrequired

    The name of the file.

    purpose stringrequired

    Possible values: [user_data]

    The intended purpose of the file.

    expires_at integer

    The Unix timestamp (in seconds) of when the file expires. Only present when an expiration was set at upload time.

Loading...