Skip to content

coolfriends/mhgu-query

Repository files navigation

mhgu-query

Build Status Maintainability Test Coverage Coverage Status

Perform simple and advanced queries on MHGU data.

Installation

Download this repo and install

$ git clone https://github.com/coolfriends/mhgu-query.git
$ bundle install

Usage

Start the server

$ bundle exec bin/server

Interact with the server using the client

$ bundle exec bin/server

See below for details on the various endpoints.

GET /api/v1/weapons

A route for obtaining data about MHGU weapons

Examples

Get all weapons

http://localhost:3000/api/v1/weapons

Get all Great Swords

http://localhost:3000/api/v1/weapons?wtype=Great Sword

Get all Great Swords and Hunting Horns with the Poison or Fire element

http://localhost:3000/api/v1/weapons?wtype=Great Sword,Hunting Horn&element=Poison,Fire

Get only the final version of every Great Sword

http://localhost:3000/api/v1/weapons?wtype=Great Sword&final=1

GET /api/v1/weapons/meta

A route for obtaining meta level data about MHGU weapons including query parameters and the fields for a Weapon.

Examples

Get the meta data

http://localhost:3000/api/v1/weapons/meta

Development

Setup RVM and install a new Ruby version (>= 2.3). I'm using ruby-2.6.0-preview2.

Download the repository

$ git clone https://github.com/coolfriends/mhgu-query.git

Make a new feature branch

$ git checkout -b my-cool-feature

Make your changes and test

$ bundle exec rake

Make your changes and commit them

$ git commit -am "Wow I really did it"

Push your changes to your feature branch

$ git push origin my-cool-feature

Run the tests

$ rake

Enter DB console session

$ bundle exec bin/db_console
[1] pry(main)> Weapon.count
=> 10877

Then make your pull request in GitHub. See this for more information

Acknowledgments

Thanks to JoeLago for the MHGU Database pulled from https://github.com/JoeLago/MHGUDB-iOS

License

The gem is available as open source under the terms of the MIT License.

About

Perform simple and advanced queries on MHGU data.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published