instance method url_for_direct_upload

Ruby on Rails 6.1.7.10

Since v5.2.8.1

Available in: v5.2.8.1 v6.0.6 v6.1.7.10 v7.0.10 v7.1.6 v7.2.3 v8.0.4 v8.1.2

Signature

url_for_direct_upload(key, expires_in:, content_type:, content_length:, checksum:)

Returns a signed, temporary URL that a direct upload file can be PUT to on the key. The URL will be valid for the amount of seconds specified in expires_in. You must also provide the content_type, content_length, and checksum of the file that will be uploaded. All these attributes will be validated by the service upon upload.

Parameters

key req
expires_in keyreq
content_type keyreq
content_length keyreq
checksum keyreq
Source
# File activestorage/lib/active_storage/service.rb, line 131
    def url_for_direct_upload(key, expires_in:, content_type:, content_length:, checksum:)
      raise NotImplementedError
    end

Defined in activestorage/lib/active_storage/service.rb line 131 · View on GitHub · Improve this page · Find usages on GitHub

Defined in ActiveStorage::Service

Type at least 2 characters to search.

↑↓ navigate · open · esc close