liamcottle / valorant.js

This is an unofficial NodeJS library for interacting with the VALORANT API used in game.
105 stars 19 forks source link

I can't authorize my account. #31

Closed Infinity9591 closed 9 months ago

Infinity9591 commented 1 year ago

I use your API to write discord bot exactly like your example but got 403 error. I'm new to programming so I don't know where I went wrong and how to fix it. I installed your API and here is the code and error I got. Hope to receive your reply soon. image image

rjames1295 commented 1 year ago

I'm not too familiar with Riot's internal API workings, but perhaps the user_agent header value is outdated?

https://github.com/liamcottle/valorant.js/blob/09176a77e77eb93eb2370571d6828f5ee95b8f6a/src/api.js#L36

@liamcottle

SpatzlHD commented 1 year ago

You can try to update the useragent and clientversion

vlrapi.user_agent = "RiotClient/60.0.10.4802528.4749685 rso-auth (Windows;10;;Professional, x64)";
vlrapi.client_version = "release-05.10-shipping-11-796984";
Infinity9591 commented 1 year ago

Uhhh... I want to link my account to my Discord account, pls help me. ;-;