protected function apiConfig($key, $default = null)
    {
        $key = 'apis.'.$key;

        if (isset($this->adminConfig[$key])) {
            return $this->adminConfig[$key];
        } elseif (isset($this->appConfig[$key])) {
            return $this->appConfig[$key];
        } elseif (!is_string($default) && is_callable($default)) {
            return $default();
        } else {
            return $default;
        }
    }