lib/box/api.rb in box-api-0.2.1 vs lib/box/api.rb in box-api-0.2.2

- old
+ new

@@ -327,21 +327,21 @@ # # @param [String] id The id of the file to use. # @param [Hash] options The properties for the generated preview code. # See File#embed_code for a more detailed list of options. def file_embed(id, options = Hash.new) - query_rest('s_create_file_embed', { :action => :create_file_embed, :file_id => id }.merge(options)) + query_rest('s_create_file_embed', :action => :create_file_embed, :file_id => id, :params => options) end # Share an item publically, making it accessible via a share link. # # @param [String] target The type of item. # @param [String] target_id The id of the item to share. # @param [Hash] options Extra options related to notifications. Please # read the developer documentation for more details. def share_public(target, target_id, options = Hash.new) - query_rest('share_ok', { :action => :public_share, :target => target, :target_id => target_id }.merge(options)) + query_rest('share_ok', { :action => :public_share, :target => target, :target_id => target_id, :password => "", :message => "", :emails => [ "" ] }.merge(options)) end # Share an item privately, making it accessible only via email. # # @param [String] target The type of item. @@ -349,10 +349,10 @@ # @param [Array] emails The email addresses of the individuals to share with. # @param [Hash] options Extra options related to notifications. Please # read the developer documentation for more details. # def share_private(target, target_id, emails, options = Hash.new) - query_rest('private_share_ok', { :action => :private_share, :target => target, :target_id => target_id, :emails => emails }.merge(options)) + query_rest('private_share_ok', { :action => :private_share, :target => target, :target_id => target_id, :emails => emails, :message => "", :notify => "" }.merge(options)) end # Stop sharing an item publically. # # @param [String] target The type of item.