nano-shino / genshinhelper

A Discord bot to help with daily Genshin activities
MIT License
33 stars 11 forks source link

Pulling codes from Genshin Wiki #13

Open mchangrh opened 4 months ago

mchangrh commented 4 months ago

I'm not sure if my serverless worker can handle the load, but you can easily extract the codes with regex

https://github.com/mchangrh/genshin-code-worker/blob/main/src/worker.js

also licenced MIT, I can also work on it if desired

nano-shino commented 4 months ago

Currently the bot gets codes from https://www.pockettactics.com/genshin-impact/codes by default. Any reason to add this extra source?

mchangrh commented 4 months ago

It doesn't require you to fake useragents, the codes are formatted very nicely in the wiki and the wiki seems to be very up-to-date (https://genshin-impact.fandom.com/wiki/Promotional_Code?action=history)