Error connect etimedout postman

I'm using Newman in order to execute a POSTMAN collection but I always have the error "connect ETIMEDOUT". Using just POSTMAN it works fine, but not with NEWMAN. The testing is quite simple, crea...

I’m using Newman in order to execute a POSTMAN collection but I always have the
error «connect ETIMEDOUT». Using just POSTMAN it works fine, but not with NEWMAN.
The testing is quite simple, create a content on the server
https://jsonblob.com/api

I’m following the tutorial
http://blog.getpostman.com/2014/04/17/how-to-write-automated-tests-for-apis-with-postman-part-2/

Thanks you very much in advance. I put below the collection and the enviroment file.

This is the collection:
{
«id»: «a6a6b2fe-db11-4c57-9144-6b3324174f18»,
«name»: «Newman»,
«values»: [
{
«key»: «url»,
«value»: «https://jsonblob.com»,
«enabled»: true,
«type»: «text»
},
{
«key»: «deviceMapping»,
«value»: «{n «content»: «My first blog post :)»n}»,
«enabled»: true,
«type»: «text»
},
{
«key»: «blogLink»,
«value»: «https://jsonblob.com/api/jsonBlob/b7f2ce87-4c8e-11e8-917b-9137e61d314b»,
«enabled»: true,
«type»: «text»
}
],
«_postman_variable_scope»: «environment»,
«_postman_exported_at»: «2018-04-30T16:13:07.630Z»,
«_postman_exported_using»: «Postman/6.0.10»
}

This is the enviroment file:
{
«id»: «a6a6b2fe-db11-4c57-9144-6b3324174f18»,
«name»: «Newman»,
«values»: [
{
«key»: «url»,
«value»: «https://jsonblob.com»,
«enabled»: true,
«type»: «text»
},
{
«key»: «deviceMapping»,
«value»: «{n «content»: «My first blog post :)»n}»,
«enabled»: true,
«type»: «text»
},
{
«key»: «blogLink»,
«value»: «https://jsonblob.com/api/jsonBlob/b7f2ce87-4c8e-11e8-917b-9137e61d314b»,
«enabled»: true,
«type»: «text»
}
],
«_postman_variable_scope»: «environment»,
«_postman_exported_at»: «2018-04-30T16:13:07.630Z»,
«_postman_exported_using»: «Postman/6.0.10»
}

Содержание

  1. Could not get any response There was an error connecting to https://reqres.in/api/users. Why this might have happened: The server couldn’t send a response: Ensure that the backend is working properly Self-signed SSL certificates are being blocked: Fix this by turning off ‘SSL certificate verification’ in Settings > General Proxy configured incorrectly Ensure that proxy is configured correctly in Settings > Proxy Request timeout: Change request timeout in Settings > General #8132
  2. Comments
  3. Footer
  4. Request timeout despite ‘0’ timeout configuration #7221
  5. Comments
  6. Official Support Articles
  7. How to configure Postman (desktop app) to connect to Qlik Sense
  8. Assumptions:
  9. Process with PEM Certificates (Simplest, Doesn’t Require OpenSSL):
  10. Process with PFX Certificates (Requires OpenSSL):
  11. Video walkthrough:
  12. Integration and Embedding

Could not get any response There was an error connecting to https://reqres.in/api/users. Why this might have happened: The server couldn’t send a response: Ensure that the backend is working properly Self-signed SSL certificates are being blocked: Fix this by turning off ‘SSL certificate verification’ in Settings > General Proxy configured incorrectly Ensure that proxy is configured correctly in Settings > Proxy Request timeout: Change request timeout in Settings > General #8132

Error: connect ETIMEDOUT 104.27.134.11:443 with Could not get any response
There was an error connecting to https://reqres.in/api/users.
Why this might have happened:
The server couldn’t send a response:
Ensure that the backend is working properly
Self-signed SSL certificates are being blocked:
Fix this by turning off ‘SSL certificate verification’ in Settings > General
Proxy configured incorrectly
Ensure that proxy is configured correctly in Settings > Proxy
Request timeout:
Change request timeout in Settings > General

The text was updated successfully, but these errors were encountered:

Error: connect ETIMEDOUT 104.27.134.11:443 in console

Perhaps you could consider editing the Subject of your issue so it’s a little shorter

@shona-code This seems to be an issue with the server itself? I tried it with http:// protocol and got this response:

Trying it with https:// gave me «Could not get response» and in the Postman Console, I see this message:

Trying it out with curl gives me a similar error too:

Hope this helps. Feel free to re-open if you think I’ve missed something. 🙂

© 2023 GitHub, Inc.

You can’t perform that action at this time.

You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.

Источник

Request timeout despite ‘0’ timeout configuration #7221

Postman replies with an ETIMEDOUT despite the timeout configuration is set to infinite (value = 0).

Postman stops in 20 seconds.

The request takes 40sec to reply. I have tried with both curl and another REST client and returns data.

App information

  • Postman Version: v7.5.0
  • OS: Windows 10 PRO 2018

The text was updated successfully, but these errors were encountered:

Hey @mbracero, thanks for reaching out! Unfortunately I’ve been unable to reproduce this.

I tried sending a request to a local server I setup which sends response after 5 mins. Here’s the code for the server:

Postman was able to get the response just like curl .

What kind of service are you using? Is there a chance this got timed out because of a Proxy/server?

Is there any publicly accessible endpoint I can reproduce this behaviour with?

Waiting for your reply!

Hi @coditva , They’re intranet endpoints, so unfortunatelly I can’t shere with you.

They’re simple REST API.

As I said, it’s extrange becasue with another REST client app, it doesn´t happends. And even I thought that timeout was for the whole request (independently of the layers the request has to go thougth).

@mbracero We have updated the Postman Console to include a lot of information to help debug issues like these. Can you update to Postman v7.10.0 and try finding the cause of the timeout?

In the Console you see the re-directs and information about proxy which might help!

Closing this issue now, as we are not able to reproduce this and no other user have reported this. Feel free to re-open the issue if the issue still persists.

I’m just now experiencing the very same behaviour.
I have a call to a REST API that always times out after about 20 seconds.
My time out value is set to 0, but increasing it to arbitrary numbers does not have any effect.
I’m running v 7.27.1

I’m just now experiencing the very same behaviour.
I have a call to a REST API that always times out after about 20 seconds.
My time out value is set to 0, but increasing it to arbitrary numbers does not have any effect.
I’m running v 7.27.1

The problem was solved — partly: The underlying issue was on the network level. My computer with Postman was not allowed to connect to the target server.
I’m now wondering if Postman could report this back to me in a different way that could help me find the problem more easily.

I am now facing same issue with Postman Version 7.28. I have tried couple of version with installations and i am stuck at same point. The API is accessible when tried through any browser but from Postman its still not accessible. Please resolve or share work around for this problem.

I just ran into the same issue with Postman 8.6.2. I’m not using any obvious proxy (but I’m testing against a Netlify local dev server). While debugging my endpoint, which was being hit successfully, Postman would time out even with a 0 in the settings. (I don’t think I ever set that though, it was just already set to 0.)

It was always a 10-second timeout, so I just changed the setting to 60000 ms just to see if that extended it. It did. So it’s all working without an earlier timeout if I just give it a larger value. It is as if the 0 is not the actual value, but the UI is showing 0 if it’s not yet set. Probably now that I’ve changed it to 60000, if I set it back to 0 it will probably not timeout at all anymore. Oh, that’s a quick test so. and yes, confirmed. Set back to 0, after setting it to 60000, and it is not timing out after 10 seconds anymore.

I strongly suspect it’s not reproducible because the bug is only present when the timeout has never been set, and it’s already been set to something in the installations being tested.

For others reading this, there appears to be a workaround of setting it to something other than zero, then setting it to zero.

I just ran into the same issue with Postman 8.6.2. I’m not using any obvious proxy (but I’m testing against a Netlify local dev server). While debugging my endpoint, which was being hit successfully, Postman would time out even with a 0 in the settings. (I don’t think I ever set that though, it was just already set to 0.)

It was always a 10-second timeout, so I just changed the setting to 60000 ms just to see if that extended it. It did. So it’s all working without an earlier timeout if I just give it a larger value. It is as if the 0 is not the actual value, but the UI is showing 0 if it’s not yet set. Probably now that I’ve changed it to 60000, if I set it back to 0 it will probably not timeout at all anymore. Oh, that’s a quick test so. and yes, confirmed. Set back to 0, after setting it to 60000, and it is not timing out after 10 seconds anymore.

I strongly suspect it’s not reproducible because the bug is only present when the timeout has never been set, and it’s already been set to something in the installations being tested.

For others reading this, there appears to be a workaround of setting it to something other than zero, then setting it to zero.

I think you’re on to something here but this didn’t solve it for me unfortunately. My experience:

Request is a non proxied totally regular POST to an external server.

  1. Timeout setting set to 0 in Postman. Request times out after 76 seconds consistently.
  2. Set timeout setting to 10000 in Postman. Request now times out after 10 seconds consistently.
  3. Set timeout setting back to 0 in Postman. Request now times out after 76 seconds consistently.

Seems more than likely that there is something along the request path causing this besides Postman but I’m unable to prove that and as far as I know there is nothing of the sort.

Источник

Official Support Articles

Search or browse our knowledge base to find answers to your questions ranging from account questions to troubleshooting error messages. The content is curated and updated by our global Support team

  • Qlik Community
  • :
  • Support
  • :
  • Support
  • :
  • Knowledge
  • :
  • Support Articles
  • :
  • How to configure Postman (desktop app) to connect .
  • Subscribe to RSS Feed
  • Mark as New
  • Mark as Read
  • Bookmark
  • Subscribe
  • Printer Friendly Page
  • Report Inappropriate Content

How to configure Postman (desktop app) to connect to Qlik Sense

  • Mark as New
  • Bookmark
  • Subscribe
  • Mute
  • Subscribe to RSS Feed
  • Permalink
  • Print
  • Report Inappropriate Content

This article will outline how to connect to Qlik Sense’s APIs using the desktop app version of Postman. The desktop app is a standalone application whereas the Chrome Extension version is being deprecated. For insight into configuring the Chrome Extension, see article QRS API using Xrfkey header in Postman Chrome Extension.

Assumptions:

  • Postman is installed
  • OpenSSL is installed
    • In this guide we will use a Windows version of OpenSSL provided by Shining Light Productions. Other Windows versions may operate slightly differently, likewise for *Nix (UNIX, Linux, etc.) based versions of OpenSSL
  • The ports being called are open between the machine with Postman installed and the server
    • Example 4242 being the direct QRS port

Process with PEM Certificates (Simplest, Doesn’t Require OpenSSL):

  • Go into the QMC > Certificate section and export a copy of the certificates used in the site:
    • Arbitrary machine name (best practice is to use the machine you are making the API calls from)
    • No password on the files
    • Include secrets key
    • PEM Format
  • Copy the client.pem and client_key.pem from C:ProgramDataQlikSenseRepositoryExported Certificates (on the Central node if in a multi-node site) to a place where you can access it from Postman
  • Make a copy of the client.pem and client_key.pem files, and rename them to client.crt and client_key.key.
  • In Postman:
    • Go to Settings > Certificates > Add Certificate
    • Enter in the hostname of your Qlik Sense Server and port (e.g., servername.company.com with port 4242 in the example below)
      • Note : Since you must enter the port used to connect, if you plan to connect via both the Proxy and directly to the QRS then you will need to specify both ports (443 and 4242 respectively). The same goes for QPS calls (4243)
    • Navigate to the where the .crt and .key files is located
    • Enter the passphrase if you used one
    • Click Add to add this certificate to Postman
    • If using a self-signed certificate: Go to Settings > General > Request > SSL certificate verification and disable certificate verification.
  • Make a test request to a known good QRS API endpoint
    • Example: GET https://servername.company.com:4242/qrs/app/full?Xrfkey=1234567890123456
    • You will need to add to the request (e.g GET ) the headers X-Qlik-User and X-Qlik-Xrfkey to the request. Otherwise the following error will be displayed:

      Process with PFX Certificates (Requires OpenSSL):

      • Go into the QMC > Certificate section and export a copy of the certificates used in the site:
        • Arbitrary machine name (best practice is to use the machine you are making the API calls from)
        • No password on the files
        • Include secrets key
        • Windows format
      • Copy the client.pfx from C:ProgramDataQlikSenseRepositoryExported Certificates (on the Central node if in a multi-node site) to the bin directory of OpenSSL ( C:OpenSSL-Win32bin for a default install of the above version of OpenSSL).
      • Open a command prompt with administrative rights
        • cd C:OpenSSL-Win32bin
        • openssl pkcs12 -in client.pfx -nocerts -out sense.key
          • The import password value will be whatever was used when exporting the certificate, if none then press enter
          • PEM pass phrase is a pass phrase to secure the .key file
            • Ultimately Postman will record this pass phrase in clear text so whether this is used or not is left up to the individual
        • openssl pkcs12 -in client.pfx -clcerts -nokeys -out sense.crt
          • The import password value will be whatever was used when exporting the certificate, if none then press enter
      • Copy the outputted .KEY and .CRT files to the client machine where Postman is installed
      • In Postman
        • Go to Settings > Certificates > Add Certificate
        • Enter in the hostname and port
          • Note : Since you must enter the port used to connect, if you plan to connect via both the Proxy and directly to the QRS then you will need to specify both ports (443 and 4242 respectively). The same goes for QPS calls (4243)
        • Navigate to the where the .CRT file is located
        • Enter the passphrase
        • Click Add to add this certificate to Postman
        • If using a self-signed certificate: Go to Settings > General > Request > SSL certificate verification and disable certificate verification.
      • Make a test request to a known good QRS API endpoint
        • Example: GET https://servername.company.com:4242/qrs/app/full?Xrfkey=1234567890123456
        • You will need to add to the request (e.g GET ) the headers X-Qlik-User and X-Qlik-Xrfkey to the request. Otherwise the following error will be displayed:

          Video walkthrough:

          Integration and Embedding

          • Mark as Read
          • Mark as New
          • Bookmark
          • Permalink
          • Print
          • Report Inappropriate Content

          thank you very much 🕺

          • Mark as Read
          • Mark as New
          • Bookmark
          • Permalink
          • Print
          • Report Inappropriate Content

          @Andre_Sostizzo The postman desktop app is slightly updated, getting an error with the current steps.

          This is the error — Error: error:0900006e:PEM routines:OPENSSL_internal:NO_START_LINE

          • Mark as Read
          • Mark as New
          • Bookmark
          • Permalink
          • Print
          • Report Inappropriate Content

          I am getting the same error as Shukla. @Andre_Sostizzo / @gal_polak / @pshukla3 , Can you please help?

          • Mark as Read
          • Mark as New
          • Bookmark
          • Permalink
          • Print
          • Report Inappropriate Content

          I exported in the PEM format and followed all steps, but I am getting the following error now:

          Error: connect ETIMEDOUT 167.219.19.251:4242

          • Mark as Read
          • Mark as New
          • Bookmark
          • Permalink
          • Print
          • Report Inappropriate Content

          @subramani_r , I would test this with Postman on the QS server itself to make sure you don’t have a network restriction between the server and your computer. Also would make sure the correct server FQDN is used in your request.

          • Mark as Read
          • Mark as New
          • Bookmark
          • Permalink
          • Print
          • Report Inappropriate Content

          @Andre_Sostizzo , Thanks for the response. Can you please clarify as to what you mean by testing postman on the QS server itself? Should I install postman on the same server where QS enterprise is installed?

          I am using the correct server FQDN, but its still not working. I am able to access the Qliksense environment on my browser but not able to do that through postman by following the steps given in the above description. Can you please suggest me any other way to fix this?

          • Mark as Read
          • Mark as New
          • Bookmark
          • Permalink
          • Print
          • Report Inappropriate Content

          Thanks for your example, it worked for me exporting certificates from QMC.

          I’d like to ask if Postman can be used for obtaining the script of each app. I mean, now I have a list of apps and for each one I’d like to open it and obtain its script. Is that possible? or I have to use solutions like QlikSense.NetSDK (.Net) or Enigma.js(Java Script).

          Thanks in advance

          • Mark as Read
          • Mark as New
          • Bookmark
          • Permalink
          • Print
          • Report Inappropriate Content

          @LDR , tagging @Levi_Turner who may have feedback.

          • Mark as Read
          • Mark as New
          • Bookmark
          • Permalink
          • Print
          • Report Inappropriate Content

          I was trying to find a similar answer (get the script of an app without opening the app in Hub) via Postman, but the only easy way I found was via ‘ Engine API Explorer ‘ ( URL : Engine API Explorer ‒ Qlik Sense for developers).

          In order to use this tool please follow the steps below:

          1.) Open one of the following URLs:

          — from a point that can access the QS Server

          — from inside the QS Server

          2.) Login with your RootAdmin account.

          3.) Click ‘ Connect to engine ‘ button.

          4.) Select an app from the drop-down list.

          5.) From the ‘ Select API calls ‘ please choose ‘ Doc ‘ > ‘ GetScript ‘ method.

          6.) Clik the ‘ Execute ‘ button and the result will appear in the ‘ Execution logs ‘ > ‘ GetScript ‘ > ‘ Response ‘.

          7.) Get the line starting with ‘ qScript ‘.

          Bear in the mind that the script will appear in a single line, so you will need to replace ‘ rn ‘ characters with new lines ( Notepad++ Solution : Search for ‘ \r\n ‘ and replace it with ‘ rn ‘ in ‘ Extended mode ‘). Finally, each tab code segment starts with ‘ ///$tab ‘ ( Example : ///$tab Main).

          I hope this approach will help you temporarily until you find something similar by Postman.

          • Mark as Read
          • Mark as New
          • Bookmark
          • Permalink
          • Print
          • Report Inappropriate Content

          First at all thanks for your answer 😉

          Yep, my first step was «Dev Hub» and then I tried to find the right way to get the same info externally. Then I was checking Qlik APIs, finally thanks to this amazing community I learnt:

          • We can use REST APIs (QRS & QPS) for querying things that can be obtained using QMC, instance: list of apps in your QS environment, tasks, etc. For these kind of purposes REST APIs are our friends.
          • If on the other hand we want to work with app’s objects then we have to use the Engine API. In this case tools like Postman, curl, etc. are not the way. We have to use programming languages like C#, Java Script, Python, Java, . or any one with the capability to work with websockets. Here Qlik is helping us because they have created several packages for making our live easier for instance: QlikSense.NetSDK (.Net), Enigma.js (Java Script), etc.

          Maybe my latin blood played a dirty trick on me 😂 , cause I started to try this and that without reading in detail the documentation that Qlik is sharing. Anyway, I think that now I know the path to follow.

          Источник

Я использую Newman для выполнения коллекции POSTMAN, но у меня всегда есть
ошибка «подключить ETIMEDOUT». Используя только POSTMAN, он работает нормально, но не с NEWMAN.
Тестирование довольно простое, создайте контент на сервере
https://jsonblob.com/api

Я следую руководству
http://blog.getpostman.com/2014/04/17/how-to-write-automated-tests-for-apis-with-postman-part-2/

Заранее большое спасибо. Я поместил ниже коллекцию и файл окружения.

Это сборник:
{
«id»: «a6a6b2fe-db11-4c57-9144-6b3324174f18»,
«name»: «Ньюман»,
«значения»: [
{
«ключ»: «URL»,
«значение»: «https://jsonblob.com»,
«включен»: правда,
«тип»: «текст»
},
{
«key»: «deviceMapping»,
«value»: «{ n » content «: » Моя первая запись в блоге:) » n}»,
«включен»: правда,
«тип»: «текст»
},
{
«ключ»: «blogLink»,
«значение»: «https://jsonblob.com/api/jsonBlob/b7f2ce87-4c8e-11e8-917b-9137e61d314b»,
«включен»: правда,
«тип»: «текст»
}
],
«_postman_variable_scope»: «среда»,
«_postman_exported_at»: «2018-04-30T16: 13: 07.630Z»,
«_postman_exported_using»: «Почтальон / 6.0.10»
}

Это файл среды:
{
«id»: «a6a6b2fe-db11-4c57-9144-6b3324174f18»,
«name»: «Ньюман»,
«значения»: [
{
«ключ»: «URL»,
«значение»: «https://jsonblob.com»,
«включен»: правда,
«тип»: «текст»
},
{
«key»: «deviceMapping»,
«value»: «{ n » content «: » Моя первая запись в блоге:) » n}»,
«включен»: правда,
«тип»: «текст»
},
{
«ключ»: «blogLink»,
«значение»: «https://jsonblob.com/api/jsonBlob/b7f2ce87-4c8e-11e8-917b-9137e61d314b»,
«включен»: правда,
«тип»: «текст»
}
],
«_postman_variable_scope»: «среда»,
«_postman_exported_at»: «2018-04-30T16: 13: 07.630Z»,
«_postman_exported_using»: «Почтальон / 6.0.10»
}

Я использую Newman для выполнения коллекции POSTMAN, но у меня всегда возникает
ошибка «connect ETIMEDOUT». При использовании только POSTMAN все работает нормально, но не с NEWMAN.
Тестирование довольно простое, создайте контент на сервере
https://jsonblob.com/api

Я следую руководству
http://blog.getpostman.com/2014/04/17/how-to-write-automated-tests-for-apis-with-postman-part-2/

Заранее большое спасибо. Я привел ниже коллекцию и файл окружения.

Это коллекция:
{
«id»: «a6a6b2fe-db11-4c57-9144-6b3324174f18»,
«имя»: «Ньюман»,
«значения»: [
{
«ключ»: «url»,
«value»: «https://jsonblob.com»,
«enabled»: true,
«type»: «text»
},
{
«ключ»: «deviceMapping»,
«value»: «{n n «content»: «Моя первая запись в блоге :)»n}»,
«enabled»: true,
«type»: «text»
},
{
«key»: «blogLink»,
«value»: «https://jsonblob.com/api/jsonBlob/b7f2ce87-4c8e-11e8-917b-9137e61d314b»,
«enabled»: true,
«type»: «text»
}
],
«_postman_variable_scope»: «environment»,
«_postman_exported_at»: «2018-04-30T16:13:07.630Z»,
«_postman_exported_using»: «Postman/6.0.10»
}

Это файл окружения:.
{
«id»: «a6a6b2fe-db11-4c57-9144-6b3324174f18»,
«имя»: «Ньюман»,
«значения»: [
{
«ключ»: «url»,
«value»: «https://jsonblob.com»,
«enabled»: true,
«type»: «text»
},
{
«ключ»: «deviceMapping»,
«value»: «{n n «content»: «Моя первая запись в блоге :)»n}»,
«enabled»: true,
«type»: «text»
},
{
«key»: «blogLink»,
«value»: «https://jsonblob.com/api/jsonBlob/b7f2ce87-4c8e-11e8-917b-9137e61d314b»,
«enabled»: true,
«type»: «text»
}
],
«_postman_variable_scope»: «environment»,
«_postman_exported_at»: «2018-04-30T16:13:07.630Z»,
«_postman_exported_using»: «Postman/6.0.10»
}

  • Qlik Sense Enterprise on Windows , All Version

Assumptions:

  • Postman is installed
  • OpenSSL is installed
    • In this guide we will use a Windows version of OpenSSL provided by Shining Light Productions. Other Windows versions may operate slightly differently, likewise for *Nix (UNIX, Linux, etc.) based versions of OpenSSL 
  • The ports being called are open between the machine with Postman installed and the server
    • Example 4242 being the direct QRS port

Process with PEM Certificates (Simplest, Doesn’t Require OpenSSL): 

  • Go into the QMC > Certificate section and export a copy of the certificates used in the site:
    • Arbitrary machine name (best practice is to use the machine you are making the API calls from)
    • No password on the files
    • Include secrets key
    • PEM Format
  • Copy the client.pem and client_key.pem from C:ProgramDataQlikSenseRepositoryExported Certificates{computer name} (on the Central node if in a multi-node site) to a place where you can access it from Postman
  • Make a copy of the client.pem and client_key.pem files, and rename them to client.crt and client_key.key.
  • In Postman:
    • Go to Settings > Certificates > Add Certificate
    • Enter in the hostname of your Qlik Sense Server and port (e.g., servername.company.com with port 4242 in the example below)
      • Note: Since you must enter the port used to connect, if you plan to connect via both the Proxy and directly to the QRS then you will need to specify both ports (443 and 4242 respectively). The same goes for QPS calls (4243)
    • Navigate to the where the .crt and .key files is located
    • Enter the passphrase if you used one
    • Click Add to add this certificate to Postman
    • If using a self-signed certificate: Go to Settings > General > Request > SSL certificate verification and disable certificate verification.
  • Make a test request to a known good QRS API endpoint
    • Example: GET https://servername.company.com:4242/qrs/app/full?Xrfkey=1234567890123456
    • You will need to add to the request (e.g GET) the headers X-Qlik-User and X-Qlik-Xrfkey to the request. Otherwise the following error will be displayed: 

      XSRF prevention check failed. Possible XSRF discovered.

    •  The X-Qlik-Xrfkey header value needs to match the Xrfkey value included in the request’s URL (e.g 1234567890123456)
    • The recommended X-Qlik-User value to use is UserDirectory=INTERNAL; UserId=sa_repository
    • More information under Reference the API documentation on Xrfkey headers.

Process with PFX Certificates (Requires OpenSSL): 

  • Go into the QMC > Certificate section and export a copy of the certificates used in the site:
    • Arbitrary machine name (best practice is to use the machine you are making the API calls from)
    • No password on the files
    • Include secrets key
    • Windows format
  • Copy the client.pfx from C:ProgramDataQlikSenseRepositoryExported Certificates (on the Central node if in a multi-node site) to the bin directory of OpenSSL (C:OpenSSL-Win32bin for a default install of the above version of OpenSSL).
  • Open a command prompt with administrative rights
    • cd C:OpenSSL-Win32bin
    • openssl pkcs12 -in client.pfx -nocerts -out sense.key
      • The import password value will be whatever was used when exporting the certificate, if none then press enter
      • PEM pass phrase is a pass phrase to secure the .key file
        • Ultimately Postman will record this pass phrase in clear text so whether this is used or not is left up to the individual
    • openssl pkcs12 -in client.pfx -clcerts -nokeys -out sense.crt
      • The import password value will be whatever was used when exporting the certificate, if none then press enter
  • Copy the outputted .KEY and .CRT files to the client machine where Postman is installed
  • In Postman
    • Go to Settings > Certificates > Add Certificate
    • Enter in the hostname and port
      • Note: Since you must enter the port used to connect, if you plan to connect via both the Proxy and directly to the QRS then you will need to specify both ports (443 and 4242 respectively). The same goes for QPS calls (4243)
    • Navigate to the where the .CRT file is located
    • Enter the passphrase
    • Click Add to add this certificate to Postman
    • If using a self-signed certificate: Go to Settings > General > Request > SSL certificate verification and disable certificate verification.
  • Make a test request to a known good QRS API endpoint
    • Example: GET https://servername.company.com:4242/qrs/app/full?Xrfkey=1234567890123456
    • You will need to add to the request (e.g GET) the headers X-Qlik-User and X-Qlik-Xrfkey to the request. Otherwise the following error will be displayed: 

      XSRF prevention check failed. Possible XSRF discovered.

    •  The X-Qlik-Xrfkey header value needs to match the Xrfkey value included in the request’s URL (e.g 1234567890123456)
    • The recommended X-Qlik-User value to use is UserDirectory=INTERNAL; UserId=sa_repository
    • More information under Reference the API documentation on Xrfkey headers.

Video walkthrough:

(source: https://www.youtube.com/watch?v=XF9CKO63zk0)

Понравилась статья? Поделить с друзьями:
  • Error conflicting types for си
  • Error conflicted subnet addresses
  • Error configuring sdk pycharm
  • Error configuring s3 backend no valid credential sources for s3 backend found
  • Error constexpr does not name a type