Attention | Topic was automatically imported from the old Question2Answer platform. | |
Asked By | iamkhan |
i need to access a web content using token how to put one in httprequest
Attention | Topic was automatically imported from the old Question2Answer platform. | |
Asked By | iamkhan |
i need to access a web content using token how to put one in httprequest
Reply From: | Calinou |
If this is a JSON Web Token or a similar mechanism, you need to pass the Authorization
HTTP header in your request with the value Bearer (your token here)
.
You can pass custom headers to HTTPRequest’s request()
function with the optional second parameter which is an array of strings of the form Key: Value
.