Jump to content


Get Access Token in Java


  • Please log in to reply
2 replies to this topic

Hammam_Boutafant #1 Posted 06 June 2018 - 08:17 PM

    Private

  • Player
  • 10056 battles
  • 10
  • [ES-SF] ES-SF
  • Member since:
    08-29-2015
Hi there, I'm developing a Java app for my clan so we can monitor the tanks everyone has easily. The problem is the access token, I know how to get the browser to open an URL, but I don't know how to get the token back, can someone throw some light in here? Thanks.

Red_Dragon_Firkraag #2 Posted 06 June 2018 - 08:45 PM

    Lieutenant

  • Player
  • 15388 battles
  • 1,682
  • Member since:
    08-13-2011

Because the current garage is a security identifier for access restoration for free players who never made a purchase in WoT, this data is confidential and cannot be accessed through the API.

 

The data you request is only available to the player in question. This would require that your Java application logs the player in to retrieve that data. For that, you also need an application ID for client-server use.

 

As this is considered private data, you'd need to fetch consent from the user of that app to stay compliant to the GDPR.

 

Because you'd need to bundle the application ID to your app, and the way Java Bytecode stores variables, it is easily leaked through decompilation. Hence it's not recommended to use Java for such a project.

 

If you wish to ignore the warnings nonetheless, have a look here on how to load data transferred via HTTP(S) in Java: https://docs.oracle....readingURL.html

 

The API OpenID login method is described here: https://developers.w...gin/&r_realm=eu

Then you'd need a JSON parser to work with the result.


Edited by Red_Dragon_Firkraag, 06 June 2018 - 08:58 PM.


Hellvinator #3 Posted 20 July 2018 - 07:02 PM

    Private

  • Player
  • 8663 battles
  • 1
  • Member since:
    10-22-2015
Nvm required info not available thru API

Edited by Hellvinator, 20 July 2018 - 07:04 PM.





4 user(s) are reading this topic

0 members, 4 guests, 0 anonymous users