Skip to content

Explore a RESTful API filled with your favorite Harry Potter characters perfect for creating enchanting projects. ๐Ÿง™โ€โ™‚๏ธโšก Built for developers and fans alike, this open-source API allows you to fetch character data, integrate it into your apps, and contribute to its growth.

License

Notifications You must be signed in to change notification settings

CarlosLeonCode/Harry-Potter-Open-API

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

42 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
hp-open-api

railsVersion rubyVersion

GitHub last commit GitHub Release Date

โšก Harry Potter Open API

A RESTful OPEN API for the Wizarding World.
Access data about characters, creatures, schools, and houses through a simple JSON interface.

View Documentation โ€ข Report Bug โ€ข Request Feature


๐Ÿ“œ Documentation

Base URL

https://harry-potter-open-api-ff4c7a51ed23.herokuapp.com

Endpoints

Resource Method Endpoint Description
Schools GET /api/v1/schools List all wizarding schools
Houses GET /api/v1/school_houses List all school houses
House Details GET /api/v1/school_houses/:id Get a specific house by ID
Characters GET /api/v1/people List all characters
Character Details GET /api/v1/people/:id Get a specific character by ID
Students GET /api/v1/people/students List only students
Creatures GET /api/v1/creatures List all magical creatures
Creature Details GET /api/v1/creatures/:id Get a specific creature by ID

๐Ÿง™โ€โ™‚๏ธ Contributing & Local Setup

We welcome all contributions: bug fixes, data contributions, and magical recommendations!

1. Fork & Clone

First, fork the project to your personal account. Then clone it:

git clone [email protected]:yourAccount/harry_potter_open_api.git
cd harry_potter_open_api
2. Dependencies & Database

Make sure you have the correct Ruby and Rails versions installed.

  1. Configure Database:
    Create a config/database.yml file with your local settings.
    Use this guide for reference.

  2. Install Gems:

    bundle install
  3. Setup Database:

    rails db:create
    rails db:migrate
3. Import Magical Data (Seeding)

Populate your local database using the custom Excel importer task:

bundle exec rake hp_data:build

Note: This parses the data.xlsx file and populates tables ensuring no duplicates.

4. Run the Server
rails s

Access the API at http://localhost:3000/api/v1/...


๐Ÿ”ฎ Roadmap / TO DO

  • Add Wizard Professions model
  • Add Spells model
  • Add Potions model
  • Add filtering and pagination

๐Ÿ‘ Credits

Special thanks to these resources for keeping the magic alive:


๐Ÿ“ƒ License

This project is available as open source under the terms of the MIT License.

About

Explore a RESTful API filled with your favorite Harry Potter characters perfect for creating enchanting projects. ๐Ÿง™โ€โ™‚๏ธโšก Built for developers and fans alike, this open-source API allows you to fetch character data, integrate it into your apps, and contribute to its growth.

Topics

Resources

License

Code of conduct

Contributing

Stars

Watchers

Forks

Contributors 2

  •  
  •  

Languages