class RecombeeApiClient::UpdateMoreItems
Updates (some) property values of all the items that pass the filter.
Example: *Setting all the items that are older than a week as unavailable*
``` { "filter": "'releaseDate' < now() - 7*24*3600", "changes": {"available": false} } ```
Attributes
changes[R]
ensure_https[RW]
filter[R]
timeout[RW]
Public Class Methods
new(filter, changes)
click to toggle source
-
*Required arguments*
-
filter
-> A [ReQL](docs.recombee.com/reql.html) expression, which returns ‘true` for the items that shall be updated. -
changes
-> A dictionary where the keys are properties that shall be updated.
-
# File lib/recombee_api_client/api/update_more_items.rb, line 31 def initialize(filter, changes) @filter = filter @changes = changes @timeout = 1000 @ensure_https = false end
Public Instance Methods
body_parameters()
click to toggle source
Values of body parameters as a Hash
# File lib/recombee_api_client/api/update_more_items.rb, line 44 def body_parameters p = Hash.new p['filter'] = @filter p['changes'] = @changes p end
method()
click to toggle source
HTTP method
# File lib/recombee_api_client/api/update_more_items.rb, line 39 def method :post end
path()
click to toggle source
Relative path to the endpoint
# File lib/recombee_api_client/api/update_more_items.rb, line 59 def path "/{databaseId}/more-items/" end
query_parameters()
click to toggle source
Values of query parameters as a Hash. name of parameter => value of the parameter
# File lib/recombee_api_client/api/update_more_items.rb, line 53 def query_parameters params = {} params end