# Introduction

GenshinApi is a fan-made Genshin API made with Node JS and MongoDB. The API endpoint is located at

https://genshin-app-api.herokuapp.com/api

# Events

Fetch information regarding current and past events.

# Fetch all events

https://genshin-app-api.herokuapp.com/api/events

# Example Response payload

[
    {
        "imageUrl": "https://uploadstatic-sea.mihoyo.com/contentweb/20210512/2021051222525282025.png",
        "rewards": [
          ...
        ],
        "_id": "609e84fb4e1bf837108449cf",
        "name": "Windtrace",
        "subtitle": "Windtrace, the classic game that hands down Mondstadt's history, is once again being held!\nPlayers will be split into two sides — the Rebels, members of the ancient resistance, and a Hunter sent by the ancient aristocracy — and have a battle of wits in the Contested Zones.",
        "durationStart": "2021/05/14 10:00:00",
        "durationEnd": "2021/05/24 03:59:59",
        "eligibility": "Adventure Rank 20 or above",
        "description": "During the event period, travelers can take part in a game of Windtrace at Gygax's, and obtain Windtrace Coins. Accumulate certain amounts of Windtrace Coins to claim rewards such as Primogems, Event Namecard 'Celebration: Peekaboo!', Character EXP Materials, Mora, and more.\nComplete Windtrace Challenges to obtain additional Mora rewards.",
        "createdAt": "2021-05-14T14:11:07.643Z",
        "__v": 0
      },
      {
          ...
      }
]

# Characters

Fetch information related to characters.

# Fetch all characters

https://genshin-app-api.herokuapp.com/api/characters?infoDataSize=[all/minimal]
infoDataSize is an optional query parameter. The default value is 'minimal'.

# Example Response payload

  • minimal

only sends basic character information like name, iconUrl, rarity, weaponType


{
    "name": "Amber",
    "title": "Champion Glider",
    "element": "Pyro",
    "weaponType": "Bow",
    "gender": "Female",
    "birthday": "August 10",
    "description": "Always energetic and full of life, Amber's the best - albeit only - Outrider of the Knights of Favonius.",
    "cardImageURL": "https://res.cloudinary.com/dnoibyqq2/image/upload/v1617899636/genshin-app/characters/Amber/card.jpg",
    "rarity": 4
}

  • all

sends all information, like talent materials, common ascension materials, constellations, passives etc


{
    "name": "Amber",
    .....
    "talentBook": [...],
    "commonAscensionMaterials": [...],
    "ascensionMaterials": [...],
    "skillTalents" : [...],
    "passiveTalents" : [...]
}

# Fetch single character

https://genshin-app-api.herokuapp.com/api/characters/info/[character_name]?infoDataSize=[all/minimal]
  • Example

    https://genshin-app-api.herokuapp.com/api/characters/info/Hutao?infoDataSize=all
    

# Weapons

Fetch information related to weapons.

# Fetch all weapons

https://genshin-app-api.herokuapp.com/api/weapons?infoDataSize=[all/minimal]

# Example Response payload


[
    {
        "name": "Staff of Homa",
        "baseAtk": "46",
        "iconUrl": "https://res.cloudinary.com/dnoibyqq2/image/upload/v1620834712/genshin-app/weapons/Staff-of-Homa.png",
        "rarity": 5,
        "weaponType": "Polearm",
        "isReleased": true
    },
    ...
]

# Fetch single weapon

https://genshin-app-api.herokuapp.com/api/weapons/info/[weapon_name]?infoDataSize=[all/minimal]

# Example Response Payload


  {
      "name": "Skyrider Sword",
      ...
      "description": "Using an Elemental Burst grants a 12% increase in ATK and Movement SPD for 15s.",
      "isReleased": true,
      "weaponType": "Sword",
      "rarity": 3,
      "source": "Wish",
      "ascensionMaterials": [...],
      "ascensionEnemyDrops": [...],
      "characters": [...]
  }
  
  

# Materials for a given day

Fetch talent materials and weapon ascension materials for a given day

# Fetch Materials

https://genshin-app-api.herokuapp.com/api/generalinfo/materials/[day]
  • day = [Sunday / Monday / Tuesday / Wednesday / Thursday / Friday / Saturday]

# Example Response payload


{
    "talentBooks": [
        {
            "farmingDays": [ 
                "Sunday",
                "Tuesday",
                "Friday"
            ],
            "characters" : [],
            "name":"Diligence",
            "iconUrl":"https://res.cloudinary.com/dnoibyqq2/image/upload/v1620824052/genshin-app/talent-books/diligence/philosophies-of-diligence.png",
            ...
        }
    ],
    "ascensionMaterials": [
        {
            "farmingDays": [ 
                "Sunday",
                "Tuesday",
                "Friday"
            ],
            "weapons" : [],
            "name":"Boreal Wolf's Nostalgia",
            "iconUrl": "https://res.cloudinary.com/dnoibyqq2/image/upload/v1617896905/genshin-app/weapon-ascension-materials/boreal/boreal-wolfs-nostalgia.png",
            ...
        }
    ]
}

# Talent Materials

Fetch talent materials like Tail of Boreas, Dvalin's Claw etc.

# Fetch all Talent Materials

# Example Request

https://genshin-app-api.herokuapp.com/api/talentmaterials?infoDataSize=[minimal/all]
  • default is minimal i.e. no characters information are populated
  • use 'all' if you want basic characters information as well. the response payload will be bigger

# Example Response payload

[
    {
        "characters": [
            "609f73b903adb03e6c9719a1",
            "609f7443715ba53d4cc958da",
            "609f7443715ba53d4cc958db",
            "609f7443715ba53d4cc958dc",
            "609f7443715ba53d4cc958df"
        ],
        "_id": "60a370b564be3136884994e3",
        "name": "Tail of Boreas",
        "iconUrl": "https://res.cloudinary.com/dnoibyqq2/image/upload/v1620824560/genshin-app/talent-boss-items/tail-of-boreas.png",
        "__v": 0
    },
    {
        ...
    }
]

# Fetch single Talent Material

https://genshin-app-api.herokuapp.com/api/talentmaterials/info/[talent_material_name]?infoDataSize=[minimal/all]

# Example Request

https://genshin-app-api.herokuapp.com/api/talentmaterials/info/Bloodjade Branch?infoDataSize=all

# Example Response payload


{
    "characters": [
        {
        "_id": "60a4d3b193b76f18901aae9d",
        "name": "Yanfei",
        "weaponType": "Catalyst",
        "rarity": 4,
        "cardImageURL": "https://res.cloudinary.com/dnoibyqq2/image/upload/v1617899636/genshin-app/characters/yanfei/card.jpg"
        }
    ],
    "_id": "60a4d22e984c49383c6ae0d0",
    "name": "Bloodjade Branch",
    "iconUrl": "https://res.cloudinary.com/dnoibyqq2/image/upload/v1620824560/genshin-app/talent-boss-items/tail-of-boreas.png",
    "__v": 0
}

# Talent Books

Fetch talent books

# Fetch all Talent Books

https://genshin-app-api.herokuapp.com/api/talentbooks?infoDataSize=[minimal/all]
  • default is minimal i.e. no characters information are populated
  • use 'all' if you want basic characters information as well. the response payload will be bigger

# Example Response payload


{
    "name": "Teachings of Ballad",
    "iconUrl": "https://res.cloudinary.com/dnoibyqq2/image/upload/v1620824052/genshin-app/talent-books/ballad/teachings-of-ballad.png",
    "rarity": 2,
    "farmingDays": [
        "Sunday",
        "Wednesday",
        "Saturday"
    ],
    "characters": [
        {
        "name": "Albedo",
        "cardImageURL": "https://res.cloudinary.com/dnoibyqq2/image/upload/v1617899636/genshin-app/characters/Albedo/card.jpg",
        "compressedImageURL": "https://res.cloudinary.com/dnoibyqq2/image/upload/v1617899636/genshin-app/characters/Albedo/compressed.jpg",
        "weaponType": "https://res.cloudinary.com/dnoibyqq2/image/upload/v1617899636/genshin-app/characters/Albedo/compressed.jpg",
        "rarity": 5
        },
        ...
    ],
    ...
}

# Fetch single Talent Book

https://genshin-app-api.herokuapp.com/api/talentbooks/info/[talent_book_name]?infoDataSize=[minimal/all]

# Enemies

Fetch all enemies - Can be filtered by "family" parameters.

# Fetch all Enemies

https://genshin-app-api.herokuapp.com/api/enemies?family=[family_name]

family parameter is optional. If it is not provided, all enemies are fetched.

family = [Slime, Hilichurl, Whopperflower, Fatui, Treasure Hoarder, Abyss Order, Automatons, Elemental Lifeforms, Mystical Beasts, Unique Enemies ]

# Example Request

https://genshin-app-api.herokuapp.com/api/enemies?family=Slime

# Example Response payload


[
    {
        "drops": [],
        "_id": "609fae275d897b01fcc92486",
        "name": "Anemo Slime",
        "family": "Slime",
        "description": "A small monster created by the coalescing of Anemo dispersed throughout nature.It is able to float in the air due to the power of Anemo.",
        "iconUrl": "https://res.cloudinary.com/dnoibyqq2/image/upload/v1621077122/genshin-app/enemies/slimes/anemo-slime.png",
        "__v": 0
    },
    {
        ...
    }
]

# Fetch single Enemy

https://genshin-app-api.herokuapp.com/api/enemies/info/[enemy_name]

# Example Request

https://genshin-app-api.herokuapp.com/api/enemies/info/Anemo Slime

# Enemy Drops

Fetch all enemy drops - Common and Elite materials. Can be filtered by different parameters.

# Fetch all Enemy Drops

https://genshin-app-api.herokuapp.com/api/enemydrops?infoDataSize=[minimal/all]
  • default is minimal i.e. no characters information are populated

  • use 'all' if you want basic characters information as well. the response payload will be bigger

  • Filters You can filter the response using the following filter parameters:

    • type = [COMMON_ENEMY_MATERIAL / ELITE_ENEMY_MATERIAL / GEMSTONE / WORLD_BOSS_MATERIAL]
    • name (e.g Sharp Arrowhead)
    • rarity (e.g. 1 / 2 / 3)

    # Example Request

    https://genshin-app-api.herokuapp.com/api/enemydrops?infoDataSize=[minimal/all]&type=ELITE_ENEMY_MATERIAL&rarity=2
    

# Example Response payload


[
    {
        "enemyFamily": [
            "Mitachurl",
            "Lawachurl"
        ],
        "_id": "60a11ae2653ed80518dc93ad",
        "name": "Heavy Horn",
        "iconUrl": "https://res.cloudinary.com/dnoibyqq2/image/upload/v1620825967/genshin-app/enemy-drops/heavy-horn.png",
        "rarity": 2,
        "type": "ELITE_ENEMY_MATERIAL",
        "__v": 0
    },
    {
        ...
    }
]

# Fetch single Enemy Drop

https://genshin-app-api.herokuapp.com/api/enemydrops/info/[enemy_drop_name]?infoDataSize=[minimal/all]

# Example Request

https://genshin-app-api.herokuapp.com/api/enemydrops/info/Heavy Horn

# Local Specialties

Fetch all local specialties along with the characters that use them.

# Fetch all Local Specialties

https://genshin-app-api.herokuapp.com/api/localspecialties?infoDataSize=all
  • default is minimal i.e. no characters information are populated
  • use 'all' if you want basic characters information as well. the response payload will be bigger

# Example Request

https://genshin-app-api.herokuapp.com/api/localspecialties?infoDataSize=[minimal/all]

# Example Response payload

[
    {
        "sources": [
            "Found in the wild",
            "Found in Springvale",
            "Sold by Flora"
        ],
        "characters": [
            "609f738f03adb03e6c971995",
            "609f73b903adb03e6c97199a"
        ],
        "_id": "60a37fc762b1d338900ae6e9",
        "name": "Calla Lily",
        "iconUrl": "https://res.cloudinary.com/dnoibyqq2/image/upload/v1620824986/genshin-app/specialties/calla-lily.png",
        "__v": 0
    },
    {
        ...
    }
 ]

# Fetch single Local Specialty

https://genshin-app-api.herokuapp.com/api/localspecialties/info/[specialty_name]?infoDataSize=[minimal/all]

# Example Request

https://genshin-app-api.herokuapp.com/api/localspecialties/info/Calla Lily

# Weapon Ascension Material

Fetch Weapon Ascension Materials like, Boreal Wolf's Milk Tooth, Fragment of Decarabian's Epic etc

# Fetch all Weapon Ascension Materials

https://genshin-app-api.herokuapp.com/api/weaponascensionmaterials?infoDataSize=[all / minimal]&categoryName=[category_name]&rarity=[rarity]

infoDataSize parameter is optional. Default value is minimal.

categoryName and rarity parameter is also optional.

categoryName = [Boreal, Decarabian, Dandelion Gladiator, Guyun, Elixir, Aerosiderite]

rarity = [2, 3, 4, 5]

# Example Request

https://genshin-app-api.herokuapp.com/api/weaponascensionmaterials?categoryName=Decarabian&infoDataSize=all&rarity=4

# Example Response payload


[
    {
        "farmingDays": [
          "Sunday",
          "Monday",
          "Thursday"
        ],
        "weapons": [
          "60a11b147dc6f433bcb7deae",
          "60a11b147dc6f433bcb7deb3",
          "60a11b147dc6f433bcb7deb9",
          "60a11b147dc6f433bcb7decb",
          "60a11b147dc6f433bcb7ded2",
          "60a11b147dc6f433bcb7dee3",
          "60a11b147dc6f433bcb7dee9"
        ],
        "_id": "60a11ac5653ed80518dc9363",
        "name": "Fragment of Decarabian's Epic",
        "categoryName": "Decarabian",
        "rarity": 4,
        "description": "Andrius once declared war upon Decarabian, but failed to even scratch the capital of the Lord of the Tower. If it were not for the song of freedom that shattered the city in an instant, Decarabian's dream would have gone on forever.",
        "iconUrl": "https://res.cloudinary.com/dnoibyqq2/image/upload/v1617896905/genshin-app/weapon-ascension-materials/decarabian/fragment-of-decarabians-epic.png",
        "domainName": "Cecilia Garden",
        "__v": 0
    }
]

# Fetch single Weapon Ascension Material

https://genshin-app-api.herokuapp.com/api/weaponascensionmaterials/info/[name]

# Example Request

https://genshin-app-api.herokuapp.com/api/weaponascensionmaterials/info/Boreal Wolf's Milk Tooth