oeh-client 2.1.0 → 2.2.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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: b2e1f488d6df5d7c01573b2c09f6109057122bff
4
- data.tar.gz: 79d567e3050d95a11edd6fd703e6872b70360729
3
+ metadata.gz: 1d73780033a33f718f8e7efce83dabb232339514
4
+ data.tar.gz: 603b72716a34bcb5830f573e6a6fc8573ae2647a
5
5
  SHA512:
6
- metadata.gz: c0d48097d1a9a0c5e4838560d5881a217526d8bbb6c7f32cc7249badaa2dbaafae2f2f62d74614c19b81b30c823031d4b72bb89cf02b7472762714f1e2dba078
7
- data.tar.gz: 2a926fab453e9736685bc8cfcd9dd12831d45be1d8884cbe5803edc93a8e8d1be944f74f272625b58295f5fdb6c849ea6a9b99e5f87835847a4d8c2ffce70493
6
+ metadata.gz: 716f2fd434c750f9fb1d8b4ff5d7386bcf343f00d919851d72dae48d136f10f61de52c165fdc2a0fa8a9167a60df8008f945578d7ae184c6e6968a4b56a367e9
7
+ data.tar.gz: 31a9d2b273b0ba050a7a70f890c76b5b60347710fee2cbcdaa398dcc7292f2b9d270c82d6bb266b7fff9cfb07205cdd01a87540da6cb264f70fd4460578a3460
@@ -61,7 +61,7 @@ class OEHClient::Config::Space
61
61
  # Create the consumer and access token
62
62
  oauth_consumer = OAuth::Consumer.new("#{@api_key}!#{@username}",
63
63
  @shared_secret,
64
- {:site => "#{OEHClient::Helper::Request::ONE_PROTOCOL}#{@host}#{OEHClient::Helper::Request::THUNDERHEAD_DOMAIN}",
64
+ {:site => "#{OEHClient::Helper::Request::ONE_PROTOCOL}#{@host}",
65
65
  :scheme => :header})
66
66
  # return the access token
67
67
  return(OAuth::AccessToken.new(oauth_consumer))
@@ -71,7 +71,7 @@ class OEHClient::Config::Space
71
71
  def oauth_consumer()
72
72
  OAuth::Consumer.new("#{@api_key}!#{@username}",
73
73
  @shared_secret,
74
- {:site => "#{OEHClient::Helper::Request::ONE_PROTOCOL}#{@host}#{OEHClient::Helper::Request::THUNDERHEAD_DOMAIN}",
74
+ {:site => "#{OEHClient::Helper::Request::ONE_PROTOCOL}#{@host}",
75
75
  :scheme => :header})
76
76
  end
77
77
 
@@ -96,11 +96,11 @@ class OEHClient::Config::Space
96
96
  end # def meta_credentials
97
97
  # return the URL for the posting a login request
98
98
  def login_url()
99
- "#{OEHClient::Helper::Request::ONE_PROTOCOL}#{@host}#{OEHClient::Helper::Request::THUNDERHEAD_DOMAIN}/one/idm_login"
99
+ "#{OEHClient::Helper::Request::ONE_PROTOCOL}#{@host}/one/idm_login"
100
100
  end # def login_url
101
101
  # return the URL for posting a logout request
102
102
  def logout_url()
103
- "#{OEHClient::Helper::Request::ONE_PROTOCOL}#{@host}#{OEHClient::Helper::Request::THUNDERHEAD_DOMAIN}/one/logout"
103
+ "#{OEHClient::Helper::Request::ONE_PROTOCOL}#{@host}/one/logout"
104
104
  end
105
105
 
106
106
  # retrieve the workspace meta-data object from the thinstance in realtime
@@ -75,7 +75,7 @@ class OEHClient::Data::Structure < OEHClient::Data::Node
75
75
 
76
76
  # request_url returns the fully-qualified URL to return a given structure
77
77
  def self.request_url(api_name)
78
- "#{OEHClient::Helper::Request::ONE_PROTOCOL}#{@space.host}#{OEHClient::Helper::Request::THUNDERHEAD_DOMAIN}#{OEHClient::Helper::Request::ONE_URI_PART}#{OEHClient::Helper::Request::API_URI_PART}#{OEHClient::Helper::Request::API_VERSION}#{API_PROFILES}/#{api_name}"
78
+ "#{OEHClient::Helper::Request::ONE_PROTOCOL}#{@space.host}#{OEHClient::Helper::Request::ONE_URI_PART}#{OEHClient::Helper::Request::API_URI_PART}#{OEHClient::Helper::Request::API_VERSION}#{API_PROFILES}/#{api_name}"
79
79
  end
80
80
 
81
81
 
@@ -54,7 +54,7 @@ module OEHClient::Meta::Entity
54
54
  # get the list of args
55
55
  entity_uri = (args.has_key?(:space)) ? "workspaces/#{args[:space]}/#{entity_uri_stem}" : "#{entity_uri_stem}"
56
56
  # construct the URL for retrieving the entity
57
- url = "#{OEHClient::Helper::Request::ONE_PROTOCOL}#{self.session.space.host}#{OEHClient::Helper::Request::THUNDERHEAD_DOMAIN}/one/services/api/#{entity_uri}"
57
+ url = "#{OEHClient::Helper::Request::ONE_PROTOCOL}#{self.session.space.host}/one/services/api/#{entity_uri}"
58
58
  # set the header information
59
59
  header = (!self.session.cookies.nil? ? {:cookies => self.session.cookies}.merge!(OEHClient::Helper::Request.default_JSON_header()) : OEHClient::Helper::Request.default_JSON_header())
60
60
  # construct the request params using the header and params (if passed)
@@ -302,7 +302,7 @@ class OEHClient::Realtime::Interaction
302
302
  # request_url returns the base of the request URL used to make either a realtime or offline request
303
303
  # through published API
304
304
  def request_url()
305
- "#{OEHClient::Helper::Request::ONE_PROTOCOL}#{@space.host}#{OEHClient::Helper::Request::THUNDERHEAD_DOMAIN}#{OEHClient::Helper::Request::ONE_URI_PART}#{OEHClient::Helper::Request::API_URI_PART}#{OEHClient::Helper::Request::API_VERSION}"
305
+ "#{OEHClient::Helper::Request::ONE_PROTOCOL}#{@space.host}#{OEHClient::Helper::Request::ONE_URI_PART}#{OEHClient::Helper::Request::API_URI_PART}#{OEHClient::Helper::Request::API_VERSION}"
306
306
  end
307
307
 
308
308
  # realtime_url is the interaction part of the API URI
@@ -1,3 +1,3 @@
1
1
  module OEHClient
2
- VERSION = "2.1.0"
2
+ VERSION = "2.2.0"
3
3
  end
data/lib/oehclient.rb CHANGED
@@ -82,8 +82,6 @@ module OEHClient
82
82
  # merge parameters into the header if they are passed
83
83
  header.merge!(:params => options[:params] ) if (options.has_key?(:params))
84
84
 
85
- puts "-----] payload: #{options[:payload]}"
86
-
87
85
  # send the POST request, manage the returned response, and return the body of the response to the
88
86
  # calling method
89
87
  RestClient.post(url, options[:payload], header) { | response, request, result | OEHClient::Helper::Response.handle(response)}
data/oeh-client.gemspec CHANGED
@@ -27,9 +27,9 @@ Gem::Specification.new do |spec|
27
27
  spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
28
28
  spec.require_paths = ["lib"]
29
29
 
30
- spec.add_development_dependency "bundler", "~> 1.0.0", ">= 1.10"
30
+ spec.add_development_dependency "bundler", "~> 1", ">= 1.10"
31
31
  spec.add_development_dependency "rake", "~> 12.0.0", ">= 12.0.0"
32
- spec.add_development_dependency "rspec-rails", "~> 3.0.0", ">= 3.2"
32
+ spec.add_development_dependency "rspec-rails", "~> 3", ">= 3.2"
33
33
 
34
34
  spec.add_dependency "oauth", "~> 0.5"
35
35
  spec.add_dependency "json", "~> 1.8"
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: oeh-client
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.1.0
4
+ version: 2.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jason Balliet
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2016-12-20 00:00:00.000000000 Z
11
+ date: 2017-01-11 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -16,7 +16,7 @@ dependencies:
16
16
  requirements:
17
17
  - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: 1.0.0
19
+ version: '1'
20
20
  - - ">="
21
21
  - !ruby/object:Gem::Version
22
22
  version: '1.10'
@@ -26,7 +26,7 @@ dependencies:
26
26
  requirements:
27
27
  - - "~>"
28
28
  - !ruby/object:Gem::Version
29
- version: 1.0.0
29
+ version: '1'
30
30
  - - ">="
31
31
  - !ruby/object:Gem::Version
32
32
  version: '1.10'
@@ -56,7 +56,7 @@ dependencies:
56
56
  requirements:
57
57
  - - "~>"
58
58
  - !ruby/object:Gem::Version
59
- version: 3.0.0
59
+ version: '3'
60
60
  - - ">="
61
61
  - !ruby/object:Gem::Version
62
62
  version: '3.2'
@@ -66,7 +66,7 @@ dependencies:
66
66
  requirements:
67
67
  - - "~>"
68
68
  - !ruby/object:Gem::Version
69
- version: 3.0.0
69
+ version: '3'
70
70
  - - ">="
71
71
  - !ruby/object:Gem::Version
72
72
  version: '3.2'