Introduction

Not sure how you ended up here? Cool, neither are we but there is a strong assumption you are interested in graphQL or anime. Use this documentation to help you get the most out of the NarutoQL API.

You can query the api at https://narutoql.up.railway.app/graphql

Contribute

This could definitely use some improvements. Feel free to fork the repo here

Info

Use the Info type to get the metadata you need for total count and pagination. All types have an Info type on them.

Info Schema

FieldTypeDescription
countIntNumber of records.
pagesIntTotal pages.
nextIntNumber of next page. Will be null if it doesn't exist
prevIntNumber of previous page. Will be null if it doesn't exist
Sample Query/Response
{
  characters(filter: {village: "leaf"}) {
    info {
      count
      pages
      next
      prev
    }
  }
}
{
  "data": {
    "characters": {
      "info": {
        "count": 157,
        "pages": 4,
        "next": 2,
        "prev": null
      }
    }
  }
}

Character

One of the more interesting data points of the API. Characters are sorted by name.

Character Schema

FieldTypeDescription
ageStringAge of character
avatarSrcStringURL for avatar image.
descriptionStringBrief description about character.
firstAnimeAppearanceStringFirst anime appearance of character.
firstMangaAppearanceStringFirst manga appearance of character.
_idIDID of character, helpful when trying to query individual character.
nameStringName of character.
nameMeaningStringMeaning of characters name. Super deep stuff.
notableFeaturesStringNoteable features of character.
rankStringRank of character (ex: chuunin/jounin)
villageStringVillage of character.

Get Single Character

Getting a single clan is simple. We recommend using the clans query to find the clan ID you're looking for.

Sample Query/Response
{
  character(id: "61bd1dbc918f12c17b9c6483") {
    name
    avatarSrc
    description
    village
  }
}
{
  "data": {
    "character": {
      "name": "Aburame Shibi",
      "avatarSrc": "https://narutoql.s3.amazonaws.com/Aburame2.jpg",
      "description": "Aburame Shibi is the father of Aburame Shino. Like his son, his body is also inhabited by the destruction bugs.",
      "village": "leaf village"
    }
  }
}

Get All Characters

Use the characters query to get all characters. See filtering section below for available parameters.

Sample Query/Response
{
  characters(filter: {village: "leaf"}) {
    info {
      count
      pages
      next
      prev
    }
    results {
      _id
      name
      avatarSrc
      description
      rank
      village
    }
  }
}
{
  "data": {
    "characters": {
      "info": {
        "count": 157,
        "pages": 8,
        "next": 2,
        "prev": null
      },
      "results": [{
        "_id": "5f9fa4187f9c8a2e250e0225",
        "name": "ANBU Captain",
        "avatarSrc": "https://narutoql.s3.amazonaws.com/ANBU2.jpg",
        "description": "This ANBU captain serves in Leaf Village.",
        "rank": "Jounin",
        "village": "leaf village"
      },
      {
        "_id": "5f9fa4187f9c8a2e250e0226",
        "name": "ANBU Member",
        "avatarSrc": "https://narutoql.s3.amazonaws.com/ANBUYakumo.jpg",
        "description": "This ANBU member was charged with protecting the villa housing Kurama Yakumo. He and medical ninja were directed to keep Yakumo at the villa so her strong Genjutsu powers would be contained.",
        "rank": "Unknown (Probable Chuunin)",
        "village": "leaf village"
      }]
    }
  }
}

Filter Characters

A character query can take a Filter InputType.

Available parameters:

  • name - name of character
  • rank - rank of character
  • village - village of character
Sample Query/Response
{
  characters(filter: {name: "sasuke", village: "leaf"}) {
    info {
      count
      pages
      next
      prev
    }    
    results {
     _id
      name
      avatarSrc
      description
      rank
      village
    }
  }
}
{
  "data": {
    "characters": {
      "info": {
        "count": 2,
        "pages": 1,
        "next": null,
        "prev": null
      },
      "results": [{
        "_id": "5f9fa4187f9c8a2e250e02db",
        "name": "Sarutobi Sasuke",
        "avatarSrc": "https://narutoql.s3.amazonaws.com/NAI.jpg",
        "description": "Sarutobi Sasuke was the well known father of Sarutobi Hiruzen, the Sandaime Hokage. Uchiha Mikoto and Fugaku would later name their second son after the man.",
        "rank": "",
        "village": "leaf village"
      },
      {
        "_id": "5f9fa4187f9c8a2e250e0206",
        "name": "Uchiha Sasuke",
        "avatarSrc": "https://narutoql.s3.amazonaws.com/Sasuke.jpg",
        "description": "A Genin from the village of Konoha, Uchiha Sasuke is one of the last surviving members of the Uchiha clan. This clan is known for the genetic ability to use the Sharigan eye. This eye allows its users to copy any jutsu technique their opponent uses. Sasuke's clan was killed by his older brother Itachi, because of that he has devoted his life to killing his brother.",
      "rank": "Genin - Team 7",
      "village": "leaf village"
      }]
    }
  }
}

Clan

Clan info and things...

Clan Schema

FieldTypeDescription
ageStringAge of character
avatarSrcStringURL for avatar image.
descriptionStringBrief description about character.
firstAnimeAppearanceStringFirst anime appearance of character.
firstMangaAppearanceStringFirst manga appearance of character.
_idIDID of character, helpful when trying to query individual character.
nameStringName of character.
nameMeaningStringMeaning of characters name. Super deep stuff.
notableFeaturesStringNoteable features of character.
rankStringRank of character (ex: chuunin/jounin)
villageStringVillage of character.

Get Single Clan

Getting a single character is simple. We recommend using the clans query to find the character ID you're looking for.

Sample Query/Response
{
  clan(id: "61bd1dbc918f12c17b9c646e") {
    avatarSrc
    description
    name
    signatureAbilities
    village
  }
}
{
  "data": {
    "clan": {
      "avatarSrc": "http://www.leafninja.com/images/information/Aburame.jpg",
      "description": "This clan from Konoha Village is known for its ties to insect. At birth clan members form an agreement with bugs to inhabit and feed on the chakra their body creates. In return the bugs will serve the commands of the clan member.",
      "name": "Aburame Clan",
      "signatureAbilities": "Kikaichuu no Jutsu",
      "village": "leaf village"
    }
  }
}

Get All Clans

Use the clans query to get all characters. See filtering section below for available parameters.

Sample Query/Response
{
  clans {
    results {
      name    
      description
      avatarSrc
      village
    }
  }
}
{
  "data": {
    "clans": [
      {
        "name": "Aburame Clan",
        "description": "This clan from Konoha Village is known for its ties to insect. At birth clan members form an agreement with bugs to inhabit and feed on the chakra their body creates. In return the bugs will serve the commands of the clan member.",
        "avatarSrc": "https://narutoql.s3.amazonaws.com/Aburame.jpg",
        "village": "leaf village"
      },
      {
        "name": "Akimichi Clan",
        "description": "This clan from Konoha Village is known for its ability to modify the size of its body, increasing their mass to a large spherical ball. In this form it is difficult for the clan user to take physical damage. The Akimichi clan have worked along side the Nara and Yamanaka clans for many generations. With each new generation, the clan member swears an oath to defend the honor of the previous generation and also raise a new generation to look after the village.",
        "avatarSrc": "https://narutoql.s3.amazonaws.com/AkimichiClan.jpg",
        "village": "leaf village"
      },
    }
  }
}

Filter Clans

A clans query can take a Filter InputType.

Available parameters:

  • village - village of clan
Sample Query/Response
{
  clans(village: "leaf") {
    results {
      name    
      description
      avatarSrc
      village 
    }
  }
}
{
  "data": {
    "clans": [{
        "name": "Aburame Clan",
        "description": "This clan from Konoha Village is known for its ties to insect. At birth clan members form an agreement with bugs to inhabit and feed on the chakra their body creates. In return the bugs will serve the commands of the clan member.",
        "avatarSrc": "https://narutoql.s3.amazonaws.com/Aburame.jpg",
        "village": "leaf village"
      },
      {
        "name": "Akimichi Clan",
        "description": "This clan from Konoha Village is known for its ability to modify the size of its body, increasing their mass to a large spherical ball. In this form it is difficult for the clan user to take physical damage. The Akimichi clan have worked along side the Nara and Yamanaka clans for many generations. With each new generation, the clan member swears an oath to defend the honor of the previous generation and also raise a new generation to look after the village.",
        "avatarSrc": "https://narutoql.s3.amazonaws.com/AkimichiClan.jpg",
        "village": "leaf village"
      }]
    }
  }
}

Village

Village things!

Village Schema

FieldTypeDescription
_idIDID of village, helpful when trying to query individual village.
nameStringName of village.

Get Single Village

Getting a single village is simple. We recommend using the clans query to find the village ID you're looking for.

Sample Query/Response
{
  village(id: "61bd1dbc918f12c17b9c6460") {
    _id
    name
  }
}
{
  "data": {
    "village": {
      "_id": "61bd1dbc918f12c17b9c6460",
      "name": "cloud village"
    }
  }
}

Get All Villages

Use the village query to get all villages.

Sample Query/Response
{
  villages {
    results {
      _id
    }
  }
}
{
  "data": {
    "villages":[{
        "_id": "5f9fa4177f9c8a2e250e0124",
        "name": "leaf village"
      },
      {
        "_id": "5f9fa4177f9c8a2e250e0125",
        "name": "rock village"
      }]
    }
  }
}