recombee_api_client 5.1.0 → 6.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/recombee_api_client/api/add_bookmark.rb +26 -26
- data/lib/recombee_api_client/api/add_cart_addition.rb +28 -28
- data/lib/recombee_api_client/api/add_detail_view.rb +32 -28
- data/lib/recombee_api_client/api/add_item.rb +15 -18
- data/lib/recombee_api_client/api/add_item_property.rb +34 -35
- data/lib/recombee_api_client/api/add_manual_reql_segment.rb +26 -27
- data/lib/recombee_api_client/api/add_purchase.rb +29 -29
- data/lib/recombee_api_client/api/add_rating.rb +27 -27
- data/lib/recombee_api_client/api/add_search_synonym.rb +29 -30
- data/lib/recombee_api_client/api/add_series.rb +20 -21
- data/lib/recombee_api_client/api/add_user.rb +14 -17
- data/lib/recombee_api_client/api/add_user_property.rb +30 -31
- data/lib/recombee_api_client/api/batch.rb +12 -16
- data/lib/recombee_api_client/api/composite_recommendation.rb +132 -0
- data/lib/recombee_api_client/api/create_auto_reql_segmentation.rb +29 -30
- data/lib/recombee_api_client/api/create_manual_reql_segmentation.rb +27 -28
- data/lib/recombee_api_client/api/create_property_based_segmentation.rb +30 -31
- data/lib/recombee_api_client/api/delete_all_search_synonyms.rb +15 -19
- data/lib/recombee_api_client/api/delete_bookmark.rb +21 -22
- data/lib/recombee_api_client/api/delete_cart_addition.rb +21 -22
- data/lib/recombee_api_client/api/delete_detail_view.rb +21 -22
- data/lib/recombee_api_client/api/delete_item.rb +16 -19
- data/lib/recombee_api_client/api/delete_item_property.rb +15 -18
- data/lib/recombee_api_client/api/delete_manual_reql_segment.rb +16 -19
- data/lib/recombee_api_client/api/delete_more_items.rb +18 -19
- data/lib/recombee_api_client/api/delete_purchase.rb +21 -22
- data/lib/recombee_api_client/api/delete_rating.rb +21 -22
- data/lib/recombee_api_client/api/delete_search_synonym.rb +15 -18
- data/lib/recombee_api_client/api/delete_segmentation.rb +15 -18
- data/lib/recombee_api_client/api/delete_series.rb +21 -22
- data/lib/recombee_api_client/api/delete_user.rb +15 -18
- data/lib/recombee_api_client/api/delete_user_property.rb +15 -18
- data/lib/recombee_api_client/api/delete_view_portion.rb +21 -22
- data/lib/recombee_api_client/api/get_item_property_info.rb +14 -17
- data/lib/recombee_api_client/api/get_item_values.rb +15 -18
- data/lib/recombee_api_client/api/get_segmentation.rb +15 -18
- data/lib/recombee_api_client/api/get_user_property_info.rb +15 -18
- data/lib/recombee_api_client/api/get_user_values.rb +15 -18
- data/lib/recombee_api_client/api/insert_to_series.rb +23 -24
- data/lib/recombee_api_client/api/list_item_bookmarks.rb +16 -19
- data/lib/recombee_api_client/api/list_item_cart_additions.rb +16 -19
- data/lib/recombee_api_client/api/list_item_detail_views.rb +16 -19
- data/lib/recombee_api_client/api/list_item_properties.rb +15 -19
- data/lib/recombee_api_client/api/list_item_purchases.rb +16 -19
- data/lib/recombee_api_client/api/list_item_ratings.rb +16 -19
- data/lib/recombee_api_client/api/list_item_view_portions.rb +16 -19
- data/lib/recombee_api_client/api/list_items.rb +62 -62
- data/lib/recombee_api_client/api/list_scenarios.rb +15 -19
- data/lib/recombee_api_client/api/list_search_synonyms.rb +20 -21
- data/lib/recombee_api_client/api/list_segmentations.rb +16 -17
- data/lib/recombee_api_client/api/list_series.rb +15 -19
- data/lib/recombee_api_client/api/list_series_items.rb +15 -18
- data/lib/recombee_api_client/api/list_user_bookmarks.rb +15 -18
- data/lib/recombee_api_client/api/list_user_cart_additions.rb +15 -18
- data/lib/recombee_api_client/api/list_user_detail_views.rb +15 -18
- data/lib/recombee_api_client/api/list_user_properties.rb +15 -19
- data/lib/recombee_api_client/api/list_user_purchases.rb +15 -18
- data/lib/recombee_api_client/api/list_user_ratings.rb +15 -18
- data/lib/recombee_api_client/api/list_user_view_portions.rb +15 -18
- data/lib/recombee_api_client/api/list_users.rb +56 -56
- data/lib/recombee_api_client/api/merge_users.rb +24 -25
- data/lib/recombee_api_client/api/recommend_item_segments_to_item.rb +69 -68
- data/lib/recombee_api_client/api/recommend_item_segments_to_item_segment.rb +70 -69
- data/lib/recombee_api_client/api/recommend_item_segments_to_user.rb +51 -50
- data/lib/recombee_api_client/api/recommend_items_to_item.rb +185 -139
- data/lib/recombee_api_client/api/recommend_items_to_item_segment.rb +181 -138
- data/lib/recombee_api_client/api/recommend_items_to_user.rb +165 -122
- data/lib/recombee_api_client/api/recommend_next_items.rb +24 -25
- data/lib/recombee_api_client/api/recommend_users_to_item.rb +151 -105
- data/lib/recombee_api_client/api/recommend_users_to_user.rb +154 -111
- data/lib/recombee_api_client/api/remove_from_series.rb +17 -18
- data/lib/recombee_api_client/api/request.rb +1 -1
- data/lib/recombee_api_client/api/reset_database.rb +15 -19
- data/lib/recombee_api_client/api/search_item_segments.rb +52 -51
- data/lib/recombee_api_client/api/search_items.rb +157 -114
- data/lib/recombee_api_client/api/set_item_values.rb +28 -29
- data/lib/recombee_api_client/api/set_user_values.rb +21 -22
- data/lib/recombee_api_client/api/set_values.rb +28 -28
- data/lib/recombee_api_client/api/set_view_portion.rb +37 -30
- data/lib/recombee_api_client/api/update_auto_reql_segmentation.rb +26 -27
- data/lib/recombee_api_client/api/update_manual_reql_segment.rb +25 -26
- data/lib/recombee_api_client/api/update_manual_reql_segmentation.rb +24 -25
- data/lib/recombee_api_client/api/update_more_items.rb +19 -20
- data/lib/recombee_api_client/api/update_property_based_segmentation.rb +26 -27
- data/lib/recombee_api_client/errors.rb +2 -5
- data/lib/recombee_api_client/inputs/composite_recommendation_stage_parameters.rb +240 -0
- data/lib/recombee_api_client/inputs/input.rb +9 -0
- data/lib/recombee_api_client/inputs/logic.rb +45 -0
- data/lib/recombee_api_client/utils/hash_normalizer.rb +21 -0
- data/lib/recombee_api_client/version.rb +1 -1
- data/lib/recombee_api_client.rb +40 -35
- data/recombee_api_client.gemspec +2 -3
- metadata +14 -10
- data/lib/recombee_api_client/api/hash_normalizer.rb +0 -21
|
@@ -5,55 +5,54 @@
|
|
|
5
5
|
module RecombeeApiClient
|
|
6
6
|
require_relative 'request'
|
|
7
7
|
require_relative '../errors'
|
|
8
|
-
|
|
8
|
+
|
|
9
9
|
##
|
|
10
|
-
#Gives the list of synonyms defined in the database
|
|
10
|
+
# Gives the list of synonyms defined in the database.#
|
|
11
11
|
class ListSearchSynonyms < ApiRequest
|
|
12
12
|
attr_reader :count, :offset
|
|
13
|
-
attr_accessor :timeout
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
#
|
|
13
|
+
attr_accessor :timeout, :ensure_https
|
|
14
|
+
|
|
15
|
+
##
|
|
16
|
+
#
|
|
17
|
+
# * *Optional arguments (given as hash optional)*
|
|
18
|
+
# - +count+ -> The number of synonyms to be listed.
|
|
19
|
+
# - +offset+ -> Specifies the number of synonyms to skip (ordered by `term`).
|
|
20
|
+
#
|
|
22
21
|
def initialize(optional = {})
|
|
23
|
-
optional =
|
|
22
|
+
optional = normalize_hash_to_camel_case(optional)
|
|
24
23
|
@count = optional['count']
|
|
25
24
|
@offset = optional['offset']
|
|
26
25
|
@optional = optional
|
|
27
|
-
@timeout =
|
|
26
|
+
@timeout = 100_000
|
|
28
27
|
@ensure_https = false
|
|
29
28
|
@optional.each do |par, _|
|
|
30
|
-
|
|
29
|
+
raise UnknownOptionalParameter.new(par) unless %w[count offset].include? par
|
|
31
30
|
end
|
|
32
31
|
end
|
|
33
|
-
|
|
32
|
+
|
|
34
33
|
# HTTP method
|
|
35
34
|
def method
|
|
36
35
|
:get
|
|
37
36
|
end
|
|
38
|
-
|
|
37
|
+
|
|
39
38
|
# Values of body parameters as a Hash
|
|
40
39
|
def body_parameters
|
|
41
|
-
|
|
42
|
-
p
|
|
40
|
+
{}
|
|
43
41
|
end
|
|
44
|
-
|
|
42
|
+
|
|
45
43
|
# Values of query parameters as a Hash.
|
|
46
44
|
# name of parameter => value of the parameter
|
|
47
45
|
def query_parameters
|
|
48
46
|
params = {}
|
|
49
47
|
params['count'] = @optional['count'] if @optional['count']
|
|
50
48
|
params['offset'] = @optional['offset'] if @optional['offset']
|
|
49
|
+
|
|
51
50
|
params
|
|
52
51
|
end
|
|
53
|
-
|
|
52
|
+
|
|
54
53
|
# Relative path to the endpoint
|
|
55
54
|
def path
|
|
56
|
-
|
|
55
|
+
'/{databaseId}/synonyms/items/'
|
|
57
56
|
end
|
|
58
57
|
end
|
|
59
58
|
end
|
|
@@ -5,47 +5,46 @@
|
|
|
5
5
|
module RecombeeApiClient
|
|
6
6
|
require_relative 'request'
|
|
7
7
|
require_relative '../errors'
|
|
8
|
-
|
|
8
|
+
|
|
9
9
|
##
|
|
10
|
-
#Return all existing items Segmentations.
|
|
10
|
+
# Return all existing items Segmentations.
|
|
11
11
|
#
|
|
12
12
|
class ListSegmentations < ApiRequest
|
|
13
13
|
attr_reader :source_type
|
|
14
|
-
attr_accessor :timeout
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
#
|
|
14
|
+
attr_accessor :timeout, :ensure_https
|
|
15
|
+
|
|
16
|
+
##
|
|
17
|
+
# * *Required arguments*
|
|
18
|
+
# - +source_type+ -> List Segmentations based on a particular type of data. Currently only `items` are supported.
|
|
19
|
+
#
|
|
21
20
|
def initialize(source_type)
|
|
22
21
|
@source_type = source_type
|
|
23
|
-
@timeout =
|
|
22
|
+
@timeout = 10_000
|
|
24
23
|
@ensure_https = false
|
|
25
24
|
end
|
|
26
|
-
|
|
25
|
+
|
|
27
26
|
# HTTP method
|
|
28
27
|
def method
|
|
29
28
|
:get
|
|
30
29
|
end
|
|
31
|
-
|
|
30
|
+
|
|
32
31
|
# Values of body parameters as a Hash
|
|
33
32
|
def body_parameters
|
|
34
|
-
|
|
35
|
-
p
|
|
33
|
+
{}
|
|
36
34
|
end
|
|
37
|
-
|
|
35
|
+
|
|
38
36
|
# Values of query parameters as a Hash.
|
|
39
37
|
# name of parameter => value of the parameter
|
|
40
38
|
def query_parameters
|
|
41
39
|
params = {}
|
|
42
40
|
params['sourceType'] = @source_type
|
|
41
|
+
|
|
43
42
|
params
|
|
44
43
|
end
|
|
45
|
-
|
|
44
|
+
|
|
46
45
|
# Relative path to the endpoint
|
|
47
46
|
def path
|
|
48
|
-
|
|
47
|
+
'/{databaseId}/segmentations/list/'
|
|
49
48
|
end
|
|
50
49
|
end
|
|
51
50
|
end
|
|
@@ -5,42 +5,38 @@
|
|
|
5
5
|
module RecombeeApiClient
|
|
6
6
|
require_relative 'request'
|
|
7
7
|
require_relative '../errors'
|
|
8
|
-
|
|
8
|
+
|
|
9
9
|
##
|
|
10
|
-
#Gets the list of all the series currently present in the database
|
|
10
|
+
# Gets the list of all the series currently present in the database.#
|
|
11
11
|
class ListSeries < ApiRequest
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
def initialize()
|
|
19
|
-
@timeout = 100000
|
|
12
|
+
attr_accessor :timeout, :ensure_https
|
|
13
|
+
|
|
14
|
+
##
|
|
15
|
+
#
|
|
16
|
+
def initialize
|
|
17
|
+
@timeout = 100_000
|
|
20
18
|
@ensure_https = false
|
|
21
19
|
end
|
|
22
|
-
|
|
20
|
+
|
|
23
21
|
# HTTP method
|
|
24
22
|
def method
|
|
25
23
|
:get
|
|
26
24
|
end
|
|
27
|
-
|
|
25
|
+
|
|
28
26
|
# Values of body parameters as a Hash
|
|
29
27
|
def body_parameters
|
|
30
|
-
|
|
31
|
-
p
|
|
28
|
+
{}
|
|
32
29
|
end
|
|
33
|
-
|
|
30
|
+
|
|
34
31
|
# Values of query parameters as a Hash.
|
|
35
32
|
# name of parameter => value of the parameter
|
|
36
33
|
def query_parameters
|
|
37
|
-
|
|
38
|
-
params
|
|
34
|
+
{}
|
|
39
35
|
end
|
|
40
|
-
|
|
36
|
+
|
|
41
37
|
# Relative path to the endpoint
|
|
42
38
|
def path
|
|
43
|
-
|
|
39
|
+
'/{databaseId}/series/list/'
|
|
44
40
|
end
|
|
45
41
|
end
|
|
46
42
|
end
|
|
@@ -5,42 +5,39 @@
|
|
|
5
5
|
module RecombeeApiClient
|
|
6
6
|
require_relative 'request'
|
|
7
7
|
require_relative '../errors'
|
|
8
|
-
|
|
8
|
+
|
|
9
9
|
##
|
|
10
|
-
#Lists all the items present in the given series, sorted according to their time index values
|
|
10
|
+
# Lists all the items present in the given series, sorted according to their time index values.#
|
|
11
11
|
class ListSeriesItems < ApiRequest
|
|
12
12
|
attr_reader :series_id
|
|
13
|
-
attr_accessor :timeout
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
#
|
|
13
|
+
attr_accessor :timeout, :ensure_https
|
|
14
|
+
|
|
15
|
+
##
|
|
16
|
+
# * *Required arguments*
|
|
17
|
+
# - +series_id+ -> ID of the series whose items are to be listed.
|
|
18
|
+
#
|
|
20
19
|
def initialize(series_id)
|
|
21
20
|
@series_id = series_id
|
|
22
|
-
@timeout =
|
|
21
|
+
@timeout = 100_000
|
|
23
22
|
@ensure_https = false
|
|
24
23
|
end
|
|
25
|
-
|
|
24
|
+
|
|
26
25
|
# HTTP method
|
|
27
26
|
def method
|
|
28
27
|
:get
|
|
29
28
|
end
|
|
30
|
-
|
|
29
|
+
|
|
31
30
|
# Values of body parameters as a Hash
|
|
32
31
|
def body_parameters
|
|
33
|
-
|
|
34
|
-
p
|
|
32
|
+
{}
|
|
35
33
|
end
|
|
36
|
-
|
|
34
|
+
|
|
37
35
|
# Values of query parameters as a Hash.
|
|
38
36
|
# name of parameter => value of the parameter
|
|
39
37
|
def query_parameters
|
|
40
|
-
|
|
41
|
-
params
|
|
38
|
+
{}
|
|
42
39
|
end
|
|
43
|
-
|
|
40
|
+
|
|
44
41
|
# Relative path to the endpoint
|
|
45
42
|
def path
|
|
46
43
|
"/{databaseId}/series/#{@series_id}/items/"
|
|
@@ -5,42 +5,39 @@
|
|
|
5
5
|
module RecombeeApiClient
|
|
6
6
|
require_relative 'request'
|
|
7
7
|
require_relative '../errors'
|
|
8
|
-
|
|
8
|
+
|
|
9
9
|
##
|
|
10
|
-
#Lists all the bookmarks ever made by the given user
|
|
10
|
+
# Lists all the bookmarks ever made by the given user.#
|
|
11
11
|
class ListUserBookmarks < ApiRequest
|
|
12
12
|
attr_reader :user_id
|
|
13
|
-
attr_accessor :timeout
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
#
|
|
13
|
+
attr_accessor :timeout, :ensure_https
|
|
14
|
+
|
|
15
|
+
##
|
|
16
|
+
# * *Required arguments*
|
|
17
|
+
# - +user_id+ -> ID of the user whose bookmarks are to be listed.
|
|
18
|
+
#
|
|
20
19
|
def initialize(user_id)
|
|
21
20
|
@user_id = user_id
|
|
22
|
-
@timeout =
|
|
21
|
+
@timeout = 100_000
|
|
23
22
|
@ensure_https = false
|
|
24
23
|
end
|
|
25
|
-
|
|
24
|
+
|
|
26
25
|
# HTTP method
|
|
27
26
|
def method
|
|
28
27
|
:get
|
|
29
28
|
end
|
|
30
|
-
|
|
29
|
+
|
|
31
30
|
# Values of body parameters as a Hash
|
|
32
31
|
def body_parameters
|
|
33
|
-
|
|
34
|
-
p
|
|
32
|
+
{}
|
|
35
33
|
end
|
|
36
|
-
|
|
34
|
+
|
|
37
35
|
# Values of query parameters as a Hash.
|
|
38
36
|
# name of parameter => value of the parameter
|
|
39
37
|
def query_parameters
|
|
40
|
-
|
|
41
|
-
params
|
|
38
|
+
{}
|
|
42
39
|
end
|
|
43
|
-
|
|
40
|
+
|
|
44
41
|
# Relative path to the endpoint
|
|
45
42
|
def path
|
|
46
43
|
"/{databaseId}/users/#{@user_id}/bookmarks/"
|
|
@@ -5,42 +5,39 @@
|
|
|
5
5
|
module RecombeeApiClient
|
|
6
6
|
require_relative 'request'
|
|
7
7
|
require_relative '../errors'
|
|
8
|
-
|
|
8
|
+
|
|
9
9
|
##
|
|
10
|
-
#Lists all the cart additions ever made by the given user
|
|
10
|
+
# Lists all the cart additions ever made by the given user.#
|
|
11
11
|
class ListUserCartAdditions < ApiRequest
|
|
12
12
|
attr_reader :user_id
|
|
13
|
-
attr_accessor :timeout
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
#
|
|
13
|
+
attr_accessor :timeout, :ensure_https
|
|
14
|
+
|
|
15
|
+
##
|
|
16
|
+
# * *Required arguments*
|
|
17
|
+
# - +user_id+ -> ID of the user whose cart additions are to be listed.
|
|
18
|
+
#
|
|
20
19
|
def initialize(user_id)
|
|
21
20
|
@user_id = user_id
|
|
22
|
-
@timeout =
|
|
21
|
+
@timeout = 100_000
|
|
23
22
|
@ensure_https = false
|
|
24
23
|
end
|
|
25
|
-
|
|
24
|
+
|
|
26
25
|
# HTTP method
|
|
27
26
|
def method
|
|
28
27
|
:get
|
|
29
28
|
end
|
|
30
|
-
|
|
29
|
+
|
|
31
30
|
# Values of body parameters as a Hash
|
|
32
31
|
def body_parameters
|
|
33
|
-
|
|
34
|
-
p
|
|
32
|
+
{}
|
|
35
33
|
end
|
|
36
|
-
|
|
34
|
+
|
|
37
35
|
# Values of query parameters as a Hash.
|
|
38
36
|
# name of parameter => value of the parameter
|
|
39
37
|
def query_parameters
|
|
40
|
-
|
|
41
|
-
params
|
|
38
|
+
{}
|
|
42
39
|
end
|
|
43
|
-
|
|
40
|
+
|
|
44
41
|
# Relative path to the endpoint
|
|
45
42
|
def path
|
|
46
43
|
"/{databaseId}/users/#{@user_id}/cartadditions/"
|
|
@@ -5,42 +5,39 @@
|
|
|
5
5
|
module RecombeeApiClient
|
|
6
6
|
require_relative 'request'
|
|
7
7
|
require_relative '../errors'
|
|
8
|
-
|
|
8
|
+
|
|
9
9
|
##
|
|
10
|
-
#Lists all the detail views of different items ever made by the given user
|
|
10
|
+
# Lists all the detail views of different items ever made by the given user.#
|
|
11
11
|
class ListUserDetailViews < ApiRequest
|
|
12
12
|
attr_reader :user_id
|
|
13
|
-
attr_accessor :timeout
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
#
|
|
13
|
+
attr_accessor :timeout, :ensure_https
|
|
14
|
+
|
|
15
|
+
##
|
|
16
|
+
# * *Required arguments*
|
|
17
|
+
# - +user_id+ -> ID of the user whose detail views are to be listed.
|
|
18
|
+
#
|
|
20
19
|
def initialize(user_id)
|
|
21
20
|
@user_id = user_id
|
|
22
|
-
@timeout =
|
|
21
|
+
@timeout = 100_000
|
|
23
22
|
@ensure_https = false
|
|
24
23
|
end
|
|
25
|
-
|
|
24
|
+
|
|
26
25
|
# HTTP method
|
|
27
26
|
def method
|
|
28
27
|
:get
|
|
29
28
|
end
|
|
30
|
-
|
|
29
|
+
|
|
31
30
|
# Values of body parameters as a Hash
|
|
32
31
|
def body_parameters
|
|
33
|
-
|
|
34
|
-
p
|
|
32
|
+
{}
|
|
35
33
|
end
|
|
36
|
-
|
|
34
|
+
|
|
37
35
|
# Values of query parameters as a Hash.
|
|
38
36
|
# name of parameter => value of the parameter
|
|
39
37
|
def query_parameters
|
|
40
|
-
|
|
41
|
-
params
|
|
38
|
+
{}
|
|
42
39
|
end
|
|
43
|
-
|
|
40
|
+
|
|
44
41
|
# Relative path to the endpoint
|
|
45
42
|
def path
|
|
46
43
|
"/{databaseId}/users/#{@user_id}/detailviews/"
|
|
@@ -5,43 +5,39 @@
|
|
|
5
5
|
module RecombeeApiClient
|
|
6
6
|
require_relative 'request'
|
|
7
7
|
require_relative '../errors'
|
|
8
|
-
|
|
8
|
+
|
|
9
9
|
##
|
|
10
|
-
#Gets the list of all the user properties in your database.
|
|
10
|
+
# Gets the list of all the user properties in your database.
|
|
11
11
|
#
|
|
12
12
|
class ListUserProperties < ApiRequest
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
def initialize()
|
|
20
|
-
@timeout = 100000
|
|
13
|
+
attr_accessor :timeout, :ensure_https
|
|
14
|
+
|
|
15
|
+
##
|
|
16
|
+
#
|
|
17
|
+
def initialize
|
|
18
|
+
@timeout = 100_000
|
|
21
19
|
@ensure_https = false
|
|
22
20
|
end
|
|
23
|
-
|
|
21
|
+
|
|
24
22
|
# HTTP method
|
|
25
23
|
def method
|
|
26
24
|
:get
|
|
27
25
|
end
|
|
28
|
-
|
|
26
|
+
|
|
29
27
|
# Values of body parameters as a Hash
|
|
30
28
|
def body_parameters
|
|
31
|
-
|
|
32
|
-
p
|
|
29
|
+
{}
|
|
33
30
|
end
|
|
34
|
-
|
|
31
|
+
|
|
35
32
|
# Values of query parameters as a Hash.
|
|
36
33
|
# name of parameter => value of the parameter
|
|
37
34
|
def query_parameters
|
|
38
|
-
|
|
39
|
-
params
|
|
35
|
+
{}
|
|
40
36
|
end
|
|
41
|
-
|
|
37
|
+
|
|
42
38
|
# Relative path to the endpoint
|
|
43
39
|
def path
|
|
44
|
-
|
|
40
|
+
'/{databaseId}/users/properties/list/'
|
|
45
41
|
end
|
|
46
42
|
end
|
|
47
43
|
end
|
|
@@ -5,42 +5,39 @@
|
|
|
5
5
|
module RecombeeApiClient
|
|
6
6
|
require_relative 'request'
|
|
7
7
|
require_relative '../errors'
|
|
8
|
-
|
|
8
|
+
|
|
9
9
|
##
|
|
10
|
-
#Lists all the purchases ever made by the given user
|
|
10
|
+
# Lists all the purchases ever made by the given user.#
|
|
11
11
|
class ListUserPurchases < ApiRequest
|
|
12
12
|
attr_reader :user_id
|
|
13
|
-
attr_accessor :timeout
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
#
|
|
13
|
+
attr_accessor :timeout, :ensure_https
|
|
14
|
+
|
|
15
|
+
##
|
|
16
|
+
# * *Required arguments*
|
|
17
|
+
# - +user_id+ -> ID of the user whose purchases are to be listed.
|
|
18
|
+
#
|
|
20
19
|
def initialize(user_id)
|
|
21
20
|
@user_id = user_id
|
|
22
|
-
@timeout =
|
|
21
|
+
@timeout = 100_000
|
|
23
22
|
@ensure_https = false
|
|
24
23
|
end
|
|
25
|
-
|
|
24
|
+
|
|
26
25
|
# HTTP method
|
|
27
26
|
def method
|
|
28
27
|
:get
|
|
29
28
|
end
|
|
30
|
-
|
|
29
|
+
|
|
31
30
|
# Values of body parameters as a Hash
|
|
32
31
|
def body_parameters
|
|
33
|
-
|
|
34
|
-
p
|
|
32
|
+
{}
|
|
35
33
|
end
|
|
36
|
-
|
|
34
|
+
|
|
37
35
|
# Values of query parameters as a Hash.
|
|
38
36
|
# name of parameter => value of the parameter
|
|
39
37
|
def query_parameters
|
|
40
|
-
|
|
41
|
-
params
|
|
38
|
+
{}
|
|
42
39
|
end
|
|
43
|
-
|
|
40
|
+
|
|
44
41
|
# Relative path to the endpoint
|
|
45
42
|
def path
|
|
46
43
|
"/{databaseId}/users/#{@user_id}/purchases/"
|
|
@@ -5,42 +5,39 @@
|
|
|
5
5
|
module RecombeeApiClient
|
|
6
6
|
require_relative 'request'
|
|
7
7
|
require_relative '../errors'
|
|
8
|
-
|
|
8
|
+
|
|
9
9
|
##
|
|
10
|
-
#Lists all the ratings ever submitted by the given user
|
|
10
|
+
# Lists all the ratings ever submitted by the given user.#
|
|
11
11
|
class ListUserRatings < ApiRequest
|
|
12
12
|
attr_reader :user_id
|
|
13
|
-
attr_accessor :timeout
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
#
|
|
13
|
+
attr_accessor :timeout, :ensure_https
|
|
14
|
+
|
|
15
|
+
##
|
|
16
|
+
# * *Required arguments*
|
|
17
|
+
# - +user_id+ -> ID of the user whose ratings are to be listed.
|
|
18
|
+
#
|
|
20
19
|
def initialize(user_id)
|
|
21
20
|
@user_id = user_id
|
|
22
|
-
@timeout =
|
|
21
|
+
@timeout = 100_000
|
|
23
22
|
@ensure_https = false
|
|
24
23
|
end
|
|
25
|
-
|
|
24
|
+
|
|
26
25
|
# HTTP method
|
|
27
26
|
def method
|
|
28
27
|
:get
|
|
29
28
|
end
|
|
30
|
-
|
|
29
|
+
|
|
31
30
|
# Values of body parameters as a Hash
|
|
32
31
|
def body_parameters
|
|
33
|
-
|
|
34
|
-
p
|
|
32
|
+
{}
|
|
35
33
|
end
|
|
36
|
-
|
|
34
|
+
|
|
37
35
|
# Values of query parameters as a Hash.
|
|
38
36
|
# name of parameter => value of the parameter
|
|
39
37
|
def query_parameters
|
|
40
|
-
|
|
41
|
-
params
|
|
38
|
+
{}
|
|
42
39
|
end
|
|
43
|
-
|
|
40
|
+
|
|
44
41
|
# Relative path to the endpoint
|
|
45
42
|
def path
|
|
46
43
|
"/{databaseId}/users/#{@user_id}/ratings/"
|
|
@@ -5,43 +5,40 @@
|
|
|
5
5
|
module RecombeeApiClient
|
|
6
6
|
require_relative 'request'
|
|
7
7
|
require_relative '../errors'
|
|
8
|
-
|
|
8
|
+
|
|
9
9
|
##
|
|
10
|
-
#Lists all the view portions ever submitted by the given user.
|
|
10
|
+
# Lists all the view portions ever submitted by the given user.
|
|
11
11
|
#
|
|
12
12
|
class ListUserViewPortions < ApiRequest
|
|
13
13
|
attr_reader :user_id
|
|
14
|
-
attr_accessor :timeout
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
#
|
|
14
|
+
attr_accessor :timeout, :ensure_https
|
|
15
|
+
|
|
16
|
+
##
|
|
17
|
+
# * *Required arguments*
|
|
18
|
+
# - +user_id+ -> ID of the user whose view portions are to be listed.
|
|
19
|
+
#
|
|
21
20
|
def initialize(user_id)
|
|
22
21
|
@user_id = user_id
|
|
23
|
-
@timeout =
|
|
22
|
+
@timeout = 100_000
|
|
24
23
|
@ensure_https = false
|
|
25
24
|
end
|
|
26
|
-
|
|
25
|
+
|
|
27
26
|
# HTTP method
|
|
28
27
|
def method
|
|
29
28
|
:get
|
|
30
29
|
end
|
|
31
|
-
|
|
30
|
+
|
|
32
31
|
# Values of body parameters as a Hash
|
|
33
32
|
def body_parameters
|
|
34
|
-
|
|
35
|
-
p
|
|
33
|
+
{}
|
|
36
34
|
end
|
|
37
|
-
|
|
35
|
+
|
|
38
36
|
# Values of query parameters as a Hash.
|
|
39
37
|
# name of parameter => value of the parameter
|
|
40
38
|
def query_parameters
|
|
41
|
-
|
|
42
|
-
params
|
|
39
|
+
{}
|
|
43
40
|
end
|
|
44
|
-
|
|
41
|
+
|
|
45
42
|
# Relative path to the endpoint
|
|
46
43
|
def path
|
|
47
44
|
"/{databaseId}/users/#{@user_id}/viewportions/"
|