These are chat archives for arenanet/api-cdi

16th
Sep 2016
Shii Kayano
@BryghtShadow
Sep 16 2016 09:39
darthmaim
@darthmaim
Sep 16 2016 13:05
/v2/guild/search is for searching guild name -> guild id (example)
@lye would be cool if /v2/guild/search would also support ?tag=X instead of just ?name=X
Nabrok
@Nabrok
Sep 16 2016 13:07
That could give a long list of results
Archomeda
@Archomeda
Sep 16 2016 13:17
but it would be very awesome :)
Archomeda
@Archomeda
Sep 16 2016 14:04
hmm, does anyone know of a discord bot that will grant permissions if a person is a member of a specific guild?
Nabrok
@Nabrok
Sep 16 2016 14:04
I actually wrote one
It's not in the wild though
Archomeda
@Archomeda
Sep 16 2016 14:05
:(
how mature is it? :P
Edgar Doiron
@Coffee4cr
Sep 16 2016 14:05
PG-13
Nabrok
@Nabrok
Sep 16 2016 14:05
I've done personal tests.
Archomeda
@Archomeda
Sep 16 2016 14:05
oh you @Coffee4cr
Edgar Doiron
@Coffee4cr
Sep 16 2016 14:05
:D
Nabrok
@Nabrok
Sep 16 2016 14:06
Basically it assigns guild members to a role, and if you have roles with the same names as your guild rank names it assigns them to that as well
Archomeda
@Archomeda
Sep 16 2016 14:07
that's exactly what i need :D
care to share? :smile:
Edgar Doiron
@Coffee4cr
Sep 16 2016 14:07
I would love that also
Nabrok
@Nabrok
Sep 16 2016 14:07
Sure
As I said I don't have it public anywhere right now, but I could zip it up
Archomeda
@Archomeda
Sep 16 2016 14:09
that would be amazing
Nabrok
@Nabrok
Sep 16 2016 14:10
It's written in node and uses redis.
Edgar Doiron
@Coffee4cr
Sep 16 2016 14:11
finally a bot in node, all the cool stuff is in other languages
:P
I had started working on one, and wanted to do the similar features that the /r/guildwars2 discord has
with item search and such
but then work became busy
Aralicia
@Aralicia
Sep 16 2016 14:14
Eh. The item search part is very shoddy on the /r/gw2 bot. I did the first version on a slow work day, and improved a bit on it later.
Edgar Doiron
@Coffee4cr
Sep 16 2016 14:15
I'm still waiting for someone to build a version of gw2skills using the api
cause i'm pretty sure whoever was maintaining gw2skills disappeared from the internet
blob
Edgar Doiron
@Coffee4cr
Sep 16 2016 14:25
thanks
Nabrok
@Nabrok
Sep 16 2016 14:26
np
Aralicia
@Aralicia
Sep 16 2016 14:27
motd refresh ? that smart. I wouldn't have though of that.
Archomeda
@Archomeda
Sep 16 2016 14:36
thanks @Nabrok!
i haven't used redis that much, so i'll have a look at that :P
Nabrok
@Nabrok
Sep 16 2016 14:39
If you want to use something else, you should be able to just adapt the functions in lib/db.js
Archomeda
@Archomeda
Sep 16 2016 14:42
oh wait, only guild leaders can access /v2/guild/[:id]/members right?
Nabrok
@Nabrok
Sep 16 2016 14:42
right, it needs a key with guilds permission from the top rank
Archomeda
@Archomeda
Sep 16 2016 14:42
then i'll have to poke my guild leader :P
oh wow, indeed that guild motd refresh, nice
oh, seems i already have redis installed
Archomeda
@Archomeda
Sep 16 2016 14:56
how are users handled that haven't entered an api key yet, but are already in the specified role?
Nabrok
@Nabrok
Sep 16 2016 14:59
It will remove them from those roles. That's line 64 in ranks.js if you want to modify that behavior.
Archomeda
@Archomeda
Sep 16 2016 15:00
hmm, that behavior is alright; i should just remember myself to assign a different role to this bot with the same permissions as the other one then :D
otherwise the existing people might freak out
Archomeda
@Archomeda
Sep 16 2016 15:38
hmm, am i missing something?
bot ready
(node:24890) UnhandledPromiseRejectionWarning: Unhandled promise rejection (rejection id: 1): Error: Unauthorized
(node:24890) UnhandledPromiseRejectionWarning: Unhandled promise rejection (rejection id: 2): Error: Unauthorized
(node:24890) UnhandledPromiseRejectionWarning: Unhandled promise rejection (rejection id: 3): Error: Unauthorized
(node:24890) UnhandledPromiseRejectionWarning: Unhandled promise rejection (rejection id: 4): Error: Unauthorized
(node:24890) UnhandledPromiseRejectionWarning: Unhandled promise rejection (rejection id: 5): Error: Unauthorized
(node:24890) UnhandledPromiseRejectionWarning: Unhandled promise rejection (rejection id: 6): Error: Unauthorized
(node:24890) UnhandledPromiseRejectionWarning: Unhandled promise rejection (rejection id: 7): Error: Unauthorized
should i add a redirect uri to the application on the discord website?
Archomeda
@Archomeda
Sep 16 2016 15:44
or is it because of hammerandchisel/discord-api-docs#119?
ah yup, that did it
Archomeda
@Archomeda
Sep 16 2016 15:51

@Nabrok

Please reply with a key from https://acount.arena.net/applications - include the code UFW91 in the key name field.

yup, that url is totally valid :D

Nabrok
@Nabrok
Sep 16 2016 16:10
crap, did they change the url?
darthmaim
@darthmaim
Sep 16 2016 16:11
no, but they can spell account :D
Nabrok
@Nabrok
Sep 16 2016 16:11
oh, I'm missing a c
Archomeda
@Archomeda
Sep 16 2016 16:11
:D
Nabrok
@Nabrok
Sep 16 2016 16:13
Do you have it up and running at the moment?
Archomeda
@Archomeda
Sep 16 2016 16:13
yes
got it working properly
also yay for figuring out how service and systemctl works again in linux
not sure how fail-proof the bot turns out to be, but we'll see :D
Nabrok
@Nabrok
Sep 16 2016 16:15
yeah, let me know if you have any issues.
Archomeda
@Archomeda
Sep 16 2016 16:15
at least it added me to the member role after i figured out where to disable the ingame roles
Aralicia
@Aralicia
Sep 16 2016 16:15
@Nabrok btw, why don't you use a github repo for it ?
Nabrok
@Nabrok
Sep 16 2016 16:16
Yeah, I probably will.
@Archomeda is !score working for you?
Archomeda
@Archomeda
Sep 16 2016 16:18
oh, i disabled wvw :P
Nabrok
@Nabrok
Sep 16 2016 16:18
ok
I'm having an issue with it not responding to me for some reason.
Archomeda
@Archomeda
Sep 16 2016 16:18
at least i can confirm that the motd is working :tada:
Archomeda
@Archomeda
Sep 16 2016 16:27
what is account supposed to do when i message it to the bot?
Nabrok
@Nabrok
Sep 16 2016 16:27
that is mostly for testing. it's a way to force the bot to check your account data
Archomeda
@Archomeda
Sep 16 2016 16:28
ah alright
well, let me know when you have made a repo :)
Nabrok
@Nabrok
Sep 16 2016 16:29
will do
Archomeda
@Archomeda
Sep 16 2016 16:29
easier to git pull than to manually copy paste everything
Nabrok
@Nabrok
Sep 16 2016 16:29
right
Archomeda
@Archomeda
Sep 16 2016 16:30
plus, pull requests!
Nabrok
@Nabrok
Sep 16 2016 16:30
If you message the bot "showtoken" in a direct message, is that working for you?
Archomeda
@Archomeda
Sep 16 2016 16:30
yeah
Nabrok
@Nabrok
Sep 16 2016 16:31
Hmm
Archomeda
@Archomeda
Sep 16 2016 16:31
gives me the json response
Nabrok
@Nabrok
Sep 16 2016 16:31
So what the heck is going on with mine that I'm not seeing responses.
Archomeda
@Archomeda
Sep 16 2016 16:31
when did it stop working?
because of hammerandchisel/discord-api-docs#119
Nabrok
@Nabrok
Sep 16 2016 16:32
ah
yeah, I hadn't looked at this for a few weeks
Archomeda
@Archomeda
Sep 16 2016 16:33
you might want to include that in the actual call, so that you don't have to include it in the config
Nabrok
@Nabrok
Sep 16 2016 16:33
good idea
yay, now it works
Archomeda
@Archomeda
Sep 16 2016 18:13
also @Nabrok, i really like how you've made it that it requires people to include a 5 character code in the api key name
Edgar Doiron
@Coffee4cr
Sep 16 2016 18:17
I had a website that used api keys, taht required something similar
can't remember which it was
isn't it gw2bltc?
Nabrok
@Nabrok
Sep 16 2016 18:18
I'd seen other people talk about doing that
Not sure who though. It does make sure that it's a key they just created.
It's an unfortunate necessity if you're authenticating (rather than authorizing) with API keys :(
Otherwise someone will "log in" with one of my public keys
Archomeda
@Archomeda
Sep 16 2016 18:19
yeah exactly
Nabrok
@Nabrok
Sep 16 2016 18:20
Right ... I used to run the TC mumble server, I have so many keys from that I could use if I was an unscrupulous person.
You can only really benefit from them on sites that don't require a unique string in the key name
I should add some more stuff to the wiki page that emphasizes that point
ChieftainAlex
@ChieftainAlex
Sep 16 2016 18:35
looks like the countdown after patches is working properly again
Edgar Doiron
@Coffee4cr
Sep 16 2016 19:40
<3
Archomeda
@Archomeda
Sep 16 2016 19:51
:O
nice <3
Archomeda
@Archomeda
Sep 16 2016 20:32
that pr approval system though :O
Archomeda
@Archomeda
Sep 16 2016 20:46
@Nabrok what are your plans for it?
Nabrok
@Nabrok
Sep 16 2016 20:51
Short term I'll probably pluck some low hanging fruit, like returning your fractal level, stuff like that
Longer term I might do some stuff like drop tracking, or pvp match tracking. Could tie that in with the discord "Playing" status to see when people are in game.
and of course when the skirmish stuff comes into the API I'll need to update the wvw scoring.
Archomeda
@Archomeda
Sep 16 2016 20:55
ah right
i would also like message customization etc :D
Nabrok
@Nabrok
Sep 16 2016 20:58
For other languages, or just in general?
Archomeda
@Archomeda
Sep 16 2016 20:58
just in general
and of course module customization in the config
instead of editing discord_bot.js :P
Nabrok
@Nabrok
Sep 16 2016 21:01
Yup, I definitely plan on that
Some of it can be disabled just by leaving the configuration for the bits it needs blank, but should have something more explicit.
Archomeda
@Archomeda
Sep 16 2016 21:05
ah yeah, blank
before i made the wvw world name blank, i commented that out as mentioned in the comment :P
but that crashed the bot
Nabrok
@Nabrok
Sep 16 2016 21:06
yeah
Archomeda
@Archomeda
Sep 16 2016 21:06
wvw role rather
Nabrok
@Nabrok
Sep 16 2016 21:06
I wrote that comment before I tested it, lol
Archomeda
@Archomeda
Sep 16 2016 21:12
also, maybe have commands starting with an exclamation mark, if you are going to integrate in some textchannel on a server?
Nabrok
@Nabrok
Sep 16 2016 21:13
The auth stuff is all in DM, so I left that without the !. I think the only public channel stuff is the wvw scores, and that uses a !
Archomeda
@Archomeda
Sep 16 2016 21:13
ahh alright