WeChat.Plug.EventHandler (wechat v0.2.0)

微信推送消息处理器

Usage

将下面的代码加到 router 里面:

  • 单一应用的情况:

    forward "/wx/event", WeChat.Plug.EventHandler, client: WxOfficialAccount, handler: &Module.handle_event/2
  • 多个应用的情况:

    请将入口路径设置为如下格式: /xxx/:appid/xxx

    scope "/wx/event/:appid" do
      forward "/", WeChat.Plug.EventHandler, handler: &Module.handle_event/2
    end

Options

Link to this section Summary

Link to this section Functions