Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Qlik Sense SDK and API

Hello,

I have been working the last days into an aplication on .NET to be able to check if an app name exists in a stream deleting the application if exists and uploading and publishing the new one or only upload and publish the app if the application is new.

I started with the SDK being able to comunicate with the server and also create and delete applications but not uploading and publishing so I tried with the API. With the API I was able to perform the operations related with GET and PUT but not with DELETE seeming to me the way to call that operation similar than the put, so I was forced to combine the SDK and the API.

I supose is not the proper way to do that but I don't know if there is something that have to be taken into account when working with Delete operations.

With PUT operation as an example trying to publish an app it returns the following REST message

{"id":"ea81f723-475f-4356-b31d-dae12983b8ca","createdDate":"2015-12-22T12:35:38.405Z","modifiedDate":"2015-12-22T12:35:39.733Z","modifiedByUserName":"SENSE\\comuser","owner":{"id":"76a556eb-cf1a-43f9-9efe-0cb2de121433","userId":"comuser","userDirectory":"SENSE","name":"comuser","privileges":null},"customProperties":[],"name":"Conector","appId":"","publishTime":"2015-12-22T12:35:39.717Z","published":true,"tags":[],"description":"","stream":{"id":"aaec8d41-5201-43ab-809f-3063750dfafd","name":"Everyone","privileges":null},"fileSize":145429,"lastReloadTime":"2015-12-17T15:56:52.000Z","thumbnail":"","savedInProductVersion":"2.1.1","migrationHash":"a9527c3f7197d59e79f5618a6900798d73ec9188","dynamicColor":"","availabilityStatus":0,"privileges":null,"schemaPath":"App"}

But trying to delete the application it returns me an HTML code starting with:

Aplicacion no encontrada System.Exception: The HTTP request header is incorrect: <!doctype html>

<html>

  <head>

  <meta charset="utf-8"/>

  <meta http-equiv="X-UA-Compatible" content="IE=edge"/>

  <meta name="google" value="notranslate"/>

  <title>400 - Bad request</title>

  <link rel="shortcut icon" href="data:image/x-

For the PUT operation I use the direction "/qrs/app/" + appId + "/publish" with the parameter "stream" specifying the stream id where I want to publish the application, with the Delete operation I use the direction "/qrs/app/"+applicationId with no parameters, I don't know if I have left something but I would like to know the proper way to perform the Delete operations.

Thanks in advance for your help.

1 Solution

Accepted Solutions
Not applicable
Author

Hello Konrad thanks for answer my question, what I really wanted is to use only the rest api Finally I used another way to do that petition with c# following the example from:

https://msdn.microsoft.com/en-us/library/jj819168.aspx

Specifying on the uri the serverurl/virtualproxy the ?xrfkey=ABCDEFG123456789

and specifying on the request object the headers for X-Qlik-xrfkey and X-QlikView-xrfkey with request.Headers.add()

and also specifying the request.Method DELETE.

View solution in original post

2 Replies
konrad_mattheis
Luminary Alumni
Luminary Alumni

Hi Oriol,

sorry I don't really understand your problem. Please can you provide (best case) a step by step howto what you have done before you reach the error.

So you like to use the QRS API or Enginge API with the .NET SDK or both?

bye

Konrad

Not applicable
Author

Hello Konrad thanks for answer my question, what I really wanted is to use only the rest api Finally I used another way to do that petition with c# following the example from:

https://msdn.microsoft.com/en-us/library/jj819168.aspx

Specifying on the uri the serverurl/virtualproxy the ?xrfkey=ABCDEFG123456789

and specifying on the request object the headers for X-Qlik-xrfkey and X-QlikView-xrfkey with request.Headers.add()

and also specifying the request.Method DELETE.