I’m trying to figure out how to send an http header.
I’m just stuck (I’m sure) on syntax. Please advise.
FYI: the page I’m calling just returns the headers, what I’m really trying to do is send an API key to a different URL, but I’m trying to just get the headers to work for now. Thanks!
let user = {
user: "jon",
key: AHDUI9JD8HKHA6E
}
let req = new Request(url)
req.headers = user
let data = await req.loadString()
QuickLook.present(data)