How can I force a facebook access token to expire?

前端 未结 8 1682
执念已碎
执念已碎 2020-12-23 12:00

I\'m doing some testing in the wake of offline_access\'s expiration. I think that since all interactions my app makes with Facebook are done via my servers and are user ini

8条回答
  •  粉色の甜心
    2020-12-23 12:26

    But it says right there in the documentation, just after the last line you quoted:

    App Access Tokens generally do not expire. Once generated, they are valid indefinitely. However, if you need to invalidate your App Access Token for some reason, you can reset your App Secret in your app's settings. Once your App Secret has been reset, you will need to go through the steps below to generate a new app access token.

    So for your testing purposes reset the app secret key.


    Edit

    Oh, I completely misunderstood you.
    It's easier to invalidate a user token, you just use the me/permissions connection with a DELETE request.

    That will remove the app for the logged in user.
    You can try that from the explorer tool, just select DELETE on the select box left to the path field.

提交回复
热议问题