Dragon type on SoT/Prov with WebService
Issue #10
resolved
Can we get the Dragon Type on the SoT and/or Prov? In IRC it show a line like "Has an Emerald dragon!" when querying for a !sot. I'd like to see that in the webservice output too.
Comments (3)
-
repo owner -
reporter Excellent! As with both Angel and "!sot" the Intel is at the province level, I thought it would be easiest to get it there, but I was looking for it at the kingdom level in the api myself.
-
repo owner - changed status to resolved
Added in 3.10
- Log in to comment
Well, the dragon is kingdom level data. In the regular bot code it's simple to just access the kingdom data and output the dragon info wherever, but we don't really have that luxury with the api since it can't send everything all the time. Instead of duplicating the dragon data all over I've added a simple resource for checking if the kingdom has a dragon or not:
GET /api/kingdoms/<id>/dragon
It returns a dragon object if a dragon does exist and sends an empty response otherwise.
Good enough?