Method: Wechat::Concern::Common#qrcode_create_scene
- Defined in:
- lib/wechat/concern/common.rb
#qrcode_create_scene(scene_id_or_str, expire_seconds = 604800) ⇒ Object
47 48 49 50 51 52 53 54 55 56 57 58 |
# File 'lib/wechat/concern/common.rb', line 47 def qrcode_create_scene(scene_id_or_str, expire_seconds = 604800) case scene_id_or_str when 0.class post 'qrcode/create', JSON.generate(expire_seconds: expire_seconds, action_name: 'QR_SCENE', action_info: { scene: { scene_id: scene_id_or_str } }) else post 'qrcode/create', JSON.generate(expire_seconds: expire_seconds, action_name: 'QR_STR_SCENE', action_info: { scene: { scene_str: scene_id_or_str } }) end end |