AlistGo/alist · warning

resolutions is required

Error message

resolutions is required

What it means

Returned by the Thunder captcha-token verifier (drivers/thunder/util.go:157) when the verification API responds with a non-empty Url field. XunLei requires interactive verification (SMS/device verification) at that URL before further API calls are allowed, so the driver returns the link as an actionable error instead of a token.

Source

Thrown at drivers/123_open/other.go:733

	return d.client.Transcode.Resolutions(ctx, fileID)
}

func otherTranscodeVideo(d *Open123, ctx context.Context, args model.OtherArgs) (interface{}, error) {
	var req struct {
		FileID      int64  `json:"file_id"`
		CodecName   string `json:"codec_name"`
		VideoTime   int64  `json:"video_time"`
		Resolutions string `json:"resolutions"`
	}
	if err := decodeOtherArgs(args.Data, &req); err != nil {
		return nil, err
	}
	fileID, err := resolveFileID(args, req.FileID)
	if err != nil {
		return nil, err
	}
	if req.Resolutions == "" {
		return nil, errors.New("resolutions is required")
	}
	err = d.client.Transcode.Transcode(ctx, &pan123.TranscodeRequest{
		FileID:      fileID,
		CodecName:   req.CodecName,
		VideoTime:   req.VideoTime,
		Resolutions: req.Resolutions,
	})
	if err != nil {
		return nil, err
	}
	return okResult{Success: true}, nil
}

func otherTranscodeRecords(d *Open123, ctx context.Context, args model.OtherArgs) (interface{}, error) {
	var req fileIDRequest
	if err := decodeOtherArgs(args.Data, &req); err != nil {
		return nil, err
	}

View on GitHub (pinned to 843d9dc814)

Solutions

  1. Open the verification URL in a browser (the error renders it as a clickable link), complete the challenge, then retry the operation — the driver will fetch a captchaToken on the next attempt.
  2. Complete verification using the same network egress the server uses, to keep risk signals consistent.
  3. If verification loops repeatedly, log out/in of the storage config or wait some hours for the risk flag to decay.
  4. Keep the storage session warm (periodic token refresh) to reduce re-verification frequency.

Example fix

// before
err := xc.refreshCaptchaToken(ctx)
// err: need verify: <a ...>Click Here</a> — surfaced to logs, user never sees it

// after: surface it to the user for interactive action
if e != nil && strings.HasPrefix(e.Error(), "need verify") {
	url := extractHref(e.Error())
	notifyUser("XunLei requires verification: open %s in your browser", url)
}
Defensive patterns

Strategy: try-catch

Type guard

func isNeedVerifyErr(err error) bool {
	return err != nil && strings.HasPrefix(err.Error(), "need verify")
}

Try / catch

if err := xc.refreshCaptchaToken(ctx); isNeedVerifyErr(err) {
	url := extractHref(err.Error())
	// surface URL to the user; after they complete verification, retry once
}

Prevention

When it happens

Trigger: First-time login or risk-triggered re-verification on the XunLei account; new device fingerprint; logging in from an unusual region or IP; too frequent login attempts — any state where the verify endpoint issues resp.Url instead of resp.CaptchaToken.

Common situations: Fresh Thunder storage setups in AList-like tools; headless servers where the user missed the one-time verification; account flagged after password changes or travel.

Related errors


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