This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import axios from "axios"; // Import axios library for HTTP requests | |
// API_URLs | |
const BASE_URL = "http://117.55.243.59:8000/api/"; // Base URL | |
const REFRESH_TOKEN = BASE_URL + 'token/refresh/'; // Refresh token API endpoint | |
// Function to fetch Auth Token from Local Storage | |
export function getAuthToken(key = "access_token") { | |
// Fetch token from local storage | |
return localStorage.getItem(key); |