跳到主要内容

用密码修改账号(ModifyAccountWithPassword)

AndroidiOSWindows
如果您使用的是 Unreal Engine,请参见 Unreal Engine SDK 的 ModifyAccountWithPassword。

函数定义​

public void ModifyAccountWithPassword(
string oldAccount,
string oldPhoneAreaCode,
string password,
string newAccount,
string newAccountVerifyCode,
string newPhoneAreaCode,
string extraJson = "{}");

入参说明​

参数类型说明
oldAccountstring旧账号
oldphoneAreaCodestring旧账号的手机区域码。如果账号为邮箱注册,则为空。
passwordstring更多信息,请参见 密码规则。
newAccountstring新账号
newAccountVerifyCodestring新账号的验证码
newphoneAreaCodestring新账号的手机区域码。如果账号注册为邮箱,则为空。
extraJsonstring扩展信息

回调处理​

回调处理接口是 AuthAccountResultObserver。回调数据结构是 AccountResult。

回调 ID 是 INTL_AUTH_MODIFY_ACCOUNT。

代码示例​

string oldAccount = "";
string oldPhoneAreaCode = "";
string password = "";
string newAccount = "";
string newAccountVerifyCode = "";
string newPhoneAreaCode = "";

INTLAPI.ModifyAccountWithPassword(oldAccount, oldPhoneAreaCode, password, newAccount,
newAccountVerifyCode, newPhoneAreaCode);