genshindev/api

Search via Name

ChrisMGeo opened this issue · 1 comments

I'm still pretty new to this API and API's in general, but I was wondering if we could add a PUT or POST request to get a resource using a vague name. For example, my use case has a different format for storing character names, e.g. Albedo, HuTao, etc, and I want to search for their corresponding character resource so I would send a post or put request with a json body like

{
  "name": "Albedo", //HuTao
  "type":"character", // or characters if that helps
}

This returns what is basically on api.genshin.dev/characters/albedo and api.genshin.dev/characters/hu-tao.

Oh ok I got it now so you do api.genshin.dev/characters/all?name=Albedo