{ "info": { "author": "Asaf Strassberg", "author_email": "asafst@microsoft.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 4 - Beta", "Intended Audience :: Developers", "Intended Audience :: Science/Research", "License :: OSI Approved :: MIT License", "Operating System :: OS Independent", "Programming Language :: Python :: 2.7", "Programming Language :: Python :: 3.5", "Topic :: Scientific/Engineering :: Information Analysis", "Topic :: Software Development :: Libraries :: Python Modules" ], "description": "Application Insights Analytics Client for Python\r\n================================================\r\n\r\n.. image:: https://badge.fury.io/py/aianalytics-client.svg\r\n :target: https://badge.fury.io/py/aianalytics-client\r\n\r\nThis project enables quering the Application Insights Analytics API while parsing the results for furthur processing in a simple manner. `Application Insights Analytics `_ is a powerful search feature of Application Insights, which allows to query your Applciation Insights telemetry.\r\nThis module is meant to be used with other data analysis packages, such as `numpy `_ and `matplotlib `_. The query result are numpy arrays.\r\n\r\n **Note**: this package is not for sending telemetry to the Application Insights serivce. For that you can use the `official python sdk repo `_.\r\n\r\n\r\nRequirements\r\n------------\r\n\r\nThis module was tested on Python 2.7 and Python 3.5. Older versions of Python 3 probably work as well. \r\n\r\nFor opening the project in Microsoft Visual Studio you will need `Python Tools for Visual Studio `_.\r\n\r\nInstallation\r\n------------\r\n\r\nTo install the latest release you can use `pip `_.\r\n\r\n::\r\n\r\n $ pip install aianalytics-client\r\n\r\nUsage\r\n-----\r\n\r\nOnce installed, you can query your Application Insights telemetry. Here are a few samples.\r\n\r\n**Query exceptions from the last 24 hours and print them**\r\n\r\n.. code:: python\r\n\r\n from analytics.client import AnalyticsClient\r\n client = AnalyticsClient('', '')\r\n result = client.query('exceptions | where timestamp > ago(24h) | project timestamp, type, outerMessage') \r\n for row in result.row_iterator():\r\n print (\"at {0} there was an exception of type {1} with message {2}\".format(row['timestamp'], row['type'], row['outerMessage']))\r\n # Indexes can also be used instead of column names, e.g.:\r\n print (\"at {0} there was an exception of type {1} with message {2}\".format(row[0], row[1], row[2]))\r\n\r\n\r\n**Query average request duration from the last week and plot using matplotlib**\r\n\r\n.. code:: python\r\n\r\n from analytics.client import AnalyticsClient\r\n client = AnalyticsClient('', '')\r\n result = client.query('requests | where timestamp > ago(7d) | summarize Duration = avg(duration/1000) by bin(timestamp, 1h) | order by timestamp asc') \r\n\r\n import matplotlib.pyplot as plt\r\n plt.plot(result[\"timestamp\"], result[\"Duration\"])\r\n plt.show()", "description_content_type": null, "docs_url": null, "download_url": "https://github.com/asafst/ApplicationInsightsAnalyticsClient-Python", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/asafst/ApplicationInsightsAnalyticsClient-Python", "keywords": "analytics applicationinsights telemetry appinsights numpy IPython", "license": "MIT", "maintainer": null, "maintainer_email": null, "name": "aianalytics-client", "package_url": "https://pypi.org/project/aianalytics-client/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/aianalytics-client/", "project_urls": { "Download": "https://github.com/asafst/ApplicationInsightsAnalyticsClient-Python", "Homepage": "https://github.com/asafst/ApplicationInsightsAnalyticsClient-Python" }, "release_url": "https://pypi.org/project/aianalytics-client/0.1.5/", "requires_dist": null, "requires_python": null, "summary": "This project enables quering the Application Insights Analytics API while parsing the results for furthur processing using data analysis tools, such as numpy", "version": "0.1.5" }, "last_serial": 2684644, "releases": { "0.1.0": [ { "comment_text": "", "digests": { "md5": "d384ee7e060280957f984c21f6fb828e", "sha256": "54b0dd2519cebe62f5b3de8235cc7029cc44d111ce4e989701720544c7ca08fa" }, "downloads": -1, "filename": "aianalytics-client-0.1.0.zip", "has_sig": false, "md5_digest": "d384ee7e060280957f984c21f6fb828e", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 1996, "upload_time": "2017-03-02T13:33:47", "url": "https://files.pythonhosted.org/packages/1f/af/2bd7dc0a4c7f3d7d68d3aad9092c09a31c6598ca3f0fff97cbf8c7cb3a64/aianalytics-client-0.1.0.zip" } ], "0.1.1": [ { "comment_text": "", "digests": { "md5": "27a003e3788c97cfe7e237f543ac99eb", "sha256": "9886ceabbcf23c622ac467f275aa3279eff4f7ca5ba3b11da341384e3e2278f8" }, "downloads": -1, "filename": "aianalytics-client-0.1.1.zip", "has_sig": false, "md5_digest": "27a003e3788c97cfe7e237f543ac99eb", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 7785, "upload_time": "2017-03-02T13:46:53", "url": "https://files.pythonhosted.org/packages/d8/61/7170b280df1689b98791cea7106c97d9b21765c54aca3ddc9e3628885b33/aianalytics-client-0.1.1.zip" } ], "0.1.2": [ { "comment_text": "", "digests": { "md5": "22f8606fc4986ed76a85c76d5725fe8a", "sha256": "31211cd91ede28ac42aa6b87c03eee3e1311c9066b797977debf20dd56832b9b" }, "downloads": -1, "filename": "aianalytics-client-0.1.2.zip", "has_sig": false, "md5_digest": "22f8606fc4986ed76a85c76d5725fe8a", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 12852, "upload_time": "2017-03-02T13:56:37", "url": "https://files.pythonhosted.org/packages/3f/d2/b22bc1013a08533731cfdad5bfbefe30aa52cf45e09f891dd9a81465a20f/aianalytics-client-0.1.2.zip" } ], "0.1.3": [ { "comment_text": "", "digests": { "md5": "036bbd53db6b5f203c5e6745f1f1fce4", "sha256": "84b95c20dfd98ccfbc8bf84f21144cfaeda4a2809b26d216fe0a2f32657cfa97" }, "downloads": -1, "filename": "aianalytics-client-0.1.3.zip", "has_sig": false, "md5_digest": "036bbd53db6b5f203c5e6745f1f1fce4", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 12932, "upload_time": "2017-03-02T14:02:49", "url": "https://files.pythonhosted.org/packages/72/01/77fc98eecb2e807c6b7a38f222b668c37b45e5ca3440eb53560586e0989d/aianalytics-client-0.1.3.zip" } ], "0.1.4": [ { "comment_text": "", "digests": { "md5": "dac69636e18d1044b184553639bcb7c4", "sha256": "c18e1dd620793eed143dac4d06e07d3fbb932184c1ceb22d4c66adad12bcfcdc" }, "downloads": -1, "filename": "aianalytics-client-0.1.4.zip", "has_sig": false, "md5_digest": "dac69636e18d1044b184553639bcb7c4", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 13092, "upload_time": "2017-03-02T14:21:27", "url": "https://files.pythonhosted.org/packages/94/2a/46acc1f8b5074fb1ff4757364cef42cd2c5e58fcc1c9b0346556665356f5/aianalytics-client-0.1.4.zip" } ], "0.1.5": [ { "comment_text": "", "digests": { "md5": "5b95b4761f72b19d7f4f1c4e311579c0", "sha256": "19aab031e128826cb8cdfe84d11f63f59d9ac2564263412cc1abe11420d0a6b2" }, "downloads": -1, "filename": "aianalytics-client-0.1.5.zip", "has_sig": false, "md5_digest": "5b95b4761f72b19d7f4f1c4e311579c0", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 12127, "upload_time": "2017-03-05T22:31:08", "url": "https://files.pythonhosted.org/packages/67/2b/1a3aadd1c6ee1896ef55ddd5987b539c95e4475c61f580ffd094b0d59885/aianalytics-client-0.1.5.zip" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "5b95b4761f72b19d7f4f1c4e311579c0", "sha256": "19aab031e128826cb8cdfe84d11f63f59d9ac2564263412cc1abe11420d0a6b2" }, "downloads": -1, "filename": "aianalytics-client-0.1.5.zip", "has_sig": false, "md5_digest": "5b95b4761f72b19d7f4f1c4e311579c0", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 12127, "upload_time": "2017-03-05T22:31:08", "url": "https://files.pythonhosted.org/packages/67/2b/1a3aadd1c6ee1896ef55ddd5987b539c95e4475c61f580ffd094b0d59885/aianalytics-client-0.1.5.zip" } ] }