In my application, I am allowing users to authenticate their Tiktok accounts via oauth. About 90% of the time there are no issues and the oauth code given by Tiktok can exchanged for an access token. The rest of the time however, I am running in to an error that looks like this:
{"code":40115,"message":"Timestamp has expired.","request_id":"someRequestId"}
I tried checking the time between the callback request starting and the request to exchange the code for the access token. The time difference here seems very small (1 second or less) so I am not sure why this problem is occurring.
The problem also seems to be intermittent. An account that runs in to this error once might not run in to it if they try and authenticate their account again.