When I try to login in Unity using the call to “PlayFabClientAPI.LoginWithKongregate” from a webgl game in development on Kongregate, I always receive this error :
blob:https://game278179.konggames.com/9785d10e-6fda-404b-9d51-175e4ea7633f:1[24/4/2017 17:18:01] PlayFabLogin:OnLoginFailure HttpCode:200 HttpStatus:OK Error:ServiceUnavailable ErrorMessage:{"code":200,"status":"OK","data":{"SessionTicket":"AA94A88247313AD4---741A-8D48B5764A84367-F625C50D9A589103.5B67BC4B24B10C00","PlayFabId":"AA94A88247313AD4","NewlyCreated":false,"SettingsForUser":{"NeedsAttribution":false},"LastLoginTime":"2017-04-24T21:07:35.354Z"}} ErrorDetails:(Filename: /Users/builduser/buildslave/unity/build/artifacts/generated/WebGL/runtime/DebugBindings.gen.cpp Line: 51)
When I check in the GameManager, my user is correctly created and reported as logged in.
My plugin is also added for kongregate and setupped with the API key in the gamemanager.
My game is unpublished yet in Kongregate (in development mode).
Note that in the error feedback, I correctly received the good PlayFabID.
“Compress API data” is left unchecked in the editor extention for playfab.
I’m probably doing something wrong but I have not enough information with the error message reported to take the good action. Any Idea?
Kongregate AuthTicket used : 2d695d5d035075f6fedc9075ba9062d9b45aaf510aaf51ac3d666746af45ba9d
Kongregate user ID : 207597
PlayFabTitle ID : 741A
Chrome : 58.0.3029.81
Unity : 5.5.3p1
Playfab SDK : 2.20.170411
Code sample for login in (Called after the kongregate API is successfully loggedin).
public void KongregateLogin(string authTicket, string kongregateId)
{
DebugLog.Log("PlayFabLogin:KongregateLogin {0} {1} {2}", authTicket, kongregateId, TitleID);
var request = new LoginWithKongregateRequest { AuthTicket = authTicket, KongregateId = kongregateId, TitleId = TitleID, CreateAccount = true };
PlayFabClientAPI.LoginWithKongregate(request, OnLoginSuccess, OnLoginFailure);
}
private void OnLoginSuccess(LoginResult result)
{
DebugLog.Log("PlayFabLogin:OnLoginSuccess playFabId:{0}", result.PlayFabId);
PlayFabID = result.PlayFabId;
IsNewlyCreated = result.NewlyCreated;
OnLogin(this, true);
}
private void OnLoginFailure(PlayFabError error)
{
DebugLog.Error("PlayFabLogin:OnLoginFailure HttpCode:{0} HttpStatus:{1} Error:{2} ErrorMessage:{3} ErrorDetails:{4}", error.HttpCode, error.HttpStatus, error.Error, error.ErrorMessage, error.ErrorDetails);
OnLogin(this, false);
}