AlistGo/alist · error

tokenInfo.ResMessage

Error message

tokenInfo.ResMessage

What it means

Raised in Cloud189PC.login after getSessionForPC.action returns a non-zero ResCode: the session could not be established (expired login result or server-side rejection). The server's ResMessage becomes the error text via fmt.Errorf.

Solutions

  1. Check the storage configuration and the provider's service status, fix the indicated cause, and retry the operation.
Defensive patterns

Strategy: try-catch

When it happens

Trigger: Thrown at drivers/189pc/utils.go:362 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of AlistGo/alist@843d9dc814 (2026-08-15). Data as JSON: /api/errors/a75dd998322144f5. Report an issue: GitHub.

Appendix: source

Thrown at drivers/189pc/utils.go:362

	}

	// 获取Session
	var erron RespErr
	var tokenInfo AppSessionResp
	_, err = y.client.R().
		SetResult(&tokenInfo).SetError(&erron).
		SetQueryParams(clientSuffix()).
		SetQueryParam("redirectURL", loginresp.ToUrl).
		Post(API_URL + "/getSessionForPC.action")
	if err != nil {
		return
	}

	if erron.HasError() {
		return &erron
	}
	if tokenInfo.ResCode != 0 {
		err = fmt.Errorf(tokenInfo.ResMessage)
		return
	}
	y.tokenInfo = &tokenInfo
	return
}

/* 初始化登陆需要的参数
*  如果遇到验证码返回错误
 */
func (y *Cloud189PC) initLoginParam() error {
	// 清除cookie
	jar, _ := cookiejar.New(nil)
	y.client.SetCookieJar(jar)

	res, err := y.client.R().
		SetQueryParams(map[string]string{
			"appId":      APP_ID,
			"clientType": CLIENT_TYPE,

View on GitHub (pinned to 843d9dc814)