question

FENG LI avatar image
FENG LI asked

/Client/LoginWithFacebook PlayFabError(InvalidFacebookToken, Invalid Facebook token, 400 Bad Request)

Very strange, when we are testing with testflight on iOS in past days, it worked well.

But now we released the game, got this error.

Any tips?

1 comment
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

FENG LI avatar image FENG LI commented ·

/Client/LinkFacebookAccount can not work either right now.

0 Likes 0 ·

1 Answer

·
Seth Du avatar image
Seth Du answered

This error is simply because the Facebook Token is incorrect. You can test the token via RESTful API tools for example, Postman, to see if you can login.

6 comments
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

FENG LI avatar image FENG LI commented ·

Very strange, i have no idea how it can be incorrent, i just login with facebook app and it comfirmed the Authenticating. Facebook app is logined, and works well on my phone.

0 Likes 0 ·
Andy avatar image Andy ♦♦ FENG LI commented ·

Are you sure that the testflight version of your game and the released version use the exact same Facebook AppId and Spp Secret? If they're different, you'll need to update them in PlayFab.

0 Likes 0 ·
FENG LI avatar image FENG LI commented ·

It's same, i did not change anything.

And, our game is released, i found some user can link facebook corretly, but some of them can not. Very strange.

0 Likes 0 ·
Andy avatar image Andy ♦♦ FENG LI commented ·

Is it possible the release version of your game is doing something different in its acquisition of Facebook tokens or the way it provides them to the LinkFacebook API? Try capturing a token from the release build using fiddler or some other tool and then using it to connect via direct Postman API call.

0 Likes 0 ·
FENG LI avatar image FENG LI commented ·

Very strange, maybe it is because the token is expired since the last time I open facebook app is days agao.

But today, i open facebook first, and then try to login in our game, it just works.

0 Likes 0 ·
brendan avatar image brendan FENG LI commented ·

Yes, a current (non-expired) token is required for us to be able to make calls to Facebook on behalf of your player.

0 Likes 0 ·

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.