face 0.0.8 → 0.0.9
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.
- data/lib/face/client/accounts.rb +9 -0
 - data/lib/face/client/utils.rb +12 -1
 - data/lib/face/version.rb +1 -1
 - metadata +17 -11
 - checksums.yaml +0 -7
 
    
        data/lib/face/client/accounts.rb
    CHANGED
    
    | 
         @@ -8,6 +8,15 @@ module Face 
     | 
|
| 
       8 
8 
     | 
    
         
             
                  def account_users(opts={})
         
     | 
| 
       9 
9 
     | 
    
         
             
                    make_request(:account_users, opts.merge(user_auth_param))
         
     | 
| 
       10 
10 
     | 
    
         
             
                  end
         
     | 
| 
      
 11 
     | 
    
         
            +
                  
         
     | 
| 
      
 12 
     | 
    
         
            +
                  def account_namespaces(opts={})
         
     | 
| 
      
 13 
     | 
    
         
            +
                    make_request(:account_namespaces, opts.merge(user_auth_param))
         
     | 
| 
      
 14 
     | 
    
         
            +
                  end
         
     | 
| 
      
 15 
     | 
    
         
            +
                  
         
     | 
| 
      
 16 
     | 
    
         
            +
                  def account_authenticate(opts={})
         
     | 
| 
      
 17 
     | 
    
         
            +
                    make_request(:account_authenticate, opts.merge(user_auth_param))
         
     | 
| 
      
 18 
     | 
    
         
            +
                  end
         
     | 
| 
      
 19 
     | 
    
         
            +
                  
         
     | 
| 
       11 
20 
     | 
    
         
             
                end
         
     | 
| 
       12 
21 
     | 
    
         
             
              end
         
     | 
| 
       13 
22 
     | 
    
         
             
            end
         
     | 
    
        data/lib/face/client/utils.rb
    CHANGED
    
    | 
         @@ -15,7 +15,9 @@ module Face 
     | 
|
| 
       15 
15 
     | 
    
         
             
                    :tags_save => 'http://api.skybiometry.com/fc/tags/save.json',
         
     | 
| 
       16 
16 
     | 
    
         
             
                    :tags_remove => 'http://api.skybiometry.com/fc/tags/remove.json',
         
     | 
| 
       17 
17 
     | 
    
         
             
                    :account_limits => 'http://api.skybiometry.com/fc/account/limits.json',
         
     | 
| 
       18 
     | 
    
         
            -
                    :account_users => 'http://api.skybiometry.com/fc/account/users.json'
         
     | 
| 
      
 18 
     | 
    
         
            +
                    :account_users => 'http://api.skybiometry.com/fc/account/users.json',
         
     | 
| 
      
 19 
     | 
    
         
            +
                    :account_namespaces => 'http://api.skybiometry.com/fc/account/namespaces.json',
         
     | 
| 
      
 20 
     | 
    
         
            +
                    :account_authenticate => 'http://api.skybiometry.com/fc/account/authenticate.json'
         
     | 
| 
       19 
21 
     | 
    
         
             
                  }
         
     | 
| 
       20 
22 
     | 
    
         | 
| 
       21 
23 
     | 
    
         
             
                  def api_crendential
         
     | 
| 
         @@ -30,6 +32,15 @@ module Face 
     | 
|
| 
       30 
32 
     | 
    
         
             
                    if opts[:uids].is_a? Array
         
     | 
| 
       31 
33 
     | 
    
         
             
                      opts[:uids] = opts[:uids].join(',')
         
     | 
| 
       32 
34 
     | 
    
         
             
                    end
         
     | 
| 
      
 35 
     | 
    
         
            +
                    
         
     | 
| 
      
 36 
     | 
    
         
            +
                    if opts[:tids].is_a? Array
         
     | 
| 
      
 37 
     | 
    
         
            +
                      opts[:tids] = opts[:tids].join(',')
         
     | 
| 
      
 38 
     | 
    
         
            +
                    end
         
     | 
| 
      
 39 
     | 
    
         
            +
             
     | 
| 
      
 40 
     | 
    
         
            +
                    if opts[:pids].is_a? Array
         
     | 
| 
      
 41 
     | 
    
         
            +
                      opts[:pids] = opts[:pids].join(',')
         
     | 
| 
      
 42 
     | 
    
         
            +
                    end
         
     | 
| 
      
 43 
     | 
    
         
            +
                    
         
     | 
| 
       33 
44 
     | 
    
         
             
                    response = JSON.parse( RestClient.post(API_METHODS[ api_method ], opts.merge(api_crendential)).body )
         
     | 
| 
       34 
45 
     | 
    
         
             
                    if %w/success partial/.include?(response['status'])
         
     | 
| 
       35 
46 
     | 
    
         
             
                      response
         
     | 
    
        data/lib/face/version.rb
    CHANGED
    
    
    
        metadata
    CHANGED
    
    | 
         @@ -1,41 +1,46 @@ 
     | 
|
| 
       1 
1 
     | 
    
         
             
            --- !ruby/object:Gem::Specification
         
     | 
| 
       2 
2 
     | 
    
         
             
            name: face
         
     | 
| 
       3 
3 
     | 
    
         
             
            version: !ruby/object:Gem::Version
         
     | 
| 
       4 
     | 
    
         
            -
              version: 0.0. 
     | 
| 
      
 4 
     | 
    
         
            +
              version: 0.0.9
         
     | 
| 
      
 5 
     | 
    
         
            +
              prerelease: 
         
     | 
| 
       5 
6 
     | 
    
         
             
            platform: ruby
         
     | 
| 
       6 
7 
     | 
    
         
             
            authors:
         
     | 
| 
       7 
8 
     | 
    
         
             
            - Roc Yu
         
     | 
| 
       8 
9 
     | 
    
         
             
            autorequire: 
         
     | 
| 
       9 
10 
     | 
    
         
             
            bindir: bin
         
     | 
| 
       10 
11 
     | 
    
         
             
            cert_chain: []
         
     | 
| 
       11 
     | 
    
         
            -
            date: 2013- 
     | 
| 
      
 12 
     | 
    
         
            +
            date: 2013-08-23 00:00:00.000000000 Z
         
     | 
| 
       12 
13 
     | 
    
         
             
            dependencies:
         
     | 
| 
       13 
14 
     | 
    
         
             
            - !ruby/object:Gem::Dependency
         
     | 
| 
       14 
15 
     | 
    
         
             
              name: rest-client
         
     | 
| 
       15 
16 
     | 
    
         
             
              requirement: !ruby/object:Gem::Requirement
         
     | 
| 
      
 17 
     | 
    
         
            +
                none: false
         
     | 
| 
       16 
18 
     | 
    
         
             
                requirements:
         
     | 
| 
       17 
     | 
    
         
            -
                - - '>='
         
     | 
| 
      
 19 
     | 
    
         
            +
                - - ! '>='
         
     | 
| 
       18 
20 
     | 
    
         
             
                  - !ruby/object:Gem::Version
         
     | 
| 
       19 
21 
     | 
    
         
             
                    version: 1.6.1
         
     | 
| 
       20 
22 
     | 
    
         
             
              type: :runtime
         
     | 
| 
       21 
23 
     | 
    
         
             
              prerelease: false
         
     | 
| 
       22 
24 
     | 
    
         
             
              version_requirements: !ruby/object:Gem::Requirement
         
     | 
| 
      
 25 
     | 
    
         
            +
                none: false
         
     | 
| 
       23 
26 
     | 
    
         
             
                requirements:
         
     | 
| 
       24 
     | 
    
         
            -
                - - '>='
         
     | 
| 
      
 27 
     | 
    
         
            +
                - - ! '>='
         
     | 
| 
       25 
28 
     | 
    
         
             
                  - !ruby/object:Gem::Version
         
     | 
| 
       26 
29 
     | 
    
         
             
                    version: 1.6.1
         
     | 
| 
       27 
30 
     | 
    
         
             
            - !ruby/object:Gem::Dependency
         
     | 
| 
       28 
31 
     | 
    
         
             
              name: json
         
     | 
| 
       29 
32 
     | 
    
         
             
              requirement: !ruby/object:Gem::Requirement
         
     | 
| 
      
 33 
     | 
    
         
            +
                none: false
         
     | 
| 
       30 
34 
     | 
    
         
             
                requirements:
         
     | 
| 
       31 
     | 
    
         
            -
                - - '>='
         
     | 
| 
      
 35 
     | 
    
         
            +
                - - ! '>='
         
     | 
| 
       32 
36 
     | 
    
         
             
                  - !ruby/object:Gem::Version
         
     | 
| 
       33 
37 
     | 
    
         
             
                    version: 1.4.6
         
     | 
| 
       34 
38 
     | 
    
         
             
              type: :runtime
         
     | 
| 
       35 
39 
     | 
    
         
             
              prerelease: false
         
     | 
| 
       36 
40 
     | 
    
         
             
              version_requirements: !ruby/object:Gem::Requirement
         
     | 
| 
      
 41 
     | 
    
         
            +
                none: false
         
     | 
| 
       37 
42 
     | 
    
         
             
                requirements:
         
     | 
| 
       38 
     | 
    
         
            -
                - - '>='
         
     | 
| 
      
 43 
     | 
    
         
            +
                - - ! '>='
         
     | 
| 
       39 
44 
     | 
    
         
             
                  - !ruby/object:Gem::Version
         
     | 
| 
       40 
45 
     | 
    
         
             
                    version: 1.4.6
         
     | 
| 
       41 
46 
     | 
    
         
             
            description: ''
         
     | 
| 
         @@ -63,25 +68,26 @@ files: 
     | 
|
| 
       63 
68 
     | 
    
         
             
            - lib/face/version.rb
         
     | 
| 
       64 
69 
     | 
    
         
             
            homepage: http://rubygems.org/gems/face
         
     | 
| 
       65 
70 
     | 
    
         
             
            licenses: []
         
     | 
| 
       66 
     | 
    
         
            -
            metadata: {}
         
     | 
| 
       67 
71 
     | 
    
         
             
            post_install_message: 
         
     | 
| 
       68 
72 
     | 
    
         
             
            rdoc_options: []
         
     | 
| 
       69 
73 
     | 
    
         
             
            require_paths:
         
     | 
| 
       70 
74 
     | 
    
         
             
            - lib
         
     | 
| 
       71 
75 
     | 
    
         
             
            required_ruby_version: !ruby/object:Gem::Requirement
         
     | 
| 
      
 76 
     | 
    
         
            +
              none: false
         
     | 
| 
       72 
77 
     | 
    
         
             
              requirements:
         
     | 
| 
       73 
     | 
    
         
            -
              - - '>='
         
     | 
| 
      
 78 
     | 
    
         
            +
              - - ! '>='
         
     | 
| 
       74 
79 
     | 
    
         
             
                - !ruby/object:Gem::Version
         
     | 
| 
       75 
80 
     | 
    
         
             
                  version: '0'
         
     | 
| 
       76 
81 
     | 
    
         
             
            required_rubygems_version: !ruby/object:Gem::Requirement
         
     | 
| 
      
 82 
     | 
    
         
            +
              none: false
         
     | 
| 
       77 
83 
     | 
    
         
             
              requirements:
         
     | 
| 
       78 
     | 
    
         
            -
              - - '>='
         
     | 
| 
      
 84 
     | 
    
         
            +
              - - ! '>='
         
     | 
| 
       79 
85 
     | 
    
         
             
                - !ruby/object:Gem::Version
         
     | 
| 
       80 
86 
     | 
    
         
             
                  version: '0'
         
     | 
| 
       81 
87 
     | 
    
         
             
            requirements: []
         
     | 
| 
       82 
88 
     | 
    
         
             
            rubyforge_project: face
         
     | 
| 
       83 
     | 
    
         
            -
            rubygems_version:  
     | 
| 
      
 89 
     | 
    
         
            +
            rubygems_version: 1.8.24
         
     | 
| 
       84 
90 
     | 
    
         
             
            signing_key: 
         
     | 
| 
       85 
     | 
    
         
            -
            specification_version:  
     | 
| 
      
 91 
     | 
    
         
            +
            specification_version: 3
         
     | 
| 
       86 
92 
     | 
    
         
             
            summary: Ruby wraper of SkyBiometry Face Detection and Recognition API
         
     | 
| 
       87 
93 
     | 
    
         
             
            test_files: []
         
     | 
    
        checksums.yaml
    DELETED
    
    | 
         @@ -1,7 +0,0 @@ 
     | 
|
| 
       1 
     | 
    
         
            -
            ---
         
     | 
| 
       2 
     | 
    
         
            -
            SHA1:
         
     | 
| 
       3 
     | 
    
         
            -
              metadata.gz: aa721c8007babb507dfc7fe4a7739145a07a02d7
         
     | 
| 
       4 
     | 
    
         
            -
              data.tar.gz: 278aabb0873b98a5fec271cb32a71d130fe2b8c5
         
     | 
| 
       5 
     | 
    
         
            -
            SHA512:
         
     | 
| 
       6 
     | 
    
         
            -
              metadata.gz: b358f2742be5d9c1c4ee99c193bb78b116ac3583f961f226c4e083db4da7ff532dff5d21b819e587a4a35c15c18b9295224bfb2fa0c7a9ad9a590d49027ee32f
         
     | 
| 
       7 
     | 
    
         
            -
              data.tar.gz: 19e684936c4e63e20536bccde06f5ec4baa6b22b35bdd3e38308d49c98ea3f088a54a6e5c72f84bf256db9717438dbea1c2d412cc650ec32c251f3edcc15be73
         
     |