Files
call-me/app/api/connected/connected.js
T
2024-12-12 09:52:58 +01:00

17 lines
406 B
JavaScript

'use strict';
const url = 'http://localhost:8000/api/v1/connected?user=call-me';
const authorization = 'call_me_api_key_secret';
fetch(url, {
method: 'GET',
headers: {
Authorization: authorization,
'Content-Type': 'application/json',
},
})
.then((response) => response.json())
.then((data) => console.log(data))
.catch((error) => console.error('Error:', error));