code: func parseAPIConfig(params map[string]string) (*storageosAPIConfig, error) {
  
  	if len(params) == 0 {
  		return nil, fmt.Errorf("empty API config")
  	}
  
  	c := &storageosAPIConfig{}
  
  	for name, data := range params {
  		switch strings.ToLower(name) {
  		case "apiaddress":
  			c.apiAddr = string(data)
  		case "apiusername":
  			c.apiUser = string(data)
  		case "apipassword":
  			c.apiPass = string(data)
  		case "apiversion":
  			c.apiVersion = string(data)
  		}
  	}
  
  	return c, nil
  }
docs: // Parse API configuration from parameters or secret