func (c *Client) DeleteFirewallGroup(groupID string) error {
	values := url.Values{
		"FIREWALLGROUPID": {groupID},
	}
	if err := c.post(`firewall/group_delete`, values, nil); err != nil {
		return err
	}
	return nil
}
DeleteFirewallGroup deletes an existing firewall group
package lib
import (
	"encoding/json"
	"fmt"
	"net"
	"net/url"
	"sort"
	"strconv"
	"strings"
)
type FirewallGroup struct {
	ID            string `json:"FIREWALLGROUPID"`
	Description   string `json:"description"`
	Created       string `json:"date_created"`
	Modified      string `json:"date_modified"`
	InstanceCount int    `json:"instance_count"`
	RuleCount     int    `json:"rule_count"`
	MaxRuleCount  int    `json:"max_rule_count"`
}
type FirewallRule struct {
	RuleNumber int    `json:"rulenumber"`
	Action     string `json:"action"`
	Protocol   string `json:"protocol"`
	Port       string `json:"port"`
	Network    *net.IPNet
	Notes      string `json:"notes"`
}
type firewallGroups []FirewallGroup
func (f firewallGroups) Len() int      { return len(f) }
func (f firewallGroups) Swap(i, j int) { f[i], f[j] = f[j], f[i] }
func (f firewallGroups) Less(i, j int) bool {
	return strings.ToLower(f[i].Description) < strings.ToLower(f[j].Description)
}
type firewallRules []FirewallRule
func (r firewallRules) Len() int      { return len(r) }
func (r firewallRules) Swap(i, j int) { r[i], r[j] = r[j], r[i] }
func (r firewallRules) Less(i, j int) bool {
	return r[i].RuleNumber < r[j].RuleNumber
}
func (r *FirewallRule) UnmarshalJSON(data []byte) (err error) {
	if r == nil {
		*r = FirewallRule{}
	}
	var fields map[string]interface{}
	if err := json.Unmarshal(data, &fields); err != nil {
		return err
	}
	value := fmt.Sprintf("%v", fields["rulenumber"])
	if len(value) == 0 || value == "<nil>" {
		value = "0"
	}
	number, err := strconv.ParseInt(value, 10, 64)
	if err != nil {
		return err
	}
	r.RuleNumber = int(number)
	value = fmt.Sprintf("%v", fields["subnet_size"])
	if len(value) == 0 || value == "<nil>" {
		value = "0"
	}
	subnetSize, err := strconv.ParseInt(value, 10, 64)
	if err != nil {
		return err
	}
	r.Action = fmt.Sprintf("%v", fields["action"])
	r.Protocol = fmt.Sprintf("%v", fields["protocol"])
	r.Port = fmt.Sprintf("%v", fields["port"])
	r.Notes = fmt.Sprintf("%v", fields["notes"])
	subnet := fmt.Sprintf("%v", fields["subnet"])
	if subnet == "<nil>" {
		subnet = ""
	}
	if len(subnet) > 0 {
		_, r.Network, err = net.ParseCIDR(fmt.Sprintf("%s/%d", subnet, subnetSize))
		if err != nil {
			return fmt.Errorf("Failed to parse subnet from Vultr API")
		}
	} else {
		_, r.Network, _ = net.ParseCIDR("0.0.0.0/0")
	}
	return
}
func (c *Client) GetFirewallGroups() ([]FirewallGroup, error) {
	var groupMap map[string]FirewallGroup
	if err := c.get(`firewall/group_list`, &groupMap); err != nil {
		return nil, err
	}
	var groupList []FirewallGroup
	for _, g := range groupMap {
		groupList = append(groupList, g)
	}
	sort.Sort(firewallGroups(groupList))
	return groupList, nil
}
func (c *Client) GetFirewallGroup(id string) (FirewallGroup, error) {
	groups, err := c.GetFirewallGroups()
	if err != nil {
		return FirewallGroup{}, err
	}
	for _, g := range groups {
		if g.ID == id {
			return g, nil
		}
	}
	return FirewallGroup{}, fmt.Errorf("Firewall group with ID %v not found", id)
}
func (c *Client) CreateFirewallGroup(description string) (string, error) {
	values := url.Values{}
	if len(description) > 0 {
		values.Add("description", description)
	}
	var result FirewallGroup
	err := c.post(`firewall/group_create`, values, &result)
	if err != nil {
		return "", err
	}
	return result.ID, nil
}