⚡✨⚡

HP-API

A magical JSON API for Harry Potter characters, spells, and the wizarding world

Gryffindor Hufflepuff Ravenclaw Slytherin
🪄

Configure Your Base URL

📜

Magical Endpoints

👤

/api/characters

GET

Returns all characters (wizards, witches, magical creatures)

curl -s {base}/api/characters | jq .
fetch('{base}/api/characters').then(r=>r.json())
🔍

/api/character/:id

GET

Find a specific character by their unique ID

curl -s {base}/api/character/9e3f7ce4-b9a7-4244-b709-dae5c1f1d4a8 | jq .
🎓

/api/characters/students

GET

Retrieve all Hogwarts students (past and present)

curl -s {base}/api/characters/students
👨‍🏫

/api/characters/staff

GET

Access information about Hogwarts faculty and staff

curl -s {base}/api/characters/staff
🏠

/api/characters/house/:house

GET

Find characters from a specific Hogwarts house

curl -s {base}/api/characters/house/gryffindor

/api/spells

GET

Discover all magical spells and their incantations

curl -s {base}/api/spells | jq .
📃

Magical Response

Response from Hogwarts
{
  "message": "Cast a spell by clicking any endpoint above...",
  "hint": "The magic will appear here!"
}
🦉

How to Use This Magic

1

Choose Your Server

Select between production or local server from the dropdown

2

Select an Endpoint

Pick from characters, spells, houses, or specific searches

3

Cast Your Spell

Click "Try This Spell" or customize parameters first

4

Receive Magic

View, format, or download the magical JSON response