`__:\n\n::\n\n easy_install -U disqust\n\nIn either case, use ``-U`` / ``--upgrade`` to upgrade to the latest\nversion in case you've already installed an older one.\n\nExample\n-------\n\nWe'll use the standard public API key that Disqus uses for its embedded\nintegrations all over the web:\n\n::\n\n export DISQUS_API_KEY=E8Uh5l5fHZ6gD8U3KycjAIAk46f68Zw7C6eW8WSjZvCLXebZ7p0r1yrYDrLilk2F\n\n(I don't know if this is legit or condoned or reliable, but you can grab\nthat key from any XHR request on any webpage that embeds Disqus\ncomments.)\n\nThen, start a Python REPL and configure the ``client`` instance:\n\n::\n\n import os\n import disqust\n client = disqust.Client(api_key=os.environ['DISQUS_API_KEY'])\n\nShow channel details (lots of fields manually elided from response):\n\n::\n\n client.json('channels/details', channel='discussdisqus')\n >>> {u'code': 0,\n u'response': {u'adminOnly': False, u'dateAdded': u'2014-09-16T05:20:15',\n u'enableCuration': False, u'hidden': False, u'id': u'2', u'isAggregation': False,\n u'isCategory': False, u'name': u'Discuss Disqus',\n u'options': {u'banner_color': u'gray', u'banner_timestamp': 1476228709,\n u'categories': {u'API': u'Communicate with Disqus data from within your application.'},\n u'coverImage': {u'cache': u'//media.disquscdn.com/home/discussdisqus.jpg'},\n u'description': u'Ongoing topics of discussion about the Disqus product',\n u'favicon': u'//media.disquscdn.com/home/discussdisqus_favicon.png',\n u'modEmail': u'discuss-disqus@disqus.com',\n u'primaryTopics': [{u'description': u'Questions about how to install Disqus on your site.',\n u'displayName': u'Installation', u'identifier': u'installation'}]},\n u'owner_id': u'21035893',\n u'primaryForum': {u'category': u'Tech', u'createdAt': u'2014-08-29T15:49:20.880158',\n u'daysAlive': 90, u'daysThreadAlive': 90,\n u'description': u'Ongoing topics of discussion about the Disqus product
',\n u'disableDisqusBranding': False, u'founder': u'164577566',\n u'guidelines': u'You\\u2019ve made it to Discuss Disqus \\u2013\\u2013 the go-to place ...',\n u'id': u'channel-discussdisqus',\n u'language': u'en', u'name': u'Discuss Disqus', u'settings': {u'adsEnabled': False},\n u'signedUrl': u'http://discussdisqus.disq.us',\n u'twitterName': u'disqus',\n u'url': u'http://discussdisqus.disq.us'},\n u'slug': u'discussdisqus'}}\n\nShow user details (for the owner of the ``discussdisqus`` channel we\njust fetched):\n\n::\n\n client.json('users/details', user='21035893')\n >>> {u'code': 0,\n u'response': {u'about': u\"Product Support @Disqus \\u2013\\u2013 I'm in your inbox, ...\",\n u'avatar': {u'isCustom': True,\n u'permalink': u'https://disqus.com/api/users/avatars/iamfrancisyo.jpg'},\n u'disable3rdPartyTrackers': False,\n u'id': u'21035893',\n u'isAnonymous': False,\n u'isPowerContributor': False,\n u'isPrimary': True,\n u'isPrivate': False,\n u'joinedAt': u'2012-01-10T21:38:08',\n u'location': u'San Francisco, CA',\n u'name': u'Daniel',\n u'numFollowers': 1225,\n u'numFollowing': 164,\n u'numForumsFollowing': 153,\n u'numLikesReceived': 2105,\n u'numPosts': 2071,\n u'profileUrl': u'https://disqus.com/by/iamfrancisyo/',\n u'reputation': 6.3932899999999995,\n u'reputationLabel': u'High',\n u'username': u'iamfrancisyo'}}\n\nFetch all the threads in a forum (this can take 5-7 minutes!) ...\napparently there's no ``channels/listThreads`` endpoint like there is\n``forums/listThreads``, nor a ``channel=xyz`` parameter for the\n``threads/list`` endpoint, but we can use the forum parameter like so:\n\n::\n\n threads = list(client.iter_results('threads/list', forum='channel-discussdisqus', limit=100))\n len(threads)\n >>> 13357\n\nPrint the 10 most recent threads:\n\n::\n\n for thread in threads[:10]:\n print('[{}] {}'.format(thread['createdAt'], thread['title']))\n >>> [2017-03-30T17:41:56] Bug Reports & Feedback: Comment migration fails for single page\n >>> [2017-03-30T16:48:08] Bug Reports & Feedback: Why are my comments being marked as spam? Please help me!\n >>> [2017-03-30T15:54:39] Bug Reports & Feedback: Spam redirects In the Disqus\n >>> [2017-03-30T15:43:08] Bug Reports & Feedback: Duplicated sections to comment after Disqus installation\n >>> [2017-03-30T15:21:03] Admin: How do I comment as my site?\n >>> [2017-03-30T15:01:54] Admin: Forgot login\n >>> [2017-03-30T13:08:37] Admin: Transferring a community?\n >>> [2017-03-30T10:45:47] Embed: Comments disappeared in my site but present in the Community and on site Disqus\n >>> [2017-03-30T10:04:32] Installation: Import old comment is not working on Blogger\n >>> [2017-03-30T06:23:04] Bug Reports & Feedback: disqus not loading on new posts wordpress\n\nDevelopment\n-----------\n\nGenerate the corresponding PyPI-readable reStructuredText,\n``README.rst``:\n\n::\n\n pandoc README.md -o README.rst\n\nPublish to PyPI:\n\n::\n\n python setup.py sdist bdist_wheel upload\n\nLicense\n-------\n\nCopyright \u00a9 2017 Christopher Brown. `MIT\nLicensed `__.\n\n.. |PyPI version| image:: https://badge.fury.io/py/disqust.svg\n :target: https://pypi.python.org/pypi/disqust\n",
"description_content_type": null,
"docs_url": null,
"download_url": "",
"downloads": {
"last_day": -1,
"last_month": -1,
"last_week": -1
},
"home_page": "http://github.com/chbrown/disqust-python",
"keywords": "",
"license": "MIT",
"maintainer": "",
"maintainer_email": "",
"name": "disqust",
"package_url": "https://pypi.org/project/disqust/",
"platform": "",
"project_url": "https://pypi.org/project/disqust/",
"project_urls": {
"Homepage": "http://github.com/chbrown/disqust-python"
},
"release_url": "https://pypi.org/project/disqust/0.1.0/",
"requires_dist": null,
"requires_python": "",
"summary": "Disqus API client",
"version": "0.1.0"
},
"last_serial": 2741968,
"releases": {
"0.1.0": [
{
"comment_text": "",
"digests": {
"md5": "373bc16abb856fafcf6af0d0c6f2a477",
"sha256": "fac41e07c7a2e2f5881c1304b54d49d3a48fd5ea590c63a7bdf68ff0837d5b62"
},
"downloads": -1,
"filename": "disqust-0.1.0-py2-none-any.whl",
"has_sig": false,
"md5_digest": "373bc16abb856fafcf6af0d0c6f2a477",
"packagetype": "bdist_wheel",
"python_version": "2.7",
"requires_python": null,
"size": 9308,
"upload_time": "2017-03-30T18:43:05",
"url": "https://files.pythonhosted.org/packages/19/4d/e7f06c9d0a7b8bba50a9e159be700c82e89f6b36a6398ed06e37b735519d/disqust-0.1.0-py2-none-any.whl"
},
{
"comment_text": "",
"digests": {
"md5": "26cb9da93475a57a8b4166a9630d1078",
"sha256": "ce937da8d866e85074093b0e519826323ff6cceff98b1ab31c3f59322c30fbce"
},
"downloads": -1,
"filename": "disqust-0.1.0.tar.gz",
"has_sig": false,
"md5_digest": "26cb9da93475a57a8b4166a9630d1078",
"packagetype": "sdist",
"python_version": "source",
"requires_python": null,
"size": 5711,
"upload_time": "2017-03-30T18:43:03",
"url": "https://files.pythonhosted.org/packages/9d/c4/b4bff4f2b3a03ad24fc440e9ac9e320eaacab4816c7e900fae0b4b860f6b/disqust-0.1.0.tar.gz"
}
]
},
"urls": [
{
"comment_text": "",
"digests": {
"md5": "373bc16abb856fafcf6af0d0c6f2a477",
"sha256": "fac41e07c7a2e2f5881c1304b54d49d3a48fd5ea590c63a7bdf68ff0837d5b62"
},
"downloads": -1,
"filename": "disqust-0.1.0-py2-none-any.whl",
"has_sig": false,
"md5_digest": "373bc16abb856fafcf6af0d0c6f2a477",
"packagetype": "bdist_wheel",
"python_version": "2.7",
"requires_python": null,
"size": 9308,
"upload_time": "2017-03-30T18:43:05",
"url": "https://files.pythonhosted.org/packages/19/4d/e7f06c9d0a7b8bba50a9e159be700c82e89f6b36a6398ed06e37b735519d/disqust-0.1.0-py2-none-any.whl"
},
{
"comment_text": "",
"digests": {
"md5": "26cb9da93475a57a8b4166a9630d1078",
"sha256": "ce937da8d866e85074093b0e519826323ff6cceff98b1ab31c3f59322c30fbce"
},
"downloads": -1,
"filename": "disqust-0.1.0.tar.gz",
"has_sig": false,
"md5_digest": "26cb9da93475a57a8b4166a9630d1078",
"packagetype": "sdist",
"python_version": "source",
"requires_python": null,
"size": 5711,
"upload_time": "2017-03-30T18:43:03",
"url": "https://files.pythonhosted.org/packages/9d/c4/b4bff4f2b3a03ad24fc440e9ac9e320eaacab4816c7e900fae0b4b860f6b/disqust-0.1.0.tar.gz"
}
]
}