docs: clarify url vs code fields in qrcode event

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
stswangzhiping
2026-05-15 18:02:51 +08:00
parent 6da91c7d26
commit d91a309419

View File

@@ -312,6 +312,8 @@ async function _runLogin({ callId, timeoutMs, botType, emit, isAborted }) {
emit({
action: 'event',
event: 'qrcode',
// url = qrcode_img_content: the WeChat URL encoded inside the QR image (use this for QR rendering)
// code = qrcode: the polling ticket used by _pollQRStatus (NOT for QR rendering)
data: { url: activeLogin.qrcodeUrl, code: activeLogin.qrcode, expire: 30, index: qrRefreshCount },
});
log.info('weixin', `callId=${callId} qrcode emitted index=${qrRefreshCount}`);