save_weight endpoint