View Source ExTDLib.Method.SetUsername (ExTDLib v0.0.4)

Changes the editable username of the current user. Returns object_ptr<Ok>.

NameTypeDescription
usernamestringThe new value of the username. Use an empty string to remove the username. The username can't be completely removed if there is another active or disabled username.

More details on telegram's documentation.