Class: Autorender::Models::UploadCreateParams

Inherits:
Internal::Type::BaseModel show all
Extended by:
Internal::Type::RequestParameters::Converter
Includes:
Internal::Type::RequestParameters
Defined in:
lib/autorender/models/upload_create_params.rb

Overview

Instance Attribute Summary collapse

Attributes included from Internal::Type::RequestParameters

#request_options

Instance Method Summary collapse

Methods included from Internal::Type::RequestParameters::Converter

dump_request

Methods included from Internal::Type::RequestParameters

included

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(file:, file_name:, custom_id: nil, folder: nil, metadata: nil, random_prefix: nil, tags: nil, transform: nil, webhook_url: nil, request_options: {}) ⇒ Object

Parameters:

  • file (Pathname, StringIO, IO, String, Autorender::FilePart)

    File to upload.

  • file_name (String)

    File name (e.g. product.jpg)

  • custom_id (String) (defaults to: nil)

    Custom identifier

  • folder (String) (defaults to: nil)

    Optional folder path

  • metadata (String) (defaults to: nil)

    JSON string of metadata

  • random_prefix (String) (defaults to: nil)

    true/false to append random suffix

  • tags (String) (defaults to: nil)

    Comma-separated tags

  • transform (String) (defaults to: nil)

    Transform string (w_300,h_300,c_crop,…)

  • webhook_url (String) (defaults to: nil)

    URL to notify on success

  • request_options (Autorender::RequestOptions, Hash{Symbol=>Object}) (defaults to: {})


# File 'lib/autorender/models/upload_create_params.rb', line 64

Instance Attribute Details

#custom_idString?

Custom identifier

Returns:

  • (String, nil)


26
# File 'lib/autorender/models/upload_create_params.rb', line 26

optional :custom_id, String

#filePathname, ...

File to upload.

Returns:



14
# File 'lib/autorender/models/upload_create_params.rb', line 14

required :file, Autorender::Internal::Type::FileInput

#file_nameString

File name (e.g. product.jpg)

Returns:

  • (String)


20
# File 'lib/autorender/models/upload_create_params.rb', line 20

required :file_name, String

#folderString?

Optional folder path

Returns:

  • (String, nil)


32
# File 'lib/autorender/models/upload_create_params.rb', line 32

optional :folder, String

#metadataString?

JSON string of metadata

Returns:

  • (String, nil)


38
# File 'lib/autorender/models/upload_create_params.rb', line 38

optional :metadata, String

#random_prefixString?

true/false to append random suffix

Returns:

  • (String, nil)


44
# File 'lib/autorender/models/upload_create_params.rb', line 44

optional :random_prefix, String

#tagsString?

Comma-separated tags

Returns:

  • (String, nil)


50
# File 'lib/autorender/models/upload_create_params.rb', line 50

optional :tags, String

#transformString?

Transform string (w_300,h_300,c_crop,…)

Returns:

  • (String, nil)


56
# File 'lib/autorender/models/upload_create_params.rb', line 56

optional :transform, String

#webhook_urlString?

URL to notify on success

Returns:

  • (String, nil)


62
# File 'lib/autorender/models/upload_create_params.rb', line 62

optional :webhook_url, String