{"id":10185,"library":"qsapi","title":"Qlik Sense qsAPI Client","description":"qsAPI is a Python client library designed for interacting with Qlik Sense's QPS (Qlik Proxy Service) and QRS (Qlik Repository Service) interfaces. It simplifies common administrative and data operations within a Qlik Sense environment, providing a programmatic way to manage apps, users, security rules, and more. The current version is 2.2.0, and the library receives updates periodically, with major refactorings in its 2.1.0 release.","status":"active","version":"2.2.0","language":"python","source_language":"en","source_url":"https://github.com/rafael-sanz/qsAPI","tags":["qlik","qlik-sense","api-client","business-intelligence"],"install":[{"cmd":"pip install qsapi","lang":"bash","label":"Install latest version"}],"dependencies":[{"reason":"Used for making HTTP requests to the Qlik Sense APIs.","package":"requests","optional":false},{"reason":"Used for parsing XML responses from some Qlik Sense endpoints.","package":"xmltodict","optional":false}],"imports":[{"wrong":"from qsAPI import QlikSenseAPI","symbol":"QlikSenseAPI","correct":"from qsapi import QlikSenseAPI"}],"quickstart":{"code":"import os\nfrom qsapi.qsapi import QlikSenseAPI\n\n# Configure Qlik Sense connection details. Use environment variables for production.\nHOST = os.environ.get('QLIK_SENSE_HOST', 'your_qlik_sense_host') # e.g., 'yourserver.example.com'\nCERT_PATH = os.environ.get('QLIK_SENSE_CERT_PATH', '/path/to/client.pem')\nKEY_PATH = os.environ.get('QLIK_SENSE_KEY_PATH', '/path/to/client_key.pem')\nUSER_DIRECTORY = os.environ.get('QLIK_SENSE_USER_DIRECTORY', 'DOMAIN') # e.g., 'YOURDOMAIN'\nUSER_ID = os.environ.get('QLIK_SENSE_USER_ID', 'svc_api_user')\n\ntry:\n    # Initialize the Qlik Sense API client\n    qs_api = QlikSenseAPI(\n        host=HOST,\n        certificate=CERT_PATH,\n        key=KEY_PATH,\n        user_directory=USER_DIRECTORY,\n        user_id=USER_ID\n    )\n\n    # Example: Get Qlik Sense Engine Version\n    engine_version = qs_api.get_engine_version()\n    print(f\"Successfully connected to Qlik Sense. Engine Version: {engine_version}\")\n\n    # Example: Get a list of apps (uncomment to run)\n    # apps = qs_api.get_apps()\n    # print(f\"Found {len(apps)} applications.\")\n    # for app in apps[:2]: # Print details for the first two apps\n    #     print(f\"  - App Name: {app.name}, ID: {app.id}\")\n\nexcept FileNotFoundError as e:\n    print(f\"Error: Certificate or key file not found: {e}. Please ensure paths are correct.\")\nexcept Exception as e:\n    print(f\"An unexpected error occurred: {e}\")","lang":"python","description":"This quickstart demonstrates how to initialize the `QlikSenseAPI` client using certificate-based authentication and fetch the Qlik Sense engine version. It highlights common configuration parameters for connecting to a Qlik Sense Enterprise server."},"warnings":[{"fix":"Update your import statements from `from qsapi import QlikSenseAPI` to `from qsapi.qsapi import QlikSenseAPI`.","message":"The package structure and import paths were refactored in version 2.1.0. The main `QlikSenseAPI` class moved from `qsapi` to `qsapi.qsapi`.","severity":"breaking","affected_versions":"< 2.1.0"},{"fix":"Verify that `certificate` and `key` parameters point to existing, readable `.pem` files. Ensure the user specified by `user_directory` and `user_id` in the API call is authorized within Qlik Sense for the actions attempted.","message":"Qlik Sense API authentication via certificates requires correct absolute paths to `client.pem` and `client_key.pem` files, and these files must have appropriate read permissions for the user running the Python script.","severity":"gotcha","affected_versions":"All versions"},{"fix":"Double-check that `user_directory` matches the user directory configured in Qlik Sense (e.g., 'DOMAINS', 'LDAP', 'LOCAL'), and `user_id` is the exact user ID within that directory that the certificate is intended for.","message":"The `user_directory` and `user_id` parameters are crucial for associating the certificate with a Qlik Sense user. Incorrect values can lead to 'Forbidden' (HTTP 403) or 'Unauthorized' errors even with valid certificates.","severity":"gotcha","affected_versions":"All versions"}],"env_vars":null,"search_vec":"'2.1.0':68 '2.2.0':56 'administr':31 'api':75 'api-cli':74 'app':46 'busi':78 'business-intellig':77 'client':4,9,76 'common':30 'current':53 'data':33 'design':11 'environ':39 'intellig':79 'interact':13 'interfac':27 'librari':10,59 'major':64 'manag':45 'oper':34 'period':62 'programmat':42 'provid':40 'proxi':20 'python':8 'qlik':1,15,19,24,37,70,72 'qlik-sens':71 'qps':18 'qrs':23 'qsapi':3,5 'receiv':60 'refactor':65 'releas':69 'repositori':25 'rule':49 'secur':48 'sens':2,16,38,73 'servic':21,26 'simplifi':29 'updat':61 'user':47 'version':54 'way':43 'within':35","created_at":"2026-04-17T01:22:49.908943+00:00","updated_at":"2026-04-17T01:22:49.908943+00:00","problems":{"verify_error":"Traceback (most recent call last):\n  File \"<string>\", line 1, in <module>\nModuleNotFoundError: No module named 'qsapi'"},"ecosystem":"pypi","meta_description":null,"install_score":null,"quickstart_score":null,"quickstart_tag":null,"pypi_latest":"2.2.0","cli_name":"","cli_version":null,"type":"library","homepage":null,"github":"https://github.com/rafael-sanz/qsAPI","docs":null,"changelog":null,"pypi":"https://pypi.org/project/qsapi/","npm":null,"openapi_spec":null,"status_page":null,"smithery":null,"categories":["http-networking","crm-productivity"],"base_url":null,"auth_type":null,"provenance":{"verified_status":"import_fail","verified_at":"2026-07-03","last_verified":"2026-07-03","next_check":"2026-07-10","install_tag":null}}