This past week I began working on a new personal project. I am collaborating with a fellow Flatiron alumna to create a jeopardy-like game. We decided that since we aren't on a deadline, that we would take this opportunity to learn and implement new skills, features, and tools.
One new tool I started using while building the rails backend, is Postman. Once I created controller methods and routes the steps are fairly easy. For example, to simulate login,
- Run rails server
- Select POST from the method drop down list
- Write out or copy/paste the login url
- In the Body tab, enter the credentials or parameters as key value pairs.
- Hit send and review the response.(My login method will either return user json or an error message.)
I was able to test login, signup, and check if JSON Web Tokens were being created, encoded, and decoded.
I would highly recommend utilizing this tool for anyone building out APIs.
Top comments (0)