code: func buildMap(v reflect.Value, onlyFields []string) map[string]interface{} {
  	res := make(map[string]interface{})
  	if onlyFields != nil {
  		for _, onlyField := range onlyFields {
  			fieldType, exist := v.Type().FieldByName(onlyField)
  			if exist {
  				addFieldToMap(true, fieldType, v.FieldByName(onlyField), res)
  			}
  		}
  	} else {
  		for i := 0; i < v.NumField(); i++ {
  			addFieldToMap(false, v.Type().Field(i), v.Field(i), res)
  		}
  	}
  	return res
  }
docs: // buildMap returns a map with fields specified in onlyFields (all fields if nil)
  // and without the read_only fields.