Class: WhopSDK::Models::FileRetrieveResponse

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/whop_sdk/models/file_retrieve_response.rb

Overview

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from Internal::Type::BaseModel

==, #==, #[], coerce, #deconstruct_keys, #deep_to_h, dump, fields, hash, #hash, inherited, inspect, #inspect, known_fields, optional, recursively_to_h, required, #to_h, #to_json, #to_s, to_sorbet_type, #to_yaml

Methods included from Internal::Type::Converter

#coerce, coerce, #dump, dump, #inspect, inspect, meta_info, new_coerce_state, type_info

Methods included from Internal::Util::SorbetRuntimeSupport

#const_missing, #define_sorbet_constant!, #sorbet_constant_defined?, #to_sorbet_type, to_sorbet_type

Constructor Details

#initialize(id:, content_type:, filename:, size:, upload_status:, url:) ⇒ Object

Some parameter documentations has been truncated, see WhopSDK::Models::FileRetrieveResponse for more details.

A file that has been uploaded or is pending upload.

Parameters:

  • id (String)

    The unique identifier for the file.

  • content_type (String, nil)

    The MIME type of the uploaded file (e.g., image/jpeg, video/mp4, audio/mpeg).

  • filename (String, nil)

    The original filename of the uploaded file, including its file extension.

  • size (String, nil)

    The file size in bytes. Null if the file has not finished uploading.

  • upload_status (Symbol, WhopSDK::Models::UploadStatus)

    The current upload status of the file (e.g., pending, ready).

  • url (String, nil)

    The CDN URL for accessing the file. Null if the file has not finished uploading.



# File 'lib/whop_sdk/models/file_retrieve_response.rb', line 43

Instance Attribute Details

#content_typeString?

The MIME type of the uploaded file (e.g., image/jpeg, video/mp4, audio/mpeg).

Returns:

  • (String, nil)


17
# File 'lib/whop_sdk/models/file_retrieve_response.rb', line 17

required :content_type, String, nil?: true

#filenameString?

The original filename of the uploaded file, including its file extension.

Returns:

  • (String, nil)


23
# File 'lib/whop_sdk/models/file_retrieve_response.rb', line 23

required :filename, String, nil?: true

#idString

The unique identifier for the file.

Returns:

  • (String)


11
# File 'lib/whop_sdk/models/file_retrieve_response.rb', line 11

required :id, String

#sizeString?

The file size in bytes. Null if the file has not finished uploading.

Returns:

  • (String, nil)


29
# File 'lib/whop_sdk/models/file_retrieve_response.rb', line 29

required :size, String, nil?: true

#upload_statusSymbol, WhopSDK::Models::UploadStatus

The current upload status of the file (e.g., pending, ready).

Returns:



35
# File 'lib/whop_sdk/models/file_retrieve_response.rb', line 35

required :upload_status, enum: -> { WhopSDK::UploadStatus }

#urlString?

The CDN URL for accessing the file. Null if the file has not finished uploading.

Returns:

  • (String, nil)


41
# File 'lib/whop_sdk/models/file_retrieve_response.rb', line 41

required :url, String, nil?: true