package hook

import "fmt"

// 获取个人详细信息
func (h *Hook) GetSelfLoginInfo() (result GetSelfLoginInfoResp, err error) {
	resp, err := h.Client.R().SetSuccessResult(&result).Post("http://" + h.ServerIp + ":" + h.WxPort + "/GetSelfLoginInfo")
	if err != nil {
		return
	}
	if !resp.IsSuccessState() {
		err = fmt.Errorf("GetPersonalInfo failed with status code %d", resp.StatusCode)
		return
	}
	return
}
