Fetch Token - Login

JWT TOKEN - Rest API Login

  • Login using an HTTP POST request by providing username and password
  • Receives a JWT authentication Token for later requests to identify the authorized user
  • Send the Authentication Token with subsequent requests typically HTTP Headers like Authorization: Bearer AUTH_JWT_TOKEN

Login API Specs

Login - http://www.tickermarket.com/TPILWebAPI/Api/V1/Users/Login

Http Method must be a POST Request
Http Scheme http
Hostname Server IP ( e.g www.tickermarket.com)
Port 8080
Path TPILWebAPI/Api/V1/Users/Login (Login Endpoint path)
POST Parameters BODY

{ "username":"DFDEMO0001", "password": "11111111" }

Response JSON Format

{ "token": "eyJhbGciOiJIUzUxMiJ9.eyJzdWIiOiJERkRFTU8wMDAxICAgICAiLCJERkRFTU8wMDAxICAgICAiOiIxNzIuMjAuMTAyLjQyIiwiQXBpS2V5IjoiRlgwMDEtMTAwMCIsImV4cCI6MTYzMDQ5MzcxNSwiaWF0IjoxNjMwNDgxNzE1fQ.5fDEI8lb7Xlc9F3Qogod6HrNg5fRD51T05F--mOC1VIgxPJ2i9h3J1M69m3mT6DEANglPXF0zioQHS46WV5U6Q" }

  • Extracting JWT AUTH TOKEN-Token Based Authentication is a simple mechanism where a token uniquely identifies a user session.
  • Once JSON Extractor is working then we can use the subsequent requests to perform authenticated requests.
Error Response

Code: 401 UNAUTHORIZED
Content: {error : "You are unauthorized to make this request." }

OR

Code: 404 NOT FOUND
Content: {error: "User doesn't exist" }