ruby-identitas-api 0.2.0 → 0.3.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: e1c982b822e1001f522ae9f264280d0532c10598
4
- data.tar.gz: ccd77bdcb92b19710be0bafe62c7cc4a1eb129de
3
+ metadata.gz: 41f57c2d6b42d84fe2986fedea63b449e388cac5
4
+ data.tar.gz: abed4c9a310110fc1d32dc5fcd218f833bdf3a1c
5
5
  SHA512:
6
- metadata.gz: 203af987f7d61ca5d732503d731aeb69ded185409e3318fffcfc85abe157ddbed50dd44d2599878b64cdeed62d9a07d7a4d1a1c247f0983efd360f93d400f9d0
7
- data.tar.gz: 0eaed0062793d35d881e16ed91560ac13b4cc74d65c93e5814b2516ad491ba7c31167523daced70d4a37e211743867c2f2ac65364d6fac2b0a1eb24eb0d07180
6
+ metadata.gz: 3b4617dba0806a3d86de99ec064ad977a008d0fb1103c707d2c8c443a414ef7c7a07d2bbf44c43281970e9e634a4430178267f09713deea81ac241cfee3dea43
7
+ data.tar.gz: 3df75bf6cc1efc0c5c4c91630d68593b1ade0a6bf78c7078a2282124c360ceaa7a7a951d7a8f1f259557594fc04fbbc98edeb988c74402a9d50e769c1faa759f
data/Gemfile.lock CHANGED
@@ -1,14 +1,14 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- ruby-identitas-api (0.2.0)
4
+ ruby-identitas-api (0.3.0)
5
5
  httparty
6
6
 
7
7
  GEM
8
8
  remote: https://rubygems.org/
9
9
  specs:
10
10
  diff-lcs (1.3)
11
- httparty (0.15.6)
11
+ httparty (0.15.7)
12
12
  multi_xml (>= 0.5.2)
13
13
  multi_xml (0.6.0)
14
14
  rake (10.5.0)
data/README.md CHANGED
@@ -67,6 +67,24 @@ example :
67
67
  response = request.token_status.parsed_response
68
68
  ```
69
69
 
70
+ ### Chane password
71
+
72
+ Change password
73
+
74
+ parameters :
75
+
76
+ | name | type |
77
+ | ------------ | ------------ |
78
+ |`access_token`| query string |
79
+ |`password`| query string |
80
+ |`password_confirmation`| query string |
81
+
82
+ example :
83
+
84
+ ```ruby
85
+ response = request.password({password: "mys3cret", password_confirmation: "mys3cret"}).parsed_response
86
+ ```
87
+
70
88
  ## Development
71
89
 
72
90
  After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake spec` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
@@ -1,7 +1,7 @@
1
1
  module Ruby
2
2
  module Identitas
3
3
  module Api
4
- VERSION = "0.2.0"
4
+ VERSION = "0.3.0"
5
5
  end
6
6
  end
7
7
  end
@@ -0,0 +1,13 @@
1
+ module Ruby
2
+ module Identitas
3
+ module Endpoints
4
+ module Password
5
+ def password(options = {})
6
+ options.merge!({access_token: @token})
7
+ endpoint = build_endpoint("/v1/me/password")
8
+ self.class.post(endpoint, query: options)
9
+ end
10
+ end
11
+ end
12
+ end
13
+ end
@@ -1,5 +1,6 @@
1
1
  require "ruby/identitas/endpoints/me"
2
2
  require "ruby/identitas/endpoints/token_status"
3
+ require "ruby/identitas/endpoints/password"
3
4
 
4
5
  module Ruby
5
6
  module Identitas
@@ -7,6 +8,7 @@ module Ruby
7
8
  include HTTParty
8
9
  include Ruby::Identitas::Endpoints::Me
9
10
  include Ruby::Identitas::Endpoints::TokenStatus
11
+ include Ruby::Identitas::Endpoints::Password
10
12
 
11
13
  def initialize(token)
12
14
  @base_uri = Ruby::Identitas::Api.url
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ruby-identitas-api
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - yunanhelmy
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2017-12-20 00:00:00.000000000 Z
11
+ date: 2018-04-29 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: httparty
@@ -90,6 +90,7 @@ files:
90
90
  - lib/ruby/identitas/api/version.rb
91
91
  - lib/ruby/identitas/configuration.rb
92
92
  - lib/ruby/identitas/endpoints/me.rb
93
+ - lib/ruby/identitas/endpoints/password.rb
93
94
  - lib/ruby/identitas/endpoints/token_status.rb
94
95
  - lib/ruby/identitas/main.rb
95
96
  - ruby-identitas-api.gemspec