Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Aug 3, 2021 8:03:12 AM
Aug 5, 2017 9:46:14 AM
This article explains how to connect to the QMS API in Visual Studio.
Create a new project in Visual Studio (for instance a simple Console Application).
The QMS API cannot be connected out-of-the-box. It needs the HTTP header "X-Service-Key" to be populated with a key retrieved by the QMS before any regular communication may occur.
This is achieved in .NET by adding a client MessageInspector via an EndpointBehavior attached to the QMS API client.
Attached to this article is a one-class implementation (QMSClientServiceKeySupport.cs) of this behavior, that can be reused straight away.
Add this class to your project!
Note: Don't forget to replace "YOUR_NAMESPACE_HERE" and "YOUR_QMSAPI_NAMESPACE_HERE" by the correct namespaces.
First, you'll need an instance of the QMSClient class, and then you should initiate the ServiceKey management using the class QMSClientServiceKeySupport just added:
QMSClient qmsClient = new QMSClient(); QMSClientServiceKeySupport.Initiate(qmsClient);
Note: If you want your client to connect to a different URL you should use the following constructor instead:
QMSClient qmsClient = new QMSClient("BasicHttpBinding_IQMS", "http://yourmachinename:4799/QMS/Service");
*If you wish to use the newest interface - IQMS2 then use QMS2Client class for initiating communication.
Now the code is prepared to start using the API.
Important Note: The user running the code must be a member of a group called "QlikView Management API".
Simply create this group locally on the system if it's not there, and add yourself to it.
Note that you must log off / on for this change to be activated.
If you wish to connect to the QMS API using HTTPS instead of HTTP, please follow QlikView: Connecting to QMS API using HTTPS
Hello!
Why are so many operations missed in QMS Backend Service?
For example - GetExternalProgramTask, GetLoadedDocuments
How can I use them?
Hello @BuTbka
Please post your query with as much detail as possible in the appropriate forum. We cannot provide further guidance directly in this article, and posting the correct forum will make your post visible to our large user base and our active support agents.
All the best,
Sonja