mirror of
https://github.com/RYGhub/royalnet.git
synced 2024-11-23 19:44:20 +00:00
16 lines
456 B
Python
16 lines
456 B
Python
import royalnet.utils as ru
|
|
import royalnet.constellation.api as rca
|
|
|
|
|
|
class ApiDiscordCvStar(rca.ApiStar):
|
|
path = "/api/discord/cv/v1"
|
|
|
|
tags = ["discord"]
|
|
|
|
@rca.magic
|
|
async def get(self, data: rca.ApiData) -> ru.JSON:
|
|
"""Get the members status of a single Discord guild.
|
|
|
|
Equivalent to calling /cv in a chat."""
|
|
response = await self.constellation.call_herald_event("discord", "discord_cv")
|
|
return response
|