|
2 years ago | |
---|---|---|
lib | 2 years ago | |
www | 2 years ago | |
README.md | 2 years ago | |
mod.js | 2 years ago |
README.md
DisWho
Deno port of Androz2091/diswho featuring reCaptcha protection, JWT authentication and return URL.
Run using the following command :
PORT=3050 CAPTCHA_PUBLIC_KEY="" CAPTCHA_PRIVATE_KEY="" DISCORD_SECRET="" deno run --allow-env --allow-net --allow-read mod.js
Other optional parameters are SESSION_DURATION
in milliseconds (900000
by default i.e. 15 mins) and JWT_SECRET
(auto-generated by default i.e. any restart will invalidate all active tokens).
Login at /
. If provided, returnUrl
query param will be redirected to, with a diswhoJwt
query param.
Then, make requests to /user/{userId}
using GET
method and Bearer YOUR_JWT_HERE
as authorization
header, which will directly return the untransformed response from https://discord.com/api/v8/users/{userId}
.
Copyright (c) 2021 KaKi87
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.