Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
gettsuker
Contributor
Contributor

400 BAD REQUEST - Missing parameters

Hi, we´re trying to implement an external log-in to qlik sense into our HTML webpage but we´re getting a 400 error once we manage to redirect the page to the qlik sense´s one.

 

This is the error that we got: "400 BadRequest: Virtual proxy not possible to determine, since neither TargetId nor Virtual Proxy were specifie"

and this is our HTML code:

 

<script>
$(document).ready(function() {
$("#login_form").submit(function(e) {
e.preventDefault();
e.stopImmediatePropagation();
$('.ajax_response').html();

var url = $(this).attr('action');
$('.ajax_response').html('');
$('#submit').html('Logging in...');
$.ajax({
cache: false,
type: "POST",
url: url,
data: $(this).serialize(), // serializes the form's elements.
success: function(response)
{
var json = jQuery.parseJSON(response);
if ( json.status == 'success' ) {
//$('.ajax_response').html(json.message);
window.location.href = json.location;
}
else {
$('.ajax_response').html(json.message);
$('#submit').html('Login');
}
}
});
});
});
</script>
<div class="ajax_response"></div>

<input type="hidden" name="do" value="login">
<input type="hidden" name="external" value="1">
<input type="hidden" name="ajax" value="1">
<label>Username</label>
<input type="text" name="username">
<label>Password</label>
<input type="password" name="pwd">
<button type="submit" id="submit">Log in</button>
</form>
Labels (1)
1 Reply
NadiaB
Support
Support

Hi @gettsuker 

What is the result if you follow the following article?

Qlik Sense: Generate a ticket with Qlik proxy API (Powershell)

Kind regards.

Don't forget to mark as "Solution Accepted" the comment that resolves the question/issue. #ngm