Sha256: 0459a2a22916e3b7b4906b2388f978fa308ad3dc877b3c17ab7162a9f5e24fec

Contents?: true

Size: 405 Bytes

Versions: 37

Compression:

Stored size: 405 Bytes

Contents

module Bearcat
  class Client < Footrest::Client
    module CanvasFiles
      def upload_file(api_path, file_path, params = {})
        declare_response = declare_file(api_path, file_params(file_path).merge(params))
        confirmation_url = post_file(declare_response['upload_url'], declare_response['upload_params'], file_path)
        confirm_file_upload(confirmation_url)
      end
    end
  end
end

Version data entries

37 entries across 37 versions & 1 rubygems

Version Path
bearcat-1.5.13 lib/bearcat/client/canvas_files.rb
bearcat-1.5.12 lib/bearcat/client/canvas_files.rb
bearcat-1.5.11 lib/bearcat/client/canvas_files.rb
bearcat-1.5.10 lib/bearcat/client/canvas_files.rb
bearcat-1.5.9 lib/bearcat/client/canvas_files.rb
bearcat-1.5.8 lib/bearcat/client/canvas_files.rb
bearcat-1.5.7 lib/bearcat/client/canvas_files.rb
bearcat-1.5.6 lib/bearcat/client/canvas_files.rb
bearcat-1.5.5 lib/bearcat/client/canvas_files.rb
bearcat-1.5.4 lib/bearcat/client/canvas_files.rb
bearcat-1.5.3 lib/bearcat/client/canvas_files.rb
bearcat-1.5.2 lib/bearcat/client/canvas_files.rb
bearcat-1.5.0 lib/bearcat/client/canvas_files.rb
bearcat-1.5.0.beta4 lib/bearcat/client/canvas_files.rb
bearcat-1.5.0.beta3 lib/bearcat/client/canvas_files.rb
bearcat-1.5.0.beta2 lib/bearcat/client/canvas_files.rb
bearcat-1.5.0.beta1 lib/bearcat/client/canvas_files.rb