Sha256: 5782fbe4a5beb80980c321cdbf2f29698476512127a919cf19b88a0d77198ee9

Contents?: true

Size: 310 Bytes

Versions: 21

Compression:

Stored size: 310 Bytes

Contents

module DiscourseApi
  module API
    module Uploads
      def upload_file(args)
        args = API.params(args)
                  .optional(:file, :url, :user_id)
                  .default(type: 'composer', synchronous: true)
                  .to_h
        post('/uploads', args)
      end
    end
  end
end

Version data entries

21 entries across 21 versions & 1 rubygems

Version Path
discourse_api-0.34.0 lib/discourse_api/api/uploads.rb
discourse_api-0.33.0 lib/discourse_api/api/uploads.rb
discourse_api-0.32.0 lib/discourse_api/api/uploads.rb
discourse_api-0.31.0 lib/discourse_api/api/uploads.rb
discourse_api-0.30.0 lib/discourse_api/api/uploads.rb
discourse_api-0.29.0 lib/discourse_api/api/uploads.rb
discourse_api-0.28.1 lib/discourse_api/api/uploads.rb
discourse_api-0.28.0 lib/discourse_api/api/uploads.rb
discourse_api-0.27.0 lib/discourse_api/api/uploads.rb
discourse_api-0.26.0 lib/discourse_api/api/uploads.rb
discourse_api-0.25.0 lib/discourse_api/api/uploads.rb
discourse_api-0.24.0 lib/discourse_api/api/uploads.rb
discourse_api-0.23.1 lib/discourse_api/api/uploads.rb
discourse_api-0.23.0 lib/discourse_api/api/uploads.rb
discourse_api-0.22.0 lib/discourse_api/api/uploads.rb
discourse_api-0.20.1 lib/discourse_api/api/uploads.rb
discourse_api-0.20.0 lib/discourse_api/api/uploads.rb
discourse_api-0.19.0 lib/discourse_api/api/uploads.rb
discourse_api-0.18.0 lib/discourse_api/api/uploads.rb
discourse_api-0.17.0 lib/discourse_api/api/uploads.rb