.
A little fun building an API that connects to Marvel's Developer Portal and be able to fetch and display data on superheroes, villains, etc.
The following should be installed in your machine:
-
Node JS (Go here for the specific file you need to download and install and other installation instructions)
-
Redis (See here for installation instructions)
.
In order to be able to query Marvel's database you should first create an account here and get your public and private keys.
.
Clone this repository and then run:
npm install
To install all dependencies.
.
Make sure you create a .env
file in the root of the project directory. This .env
file should have the following content:
PORT=8080
REDIS_PORT=6379
PUBLIC_KEY=<your Marvel API public key>
PRIVATE_KEY=<your Marvel API private key>
.
Once you have successfully installed all dependencies and have your .env
file ready run the following in your terminal (make sure you're running your terminal in the project's root directory):
npm start
Also ensure your redis server is running. Please check Redis documentation for more information.
In order to test the API and also view it's documentation please open localhost:8080/api-docs
in your browser.
.
- ExpressJS
- Axios
- Redis
- SwaggerUI (for documentation)