5e-srd-api icon indicating copy to clipboard operation
5e-srd-api copied to clipboard

Add some convenience queries to equipment/equipment-category routes

Open Redmega opened this issue 3 years ago • 4 comments

Would be nice to query something like:

  • /api/equipment-categories/weapon?weapon_category=simple
  • /api/equipment-categories/weapon?properties=finesse

I'm sure there are others that folks would find useful.

Redmega avatar Jul 28 '21 03:07 Redmega

Some of this is probably related to https://github.com/5e-bits/5e-database/issues/397

However, the properties would be a nice addition. I'm here for it.

bagelbits avatar Aug 12 '21 20:08 bagelbits

@Redmega Do you think this would be more useful on the /api/equipment route? Putting it on the /api/equipment-categories/weapon route seems odd.

bagelbits avatar Jul 19 '23 20:07 bagelbits

Hmm... I could see it being useful there. I think the initial thought was that properties like weapon_category were mainly on weapons, but I'm sure if we look at the data there might be similar properties that are shared between equipment in general?

Redmega avatar Jul 21 '23 15:07 Redmega

I've been considering adding an equipment_categories field that has an array of all categories that apply to an equipment. Then we don't have 3-4 different fields like we do right now. I assume that would make it a bit cleaner.

bagelbits avatar Jul 24 '23 17:07 bagelbits