code: func ConvertByJSON(src, target interface{}) error {
  	newBytes, err := json.Marshal(src)
  	if err != nil {
  		return err
  	}
  
  	err = json.Unmarshal(newBytes, target)
  	if err != nil {
  		logrus.Errorf("Failed to unmarshall: %v\n%s", err, string(newBytes))
  	}
  	return err
  }
docs: // ConvertByJSON converts a struct (src) to another one (target) using json marshalling/unmarshalling.
  // If the structure are not compatible, this will throw an error as the unmarshalling will fail.