code: private void requestAccountName() {
          GraphUserCallback callback = new GraphUserCallback() {
              @Override
              public void onCompleted(GraphUser user, Response response) {
                  FacebookSettingsActivity activity = (FacebookSettingsActivity) getActivity();
                  if (activity == null || activity.isFinishing()) {
                      return;
                  }
  
                  if (response != null && response.getError() == null && user != null) {
                      String accountName = user.getFirstName() + " " + user.getLastName();
                      if (accountName != null && accountName.length() > 0) {
                          activity.mAccountName = accountName;
                      } else {
                          activity.mHasErrorOccurred = true;
                      }
                  } else {
                      activity.mHasErrorOccurred = true;
                  }
  
                  activity.tryFinish();
              }
          };
  
          mFacebookEndpoint.requestAccountName(callback);
      }
docs: Asynchronously requests the user name associated with the linked account. Tries to finish the
  {@link FacebookSettingsActivity} when completed.