1
Fork 0
mirror of https://github.com/RYGhub/royalnet.git synced 2024-11-27 21:44:21 +00:00
royalnet/royalpack/stars/api_discord_cv.py
2020-06-26 16:13:11 +02:00

16 lines
452 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.interface.call_herald_event("discord", "discord_cv")
return response