20 lines
331 B
JavaScript
20 lines
331 B
JavaScript
const axios = require("axios").default;
|
|
|
|
const getTokenFree = async (baseUrl, data = {}) => {
|
|
const url = `${baseUrl}/__free__/api/get_token`;
|
|
return axios({
|
|
method: "POST",
|
|
url: url,
|
|
data: {
|
|
...data,
|
|
},
|
|
headers: {
|
|
"x-access-type": "FREE",
|
|
},
|
|
});
|
|
};
|
|
|
|
module.exports = {
|
|
getTokenFree,
|
|
};
|