ZCRMSDK 1.0.0 → 1.0.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: d56af70d5d23b54d9d45d31ed2b8cc8503a4504b1f9389051fa045d880a69507
4
- data.tar.gz: deeec0442c523b22978e501f0ff2857bd0db7a43552e784eae0dd3af821d6a82
3
+ metadata.gz: e94d56d890ac35f0b38ed54ba4e9194f6da2da9e7a9a34674af39f185aff4c26
4
+ data.tar.gz: 0d55ff863d8566ad8e8418cf987f59d1f1b365772362fa52788d1133c69ea180
5
5
  SHA512:
6
- metadata.gz: 9e8db5b5d612097e1a4012e4c1492ecfd7b2634180dcc01caa6719ab1bc03b3968042546a265f652280c54596e9d35c8781ecde3d81a7541df733f47d337a57b
7
- data.tar.gz: 570ba45f439498195d2ca3822d43bf0aacaf75ac687894fd4b7f711cbaf8690ce8482d53c094dba2961240277e1aab714aba993481e12a4511775570cb38890e
6
+ metadata.gz: ebdc399d3373acd979e3ce7daedcc5d77a8c5e8636e383f12c0eba2a003070b4237cb7cc1266d77fd2dfd4c360b7131e5ce0f9f45bd5d39a155ec665b35b3aea
7
+ data.tar.gz: a18a68e343488cc101ee8e8ed9d11e7eeec0d74b1b4d09e1c26debf21708e75bc991a85bbb02f4630d43dca2f3411ae717fd44489a09d93efc4f38b256d4b631
@@ -193,6 +193,9 @@ module ZCRMSDK
193
193
 
194
194
  def get_tokens_from_json(response_json)
195
195
  expires_in = response_json[OAuthUtility::ZohoOAuthConstants::EXPIRES_IN]
196
+ unless response_json.has_key?(OAuthUtility::ZohoOAuthConstants::EXPIRES_IN_SEC)
197
+ expires_in = expires_in * 1000
198
+ end
196
199
  expires_in += ZCRMSDK::OAuthClient::ZohoOAuthTokens.get_current_time_in_millis
197
200
  access_token = response_json[OAuthUtility::ZohoOAuthConstants::ACCESS_TOKEN]
198
201
  refresh_token = nil
@@ -34,6 +34,7 @@ module ZCRMSDK
34
34
  REFRESH_TOKEN = 'refresh_token'
35
35
  EXPIRES_IN = 'expires_in'
36
36
  EXPIRIY_TIME = 'expiry_time'
37
+ EXPIRES_IN_SEC = 'expires_in_sec'
37
38
  PERSISTENCE_HANDLER_CLASS_PATH = 'persistence_handler_class_path'
38
39
  PERSISTENCE_HANDLER_CLASS = 'persistence_handler_class'
39
40
  TOKEN = 'token'
data/lib/ZCRMSDK/test.rb CHANGED
@@ -14,6 +14,7 @@ require 'ZCRMSDK'
14
14
  # THIS CLASS SHOWS THE EXAMPLES
15
15
  class Tester
16
16
  def initialize
17
+
17
18
  config_details = { 'client_id' => 'client_id', 'client_secret' => 'client_secret', 'redirect_uri' => 'redirect_uri', 'api_base_url' => 'http://www.zohoapis.com', 'api_version' => 'v2', 'current_user_email' => 'current_user_email' ,'log_in_console' => 'true' }
18
19
  ZCRMSDK::RestClient::ZCRMRestClient.init(config_details)
19
20
  end
@@ -5612,7 +5613,7 @@ obj = Tester.new
5612
5613
 
5613
5614
  # obj.get_module
5614
5615
  # obj.get_all_modules
5615
- # obj.get_organization_details
5616
+ obj.get_organization_details
5616
5617
  # obj.get_current_user
5617
5618
 
5618
5619
  # ZCRMOrganization samples
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module ZCRMSDK
4
- VERSION = '1.0.0'
4
+ VERSION = '1.0.1'
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ZCRMSDK
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ version: 1.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - ZOHO CRM API TEAM
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2019-10-23 00:00:00.000000000 Z
11
+ date: 2019-11-18 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler