File tree Expand file tree Collapse file tree 1 file changed +14
-1
lines changed Expand file tree Collapse file tree 1 file changed +14
-1
lines changed Original file line number Diff line number Diff line change 11# spectrum.py
22
33spectrum.py is a [ discord.py] ( https://github.com/Rapptz/discord.py ) style proof-of-concept library for making chatbots
4- for Star Citizen's [ Spectrum] ( https://robertsspaceindustries.com/spectrum/community/SC ) chat client.
4+ for Star Citizen's [ Spectrum] ( https://robertsspaceindustries.com/spectrum/community/SC ) chat client. It also offers HTTP clients for interacting
5+ with both Spectrum's REST API and the Community Hub's GraphQL API.
56
67## Installation
78``` shell
@@ -59,6 +60,18 @@ async def run():
5960asyncio.run(run())
6061```
6162
63+ ### Community Hub
64+ ``` python
65+ import asyncio
66+ from spectrum import CommunityHubClient
67+
68+ async def run ():
69+ client = CommunityHubClient()
70+ print (await client.fetch_user_profile(" Khuzdul" ))
71+
72+ asyncio.run(run())
73+ ```
74+
6275## Authentication
6376The bot can be run in a read only state without any authentication.
6477If you want to be able to send messages or read private messages (and eventually do other things),
You can’t perform that action at this time.
0 commit comments