code: func (api OrganizationsAPI) UpdateRequiredScope(w http.ResponseWriter, r *http.Request) {
  	globalID := mux.Vars(r)["globalid"]
  	oldRequiredScope := mux.Vars(r)["requiredscope"]
  	var requiredScope organization.RequiredScope
  	if err := json.NewDecoder(r.Body).Decode(&requiredScope); err != nil {
  		log.Debug("Error while updating a required scope: ", err.Error())
  		http.Error(w, http.StatusText(http.StatusBadRequest), http.StatusBadRequest)
  		return
  	}
  	if !requiredScope.IsValid() {
  		http.Error(w, http.StatusText(http.StatusBadRequest), http.StatusBadRequest)
  		return
  	}
  	mgr := organization.NewManager(r)
  	exists := mgr.Exists(globalID)
  	if !exists {
  		writeErrorResponse(w, http.StatusNotFound, "organization_not_found")
  		return
  	}
  	err := mgr.UpdateRequiredScope(globalID, oldRequiredScope, requiredScope)
  	if err != nil {
  		if err == mgo.ErrNotFound {
  			writeErrorResponse(w, http.StatusNotFound, "required_scope_not_found")
  		} else {
  			handleServerError(w, "updating a required scope", err)
  		}
  	} else {
  		w.WriteHeader(http.StatusNoContent)
  	}
  }
docs: // UpdateRequiredScope is the handler for PUT /organizations/{globalid}/requiredscope/{requiredscope}
  // Updates a required scope