I'm unable to show a player profile with ShowNativeProfile

Hi!

I implemented the EOS C# SDK on a Unity game already released on the Epic Store. It’s a simple setup, no cross-platform stuff and no integration with Steam or other systems. I only use it to implement achievements and leaderboards on the Epic Store version.

I’m trying to implement the possibility of the player being able to click another player in the leaderboards, and show his/her profile. I’m assuming that I need to use the ShowNativeProfile function. But I’ve tried many things, but I always get the following warning:

[EOS: LogEOSAuth] Unable to get integrated platform id from Epic account id - external account type unset

And the ResultCode of the ShowNativeProfile is NotFound.

Let me add some details about how I’m doing things.

First I call QueryProductUserIdMappings, passing my user as LocalUserId, and the other user’s ProductUserId (obtained from the retrieved leaderboard), and then I use GetProductUserIdMapping:

QueryProductUserIdMappingsOptions queryUserIdOptions = new QueryProductUserIdMappingsOptions()
{
  LocalUserId = <MY_USER>,
  ProductUserIds = new ProductUserId[] { <OTHER_PLAYER_USER_OBTAINED_FROM_LEADERBOARD> }
};

connectInterface.QueryProductUserIdMappings(ref queryUserIdOptions, null, (ref QueryProductUserIdMappingsCallbackInfo data) =>
{
  if (data.ResultCode != Result.Success)
  {
    Utils.LogError($"Error querying Product User Id Mapping from user ID {targetId}. Result: {data.ResultCode}.");
    return;
  }

  // Get EpicAccountId from the queried user

  GetProductUserIdMappingOptions getProductUserIdMappingOptions = new GetProductUserIdMappingOptions()
  {
      LocalUserId = <MY_USER>,
      TargetProductUserId = <OTHER_PLAYER_USER_OBTAINED_FROM_LEADERBOARD>,
      AccountIdType = ExternalAccountType.Epic
  };

  Result result = connectInterface.GetProductUserIdMapping(ref getProductUserIdMappingOptions, out Utf8String idString);

  if (result != Result.Success)
  {
      Utils.LogError($"Error getting Epic Account ID from user ID {targetId}. Result: {result}.");
      return;
  }

  EpicAccountId targetEpicAccountId = EpicAccountId.FromString(idString);
}

Both operations succeed and I’m able to get the EpicAccountID of the user in the leaderboards. Then I can pass the obtained EpicAccountId to ShowNativeProfile:

ShowNativeProfileOptions options = new ShowNativeProfileOptions()
{
  LocalUserId = <MY_USER>,
  TargetUserId = targetEpicAccountId
};

uiInterface.ShowNativeProfile(ref options, null, (ref ShowNativeProfileCallbackInfo data) =>
{
  if (data.ResultCode == Result.Success) Utils.Log($"Showing profile of user ID {data.TargetUserId}.");
  else Utils.LogError($"Error showing profile of user ID {data.TargetUserId}. Result: {data.ResultCode}");
});

And this is where, no matter what I try, I always get the aforementioned warning and a NotFound result code.

I tried some other things to try to figure this out. For example, I tried to get the user’s info with QueryUserInfo and CopyUserInfo:

QueryUserInfoOptions userInfoOptions = new QueryUserInfoOptions()
{
  LocalUserId = <MY_USER>,
  TargetUserId = targetEpicAccountId
};

userInfoInterface.QueryUserInfo(ref userInfoOptions, null, (ref QueryUserInfoCallbackInfo data) =>
{
  if (data.ResultCode != Result.Success)
  {
    Utils.LogError($"Error querying user info: {data.ResultCode}");
    return;
  }

  var copyUserInfoOptions = new CopyUserInfoOptions()
  {
    LocalUserId = eosUsers.EpicAccountId,
    TargetUserId = targetEpicAccountId
  };

  Result copyResult = userInfoInterface.CopyUserInfo(ref copyUserInfoOptions, out UserInfoData? userInfoData);
  if (copyResult != Result.Success)
  {
    Utils.LogError($"Error copying user info: {copyResult}");
    return;
  }
}

This succeeds. I’m able to see the display name, preferred language, etc. (not the country, but I’m guessing that’s because of only having set BasicProfile as ScopeFlags). So this confirms that the user exists and it has been found.

I also tried with my own EpicAccountId obtained when logging in via the AuthInterface. I also get a NotFound result in ShowNativeProfile.

The only mentions of this warning in other forum posts are about people trying to send session invites. None of those threads were resolved. Some people mentioned something about not being logged in or authenticated properly. But I don’t know what to make about that. The login and auth process work fine for me, and I’ve tried several methods just in case:

  • I tried ExternalCredentialType.EpicIdToken and ExternalCredentialType.Epic as Credential types in LoginOptions. I can log in with both methods successfully but didn’t fix my issue.
  • I tried logging in from a standalone build with LoginCredentialType.AccountPortal / LoginCredentialType.PersistentAuth, and also from the Epic Launcher with LoginCredentialType.ExchangeCode. Both work successfully but didn’t fix my issue.

I have also tried EOS SDK 1.15, 1.16, 1.17 and 1.18. All of them had the same issue.

So I’m running out of ideas. Anybody know what could be happening? Maybe ShowNativeProfile is not what I should be using for showing an Epic Account’s profile?

Thanks for your attention.

Hello! The EOS_UI_ShowNativeProfile function is designed to work with the SDK’s native platform integrations for Steam and console platforms.

https://dev.epicgames.com/docs/game-services/eos-platform-interface\#native-platform-integration

For the Epic accounts on the Overlay, there is currently no direct way to bring up another player’s profile.

Instead, you can show or hide the overlay, from which the player can search for another player to interact with.

https://dev.epicgames.com/docs/epic-account-services/eosui-interface\#show-or-hide-an-overlay

https://dev.epicgames.com/docs/epic-account-services/social-overlay-overview/social-overlay-tabs/social