public Reaction CreateReaction(ReactionCreationProperties properties) { return(Client.CreateGuildReaction(Id, properties)); }
public static Reaction CreateGuildReaction(this DiscordClient client, long guildId, ReactionCreationProperties properties) { var resp = client.HttpClient.Post($"/guilds/{guildId}/emojis", JsonConvert.SerializeObject(properties)); if (resp.StatusCode == HttpStatusCode.NotFound) { throw new GuildNotFoundException(client, guildId); } Reaction reaction = JsonConvert.DeserializeObject <Reaction>(resp.Content.ReadAsStringAsync().Result); reaction.Client = client; reaction.GuildId = guildId; return(reaction); }