andshrew / PlayStation-Trophies

Sony has an API for retrieving details of the trophies an account has earned, but there is no public documentation for using it. This is an attempt at documenting the API by capturing the requests made by the https://my.playstation.com web site.
MIT License
104 stars 4 forks source link

Problem with the Get-AuthenticationToken method #3

Closed ghost closed 3 years ago

ghost commented 3 years ago

First, congratulations for the amazing work on this project, very impressive indeed.

I'm having some trouble when I try to use the Get-AuthenticationToken method with my npsso string. it throws me the following error message:

image

Do you know what could possibly be the solution for this?

andshrew commented 3 years ago

Hi @rafaelfgyn - thanks for that.

Are you using Powershell 7? You can check by running $PSVersionTable. If you don't have it you can download it from https://github.com/PowerShell/PowerShell#get-powershell

It has a few enhancements over Powershell 5.1 - which is included with Windows 10 - especially when it comes to making web requests with Invoke-WebRequest and Invoke-RestMethod. All of the examples here and the Get-AuthenticationToken method depend on these new features and I think this is what is causing your error.

Andrew

ghost commented 3 years ago

Yeah, It was that what happen. Problem solved. Thanks a lot!