Class: Zhima::Score
- Inherits:
-
Object
- Object
- Zhima::Score
- Defined in:
- lib/zhima/score.rb
Constant Summary collapse
- AUTHORIZE_METHOD =
'zhima.auth.info.authorize'.freeze
- SCORE_METHOD =
'zhima.credit.score.get'.freeze
- AUTH_QUERY_METHOD =
'zhima.auth.info.authquery'.freeze
Class Method Summary collapse
- .auth_query(params, sys_options = {}) ⇒ Object
-
.auth_url(params, sys_options = {}) ⇒ Object
params参数 请参考 b.zmxy.com.cn/technology/openDoc.htm?id=67 系统参数 SYSTEM_OPTIONS,可自己传入,一般只需要配置channel参数(与auth_code不对应芝麻信用会报错).
- .get(params, sys_options = {}) ⇒ Object
-
.param_decrypt(params_str) ⇒ Object
芝麻callback url中的params参数解密方法.
Class Method Details
.auth_query(params, sys_options = {}) ⇒ Object
21 22 23 |
# File 'lib/zhima/score.rb', line 21 def self.auth_query(params, = {}) Request.new(params, .merge(method: AUTH_QUERY_METHOD)).execute end |
.auth_url(params, sys_options = {}) ⇒ Object
params参数 请参考 b.zmxy.com.cn/technology/openDoc.htm?id=67 系统参数 SYSTEM_OPTIONS,可自己传入,一般只需要配置channel参数(与auth_code不对应芝麻信用会报错)
11 12 13 |
# File 'lib/zhima/score.rb', line 11 def self.auth_url(params, = {}) Request.new(params, .merge(method: AUTHORIZE_METHOD)).url end |
.get(params, sys_options = {}) ⇒ Object
16 17 18 |
# File 'lib/zhima/score.rb', line 16 def self.get(params, = {}) Request.new(params, .merge(method: SCORE_METHOD)).execute end |