Please, help with this tiny error. Thanks

Hello friends, please can anybody help me? I am getting error in the second line, on new Headers()
Can anyone tell me how to achieve this? Or is there a workaround?
Thanks in advance.

import { fetch } from 'wix-fetch';
const headers = new Headers();
headers.append("Authorization", "Basic Z3JhbmRzdHVkeTpHcm5U3Q4OA==");
headers.append("Content-Type", "application/json");
const raw = JSON.stringify({
"messages": [{
"recipient": "37498664040",
"priority": "2",
"sms": {
"originator": "GrandStudy",
"content": {
"text": "Test"
}
},
"message-id": "201902280917"
}]
});
const requestOptions = {
method: 'POST',
headers: headers,
body: raw,
};
$w.onReady(function () {
fetch("https://sendsms.nikita.am/broker-api/send", requestOptions)
.catch(err => console.log(err));
})

Why are you using new

Hello, thanks for your reply.
It is for Authorization. Can you give me an example without new?

armkhachatryan What is the error you’re getting?

Thanks for reply friend. I was getting CORS error. Fixed already. Thank you.