const username = '' const password = '' const token = Buffer.from(`${username}:${password}`, 'utf8').toString('base64') const url = 'https://...' axios.post(url, { headers: { 'Authorization': `Basic ${token}` } })