Guest User

Untitled

a guest
Jan 31st, 2019
112
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.50 KB | None | 0 0
  1. axios
  2. .get(
  3. "http://localhost:8085/api/v1/users",
  4. {},
  5. {
  6. auth: {
  7. username: "sample@gmail.com",
  8. password: "pass@"
  9. }
  10. }
  11. )
  12. .then(resp => console.log(resp))
  13. .catch(err => console.log(err));
  14.  
  15. axios({
  16. method: "get",
  17. baseURL: endpoint,
  18. auth: {
  19. username: "sample@gmail.com",
  20. password: "pass@"
  21. }
  22. })
  23. .then(resp => console.log(resp))
  24. .catch(err => console.log(err));
Add Comment
Please, Sign In to add comment