Find answers from the community

T
Tom
Offline, last seen 3 months ago
Joined September 25, 2024
Hi, I am trying to load conversations from discord using the discord loader but I always get
Plain Text
---------------------------------------------------------------------------

HTTPException                             Traceback (most recent call last)

/usr/local/lib/python3.10/dist-packages/discord/http.py in static_login(self, token)
    802         try:
--> 803             data = await self.request(Route('GET', '/users/@me'))
    804         except HTTPException as exc:

10 frames

HTTPException: 401 Unauthorized (error code: 0): 401: Unauthorized


The above exception was the direct cause of the following exception:

LoginFailure                              Traceback (most recent call last)

/usr/local/lib/python3.10/dist-packages/discord/http.py in static_login(self, token)
    805             self.token = old_token
    806             if exc.status == 401:
--> 807                 raise LoginFailure('Improper token has been passed.') from exc
    808             raise
    809 

LoginFailure: Improper token has been passed.

Which token do I have to pass as an argument? I tried the one from the /api library Authrorisation header without success. Could me using google collab also be an issue?
3 comments
B
T
L