fantasticstay_api 0.1.1 → 0.1.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/fantasticstay_api/client.rb +5 -4
- data/lib/fantasticstay_api/version.rb +1 -1
- metadata +6 -6
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: f0a0159628ff5d6e47b19ff0cbcc1f206809c18bf01a85581c80ce448cc2d8cd
|
4
|
+
data.tar.gz: fc4aa632878fad907ddada639f09339d16d90db906c1bd4a2d1bb34a68cab3ac
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 66c7a86db2f4e5bad774620f8c7f0eaa00af1e63ffffe357a3df59165507bf9e43446252b8a632c5a56da904c9be80a6cc40236919ca6b130d00f49fecd94f8f
|
7
|
+
data.tar.gz: ffdd16db301ead53334a991d423cf72714f6c19568d916b607e2304886ed785f76697adc459826fa79676159b0c5cb3ec4c807ba1f5367f0de3d196f75b4b9df
|
@@ -45,16 +45,17 @@ module FantasticstayApi
|
|
45
45
|
end
|
46
46
|
|
47
47
|
# FantasticstayApi::Client.new.reservations(38859)
|
48
|
-
def reservations(listing_id, filters = [], sort =
|
48
|
+
def reservations(listing_id, filters = [], sort = { order: 'checkIn', direction: 'desc' }, global_params = {})
|
49
49
|
response = request(
|
50
50
|
http_method: :get,
|
51
51
|
endpoint: 'reservations',
|
52
52
|
params: {
|
53
53
|
listing_id: listing_id,
|
54
54
|
filters: filters.to_json,
|
55
|
-
sort: sort
|
55
|
+
sort: sort[:order],
|
56
|
+
direction: sort[:direction]
|
56
57
|
}.merge!(global_params),
|
57
|
-
cache_ttl: 3600*24
|
58
|
+
cache_ttl: 3600 * 24
|
58
59
|
)
|
59
60
|
process_response(response)
|
60
61
|
end
|
@@ -73,7 +74,7 @@ module FantasticstayApi
|
|
73
74
|
http_method: :get,
|
74
75
|
endpoint: "guests/#{guest_id}",
|
75
76
|
params: global_params,
|
76
|
-
cache_ttl: 3600*24
|
77
|
+
cache_ttl: 3600 * 24
|
77
78
|
)
|
78
79
|
process_response(response)
|
79
80
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: fantasticstay_api
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Dinis
|
8
|
-
autorequire:
|
8
|
+
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-
|
11
|
+
date: 2022-10-26 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: faraday
|
@@ -94,7 +94,7 @@ metadata:
|
|
94
94
|
homepage_uri: https://github.com/dlage/fantasticstay_api_gem
|
95
95
|
source_code_uri: https://github.com/dlage/fantasticstay_api_gem
|
96
96
|
changelog_uri: https://github.com/dlage/fantasticstay_api_gem/blob/master/CHANGELOG.md
|
97
|
-
post_install_message:
|
97
|
+
post_install_message:
|
98
98
|
rdoc_options: []
|
99
99
|
require_paths:
|
100
100
|
- lib
|
@@ -109,8 +109,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
109
109
|
- !ruby/object:Gem::Version
|
110
110
|
version: '0'
|
111
111
|
requirements: []
|
112
|
-
rubygems_version: 3.
|
113
|
-
signing_key:
|
112
|
+
rubygems_version: 3.2.33
|
113
|
+
signing_key:
|
114
114
|
specification_version: 4
|
115
115
|
summary: FantasticStay API Wrapper.
|
116
116
|
test_files: []
|