mage-hand 0.2.0 → 0.2.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (4) hide show
  1. data/README.rdoc +10 -6
  2. data/VERSION +1 -1
  3. data/mage-hand.gemspec +1 -1
  4. metadata +3 -3
data/README.rdoc CHANGED
@@ -18,7 +18,8 @@ gem 'mage-hand'
18
18
 
19
19
  == Usage
20
20
 
21
- Right now mage-hand only handles the OAuth authentication to Obsidian Portal. Support for the rest of the API will be coming soon. To use Obsidian Portal to authenticate a Rails Controller include MageHand and set up the before filter.
21
+ MageHand handles the OAuth authentication to Obsidian Portal for you. To do that from a Rails controller
22
+ try this...
22
23
 
23
24
  class CoolController < ApplicationController
24
25
  include MageHand
@@ -26,16 +27,19 @@ class CoolController < ApplicationController
26
27
 
27
28
  This will handle all of the authenticate and redirecting etc. You will be returned to the original requested action after authentication.
28
29
 
29
- To make a call to the API, you have to do it directly with the full URL. obsidian_portal is a method that gets added to your controller by the include.
30
+ You can get objects from Obsidian Portal by calling the obsidian_portal object. obsidian_portal is a method that gets added to your controller by the include.
30
31
 
31
- obsidian_portal.get('http://api.obsidianportal.com/v1/users/me.json').body
32
+ obsidian_portal.current_user will get the currently authenticated user. obsidian_portal.me will
33
+ do the same thing.
32
34
 
33
- == Known Issues
35
+ To make a direct call to the API, you have to do it through the access token.
34
36
 
35
- 1. You have to use the full url to make calls to the API
37
+ obsidian_portal.access_token.get('/v1/users/me.json').body
36
38
 
37
- 2. A new browser session requires a new authorization to use the Obsidian Portal API
39
+ == Known Issues
38
40
 
41
+ 1. Only finding a user through current_user or me is currently supported.
42
+ 2. Should hide accesss token and have get work correctly on the obsidian_portal instance
39
43
 
40
44
  == Contributing to mage-hand
41
45
 
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.2.0
1
+ 0.2.1
data/mage-hand.gemspec CHANGED
@@ -5,7 +5,7 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{mage-hand}
8
- s.version = "0.2.0"
8
+ s.version = "0.2.1"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Steven Hammond"]
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mage-hand
3
3
  version: !ruby/object:Gem::Version
4
- hash: 23
4
+ hash: 21
5
5
  prerelease: false
6
6
  segments:
7
7
  - 0
8
8
  - 2
9
- - 0
10
- version: 0.2.0
9
+ - 1
10
+ version: 0.2.1
11
11
  platform: ruby
12
12
  authors:
13
13
  - Steven Hammond