func (r *Resource) ModifyEmoji(ctx context.Context, emojiID, name string, roles []string) (*discord.Emoji, error) {
	return r.ModifyEmojiWithReason(ctx, emojiID, name, roles, "")
}
ModifyEmoji is like ModifyEmojiWithReason but with no particular reason.
package guild
import (
	"context"
	"encoding/json"
	"net/http"
	"github.com/skwair/harmony/discord"
	"github.com/skwair/harmony/internal/endpoint"
	"github.com/skwair/harmony/internal/rest"
)
func (r *Resource) Emojis(ctx context.Context) ([]discord.Emoji, error) {
	e := endpoint.ListGuildEmojis(r.guildID)
	resp, err := r.client.Do(ctx, e, nil)
	if err != nil {
		return nil, err
	}
	defer resp.Body.Close()
	if resp.StatusCode != http.StatusOK {
		return nil, discord.NewAPIError(resp)
	}
	var emojis []discord.Emoji
	if err = json.NewDecoder(resp.Body).Decode(&emojis); err != nil {
		return nil, err
	}
	return emojis, nil
}
func (r *Resource) Emoji(ctx context.Context, emojiID string) (*discord.Emoji, error) {
	e := endpoint.GetGuildEmoji(r.guildID, emojiID)
	resp, err := r.client.Do(ctx, e, nil)
	if err != nil {
		return nil, err
	}
	defer resp.Body.Close()
	if resp.StatusCode != http.StatusOK {
		return nil, discord.NewAPIError(resp)
	}
	var emoji discord.Emoji
	if err = json.NewDecoder(resp.Body).Decode(&emoji); err != nil {
		return nil, err
	}
	return &emoji, nil
}
func (r *Resource) NewEmoji(ctx context.Context, name, image string, roles []string) (*discord.Emoji, error) {
	return r.NewEmojiWithReason(ctx, name, image, roles, "")
}
func (r *Resource) NewEmojiWithReason(ctx context.Context, name, image string, roles []string, reason string) (*discord.Emoji, error) {
	st := struct {
		Name  string   `json:"name"`
		Image string   `json:"image"`
		Roles []string `json:"roles"`
	}{
		Name:  name,
		Image: image,
		Roles: roles,
	}
	b, err := json.Marshal(st)
	if err != nil {
		return nil, err
	}
	e := endpoint.CreateGuildEmoji(r.guildID)
	resp, err := r.client.DoWithHeader(ctx, e, rest.JSONPayload(b), rest.ReasonHeader(reason))
	if err != nil {
		return nil, err
	}
	defer resp.Body.Close()
	if resp.StatusCode != http.StatusCreated {
		return nil, discord.NewAPIError(resp)
	}
	var emoji discord.Emoji
	if err = json.NewDecoder(resp.Body).Decode(&emoji); err != nil {
		return nil, err
	}
	return &emoji, nil
}