wework 1.1.8 → 1.1.9
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/wework.rb +1 -0
- data/lib/wework/api/methods/provider.rb +5 -0
- data/lib/wework/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 9a27b4356a46bd485622d6e9dcea2cf1be0a571eb52499ce64788a1dc80a57f5
|
4
|
+
data.tar.gz: 4441474ed9f3e4c75d329e903c1e5cb2ed12dfd35ac29aa35332d1914a870b9d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: af3288c1e54e2de58fb25363701cc9bcf2b8edcfdda0075df4f2193f35fa505fbf2dda47f27f43387c28e48db425004298c22532e7ba7f6753ef657978b21229
|
7
|
+
data.tar.gz: 0da06a1707b5c849b7eed20fa6a6adbc4d4d78dc7887243b8eb363b6b7d6a6d00b711eb185d0f0c10221d05b6fbc86d0ee66e0955a8a221e20fe14c97084313d
|
data/lib/wework.rb
CHANGED
@@ -21,6 +21,7 @@ module Wework
|
|
21
21
|
AUTHORIZE_ENDPOINT = 'https://open.weixin.qq.com/connect/oauth2/authorize'.freeze
|
22
22
|
SSO_AUTHORIZE_ENDPOINT = 'https://open.work.weixin.qq.com/wwopen/sso/3rd_qrConnect'.freeze
|
23
23
|
APP_AUTHORIZE_ENDPOINT = 'https://open.work.weixin.qq.com/3rdapp/install'.freeze
|
24
|
+
REGISTER_ENDPOINT = 'https://open.work.weixin.qq.com/3rdservice/wework/register'.freeze
|
24
25
|
HTTP_OK_STATUS = [200, 201].freeze
|
25
26
|
SUCCESS_CODE = 0
|
26
27
|
|
@@ -15,6 +15,11 @@ module Wework
|
|
15
15
|
params = {template_id: template_id}
|
16
16
|
post 'service/get_register_code', params.merge(options)
|
17
17
|
end
|
18
|
+
|
19
|
+
def get_register_url template_id, options={}
|
20
|
+
register_code = get_register_code(template_id, options).register_code
|
21
|
+
"#{REGISTER_ENDPOINT}?register_code=#{register_code}"
|
22
|
+
end
|
18
23
|
end
|
19
24
|
end
|
20
25
|
end
|
data/lib/wework/version.rb
CHANGED