I have a C# app. What I'm trying to do is to open the default browser (for example Mozilla) with Confluence logged in.
I tried to create a simple html file (and run it from C#) with a function that creates a request and passes the Authorization header:
function myFunction() {
var parameters = location.search.substring(1).split("&");
var lAuthHeader = parameters[0];
$.ajax({
url: "https://myconfluenceurl?",
type: "GET",
beforeSend: function(xhr) {
xhr.setRequestHeader('Authorization', 'Basic ' + lAuthHeader);
},
success: function() {
window.location.href = 'https://myconfluenceurl?';
}
});
}But I'm getting a 403 in the console. Is there any way to do it?