func (c *Config) SaveCache(response map[string]interface{}) {
	output, _ := json.Marshal(response)
	ioutil.WriteFile(c.CacheFile(), output, 0600)
}
SaveCache saves received auto-discovery data to cache file
package config
import (
	"encoding/json"
	"fmt"
	"io/ioutil"
	"os"
	"sort"
	"strings"
	"unicode"
)
const FAKE = "fake"
type APIArg struct {
	Name        string
	Type        string
	Related     []string
	Description string
	Required    bool
	Length      int
}
type API struct {
	Name         string
	Verb         string
	Noun         string
	Args         []*APIArg
	RequiredArgs []string
	Related      []string
	Async        bool
	Description  string
	ResponseKeys []string
}
var apiCache map[string]*API
var apiVerbMap map[string][]*API
func (c *Config) GetAPIVerbMap() map[string][]*API {
	if apiVerbMap != nil {
		return apiVerbMap
	}
	apiSplitMap := make(map[string][]*API)
	for api := range apiCache {
		verb := apiCache[api].Verb
		apiSplitMap[verb] = append(apiSplitMap[verb], apiCache[api])
	}
	return apiSplitMap
}
func (c *Config) GetCache() map[string]*API {
	if apiCache == nil {
		return make(map[string]*API)
	}
	return apiCache
}
func LoadCache(c *Config) interface{} {
	cacheFile := c.CacheFile()
	Debug("Trying to read API cache from:", cacheFile)
	cache, err := ioutil.ReadFile(cacheFile)
	if err != nil {
		if c.HasShell {
			fmt.Fprintf(os.Stderr, "Loaded in-built API cache. Failed to read API cache, please run 'sync'.\n")
		}
		cache = []byte(preCache)
	}
	var data map[string]interface{}
	_ = json.Unmarshal(cache, &data)
	return c.UpdateCache(data)
}