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

[FEATURE REQUEST] Take over steam chat, User to user messaging #427

Open
ZangYUzhang opened this issue Feb 24, 2023 · 7 comments
Open

[FEATURE REQUEST] Take over steam chat, User to user messaging #427

ZangYUzhang opened this issue Feb 24, 2023 · 7 comments

Comments

@ZangYUzhang
Copy link

Taking over Steam chat and realizing the reception and transmission of Steam messages.

Here you can get all the socket addresses for Steamchat: https://api.steampowered.com/ISteamDirectory/GetCMList/v1/?cellid=0

Here you can get information about the currently logged-in account: https://steamcommunity.com/chat/clientjstoken

Finally, connect them together to realize the reception and transmission of messages.

@Gobot1234
Copy link

You can already send messages to users using https://steam.readthedocs.io/en/stable/api/steam.client.user.html#steam.client.user.SteamUser.send_message and you can receive them by listening for the EVENT_CHAT_MESSAGE event with client.on

@ZangYUzhang
Copy link
Author

ZangYUzhang commented Feb 24, 2023

You can already send messages to users using https://steam.readthedocs.io/en/stable/api/steam.client.user.html#steam.client.user.SteamUser.send_message and you can receive them by listening for the EVENT_CHAT_MESSAGE event with client.on

classs team.client.user.SteamUser(steam_id, steam)
Do you know what the parameter steam is? the reuqests.session()?

@Gobot1234
Copy link

Gobot1234 commented Feb 24, 2023

You aren't meant to construct the class yourself, you are meant to use SteamClient.get_user to get user instances as suggested by the docstring

@ZangYUzhang
Copy link
Author

OMG, I still don't know what the second parameter ‘’steam‘’ is in classes SteamUser (steam_id, steam)。 i think the parameter 'steam' s something with my account identity...but how to get it..
also i cant found SteamClient.get_user ... what's that...
I know that to send a steam message, at frist we need open a friend's chat then ISteamMessagesService.SendMessage # 1 message text to send message to friend

Can you give me a sample code?ty very much

@Gobot1234
Copy link

https://steam.readthedocs.io/en/latest/api/steam.client.html#steam.client.SteamClient.get_user

@ZangYUzhang
Copy link
Author

1677345615919
check img, here is no the path of steam > client > 'SteamClient' ?? Where am I stuck??

@Gobot1234
Copy link

It's in __init__.py you import it using from steam.client import SteamClient.

p.s you should probably make this a discussion

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

No branches or pull requests

2 participants