Alter Realm

alter realm

For Heroku App

https://immense-refuge-56824.herokuapp.com/api/

About

The backend API for Alter Realm. This API grabs the data from Rick and Morty API and builds a custom

deployed link: https://alterrealms.vercel.app

backend repo: https://github.com/dcartist/alterrealms-api

backend link: https://immense-refuge-56824.herokuapp.com/api

Created by:

Paula Bannerman

Portfolio: https://www.dcartist.studio

LinkedIn: https://www.linkedin.com/in/dcartist

When: built during the Mintbean hackathon Duration of Creation: 1 week

Technologies Used:

  • Express JS

  • MongoDB

Installation Instructions

  • Clone and download the project

  • cd into the project

  • use npm install to install the react app

  • use node index.js to start the project

Response Data:

{
"_id": "612c4c0395a4b3378fd367ed",
"id": 1,
"name": "Rick Sanchez",
"species": "Human",
"origin_name": "Earth (C-137)",
"origin_url": "https://rickandmortyapi.com/api/location/1",
"location_name": "Earth (Replacement Dimension)",
"location_url": "https://rickandmortyapi.com/api/location/20",
"type": "",
"wins": 3,
"rounds": 12,
"image_url": "https://rickandmortyapi.com/api/character/avatar/1.jpeg",
"losses": 4,
"ties": 5,
"__v": 0
}

Routes

GET

all characters:

/api

character by id:

api/character/id/{number}

character by name:

api/character/name/{name or particial name}

characters by species:

api/character/species/{species name or particial name}

Top winners:

api/top/wins

Top losers:

api/top/losses

Top tied players:

api/top/tied

Top players:

api/top/player

Setting winner and looser

/gameplay/results/{winner id}/{loser id}

Setting tie

/gameplay/tie/{winner id}/{loser id}