tribune_recurly_api 1.0.3 → 1.0.4

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: af64dadcbbd3277c1b4a5456251bb92c3559c9bcb7ce8e58d397964194d61011
4
- data.tar.gz: f4ceb3fad5a513a2ca8e944cd1e536689918662be57f7610825e6b86211d832c
3
+ metadata.gz: 710191b3144933ba14175b9f79f8b913c1838daf314103e03b2ce3c2a01d6c7b
4
+ data.tar.gz: 1c590a30db886709b49db2628a532de7da49f1bcc2774274e992a486095821e8
5
5
  SHA512:
6
- metadata.gz: 0a43e99ab5c9522148328ee1a61f7a56122efe293c41f8548feffea4ce8437c0b1873a86e2920c3a72d9b00abd9d385b60d27234965dcfbacf87a45b58444f6e
7
- data.tar.gz: 5a1a9f1b0d040f1901eb44a381236e08215e41ac56614b03da42d0ec93ef51ec7e77c78be7aed98cc39b88eefd4be73acb5d6352e5514a657efc98b348a80b2c
6
+ metadata.gz: b5357d11ad9b95582f81582fb3aec20759c3bc4fc5072e8608908d10a7fcb07f01d96e837235300bbdf6df2de3cf58eb38a6634fc37e3334f59a9374061b8993
7
+ data.tar.gz: cd48953eb36937260352b95ec6c58076204e261a604b33da7812eebc487de3fb9f2788012d6a33cf0690f47974100e2b16591a51a41e9a279d9142dbbb1c164a
@@ -8,6 +8,9 @@ module RecurlyApi
8
8
  # @param ssor_id [String], Recurly Account Code(i.e SsorID)
9
9
  # - The unique identifier of the Recurly account
10
10
  def account_info(ssor_id:, **optional_params)
11
+ # cache_key should be uniq for each account(here ssor_id is uniq)
12
+ # final cache key with prefix: tribune_recurly_api.account_info.<abcdef>
13
+ self.cache_key_name = "account_info.#{ssor_id}" unless bypass_caching?
11
14
  request_api(path_name: "accounts/code-#{ssor_id}", **optional_params) # cache_key_name: cache_key_name
12
15
  end
13
16
 
@@ -8,6 +8,9 @@ module RecurlyApi
8
8
  # @param ssor_id [String] Recurly Account ID(SsorID) or code.
9
9
  # For ID no prefix is used e.g. +e28zov4fw0v2+. For code use prefix +code-+, e.g. +code-bob+.
10
10
  def coupon_redemptions(ssor_id:, **optional_params)
11
+ # cache_key should be uniq for each account(here ssor_id is uniq)
12
+ # final cache key with prefix: tribune_recurly_api.coupon_redemptions.<abcdef>
13
+ self.cache_key_name = "coupon_redemptions.#{ssor_id}" unless bypass_caching?
11
14
  request_api(path_name: "accounts/code-#{ssor_id}/coupon_redemptions", **optional_params)
12
15
  end
13
16
 
@@ -39,7 +39,10 @@ module RecurlyApi
39
39
  # @param optional_params [Hash] Optional, same as above
40
40
  def plan_info(plan_id:, **optional_params)
41
41
  self.cache_expires_in = optional_params[:cache_expires_in] || cache_settings[:plan_expiry] unless bypass_caching?
42
- request_api(path_name: "plans/#{plan_id}", **optional_params) # cache_key_name: cache_key_name
42
+ # cache_key should be uniq for each plan(here plan_id is uniq)
43
+ # final cache key with prefix: tribune_recurly_api.plan_info.<abcdef>
44
+ self.cache_key_name = "plan_info.#{plan_id}" unless bypass_caching?
45
+ request_api(path_name: "plans/#{plan_id}", **optional_params)
43
46
  end
44
47
  end
45
48
  end
@@ -11,7 +11,10 @@ module RecurlyApi
11
11
  def account_subscriptions(ssor_id:, recurly_query_params: {}, **optional_params)
12
12
  path = "accounts/code-#{ssor_id}/subscriptions"
13
13
  self.cache_expires_in = optional_params[:cache_expires_in] || cache_settings[:subscription_expiry] unless bypass_caching?
14
- request_api(path_name: path, query_params: recurly_query_params, **optional_params) # cache_key_name: cache_key_name
14
+ # cache_key should be uniq for each account(here ssor_id is uniq)
15
+ # final cache key with prefix: tribune_recurly_api.account_subscriptions.<abcdef>
16
+ self.cache_key_name = "account_subscriptions.#{ssor_id}" unless bypass_caching?
17
+ request_api(path_name: path, query_params: recurly_query_params, **optional_params)
15
18
  end
16
19
 
17
20
  # Checking if user already has subscription OR
@@ -16,5 +16,6 @@ module RecurlyApi
16
16
  # end
17
17
  # VERSION = '1.0.1' # cache settings from configuration file
18
18
  # VERSION = '1.0.2' # prefixing '<code->' to ssor_id is now part of GEM
19
- VERSION = '1.0.3' # return recurly error response
19
+ # VERSION = '1.0.3' # return recurly error response
20
+ VERSION = '1.0.4' # cache key should be uniq
20
21
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: tribune_recurly_api
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.3
4
+ version: 1.0.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - udevulapally
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2021-06-28 00:00:00.000000000 Z
11
+ date: 2021-08-03 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport