const response = await fetch(API_URL, {
method: 'POST',
body: JSON.stringify(body),
headers: headers
})
Here API_URL = https://139.59.39.54:53724/business/1.0/verify
Getting error
TypeError: Only absolute URLs are supported
I though maybe the problem with package it doesn't support domain with IP addresses, so I also tried nip.io
.
But still getting same error.
Update
I am using dotenv
for environment variables. So If directly use the domain I don't get error any more.
const response = await fetch("https://139.59.39.54:53724/business/1.0/verify", {
method: 'POST',
body: JSON.stringify(body),
headers: headers
})