Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[RFC] custom id on Contact #1647

Closed
windmemory opened this issue Nov 19, 2018 · 2 comments
Closed

[RFC] custom id on Contact #1647

windmemory opened this issue Nov 19, 2018 · 2 comments

Comments

@windmemory
Copy link
Member

Recently while working on wechaty-puppet-padpro project, I found that there is a way to get the real wechat id from underlying service. So for each contact, there will be two ids, one is wxid, which is allocated by wechat system, the other one is the use name, which is created by the user.

I am suggesting here to have an optional customId field on Contact class. For developers who want to get the real wechat id, they could try to get the customId first, then fallback to the id, in this way, they will get the id that same as the one on wechat.

Does this make sense?

@huan
Copy link
Member

huan commented Nov 19, 2018

There's already a weixin in ContactPayload, and it was designed for the real wechat id.

Please have a look into it and let me know whether it cloud fulfill your requirement.

@windmemory
Copy link
Member Author

Got it, will assign that value to weixin.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants