easy-twitter-interactors


Nameeasy-twitter-interactors JSON
Version 1.0.1 PyPI version JSON
download
home_pagehttps://easy-twitter-interactors.xink.top/
Summary简易、好用的推特(Twitter)点赞,刷阅读量程序
upload_time2023-09-09 03:44:34
maintainer
docs_urlNone
authorhanxinkong
requires_python>=3.6.8
licenseMIT
keywords easy twitter interactors reads
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # easy_twitter_interactors

推特(Twitter)点赞,刷阅读量程序,希望能为使用者带来益处。如果您也想贡献好的代码片段,请将代码以及描述,通过邮箱( [xinkonghan@gmail.com](mailto:hanxinkong<xinkonghan@gmail.com>)
)发送给我。代码格式是遵循自我主观,如存在不足敬请指出!


----
**文档地址:
** <a href="https://easy-twitter-interactors.xink.top/" target="_blank">https://easy-twitter-interactors.xink.top/ </a>

**PyPi地址:
** <a href="https://pypi.org/project/easy-twitter-interactors" target="_blank">https://pypi.org/project/easy-twitter-interactors </a>

**GitHub地址:
** [https://github.com/hanxinkong/easy-twitter-interactors](https://github.com/hanxinkong/easy-twitter-interactors)

----

## 推特三件套(有需要可自行安装)

- `easy_twitter_publisher` 推特发帖,回帖,转载 https://pypi.org/project/easy_twitter_publisher
- `easy_twitter_crawler` 推特采集 https://pypi.org/project/easy-twitter-crawler
- `easy_twitter_interactors` 推特互动(点赞,刷阅读量等) https://pypi.org/project/easy_twitter_interactors

## 安装

<div class="termy">

```console
pip install easy-twitter-interactors
```

</div>

## 主要功能

- `likes` 对指定帖子点赞
- `reads` 对指定帖子刷阅读量(暂无)

## 简单使用

设置代理及cookie (点赞和阅读均需要设置cookie)

```python
proxy = {
    'http': 'http://127.0.0.1:10808',
    'https': 'http://127.0.0.1:10808'
}
cookie = 'auth_token=686fa28f49400698820d0a3c344c51efdeeaf73a; ct0=5bed99b7faad9dcc742eda564ddbcf37888f8794abd6d4d736919234440be2172da1e9a9fc48bb068db1951d1748ba5467db2bc3e768f122794265da0a9fa6135b4ef40763e7fd91f730d0bb1298136b'
```

点赞使用案例(对指定帖子点赞)

```python
from easy_spider_tool import format_json
from easy_twitter_interactors import TwitterLikes, get_headers

twitter_likes = TwitterLikes()
twitter_likes.set_proxy(proxy)
twitter_likes.set_headers(get_headers(cookie))
likes_info = twitter_likes.likes('1690065356495421444')
print(format_json(likes_info))
```

点赞参数说明

| 字段名         | 类型     | 必须 | 描述                                                                                     |
|-------------|--------|----|----------------------------------------------------------------------------------------|
| to_tweet_id | string | 是  | 目标帖子id(https://twitter.com/elonmusk/status/1690164670441586688 中的 1690164670441586688) |

___

## 依赖

内置依赖

- `typing` Type Hints for Python.
- `json` Type Hints for Python.

第三方依赖

- `requests` An XPath for JSON.
- `loguru` An XPath for JSON.
- `urllib3` Python library used for working with timezone information.
- `easy_spider_tool` Python library used for working with timezone information.

_注:依赖顺序排名不分先后_

## 链接

Github:https://github.com/hanxinkong/easy-twitter-interactors

在线文档:https://easy-twitter-interactors.xink.top

## 贡献者

## 许可证

该项目根据 **MIT** 许可条款获得许可.

            

Raw data

            {
    "_id": null,
    "home_page": "https://easy-twitter-interactors.xink.top/",
    "name": "easy-twitter-interactors",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">=3.6.8",
    "maintainer_email": "",
    "keywords": "easy,twitter,interactors,reads",
    "author": "hanxinkong",
    "author_email": "xinkonghan@gmail.com",
    "download_url": "https://files.pythonhosted.org/packages/54/c5/622660dc25f7641c876a389c0f4802c02310c1c2f65a84675330aec1b73a/easy_twitter_interactors-1.0.1.tar.gz",
    "platform": null,
    "description": "# easy_twitter_interactors\r\n\r\n\u63a8\u7279\uff08Twitter\uff09\u70b9\u8d5e,\u5237\u9605\u8bfb\u91cf\u7a0b\u5e8f\uff0c\u5e0c\u671b\u80fd\u4e3a\u4f7f\u7528\u8005\u5e26\u6765\u76ca\u5904\u3002\u5982\u679c\u60a8\u4e5f\u60f3\u8d21\u732e\u597d\u7684\u4ee3\u7801\u7247\u6bb5\uff0c\u8bf7\u5c06\u4ee3\u7801\u4ee5\u53ca\u63cf\u8ff0\uff0c\u901a\u8fc7\u90ae\u7bb1\uff08 [xinkonghan@gmail.com](mailto:hanxinkong<xinkonghan@gmail.com>)\r\n\uff09\u53d1\u9001\u7ed9\u6211\u3002\u4ee3\u7801\u683c\u5f0f\u662f\u9075\u5faa\u81ea\u6211\u4e3b\u89c2\uff0c\u5982\u5b58\u5728\u4e0d\u8db3\u656c\u8bf7\u6307\u51fa\uff01\r\n\r\n\r\n----\r\n**\u6587\u6863\u5730\u5740\uff1a\r\n** <a href=\"https://easy-twitter-interactors.xink.top/\" target=\"_blank\">https://easy-twitter-interactors.xink.top/ </a>\r\n\r\n**PyPi\u5730\u5740\uff1a\r\n** <a href=\"https://pypi.org/project/easy-twitter-interactors\" target=\"_blank\">https://pypi.org/project/easy-twitter-interactors </a>\r\n\r\n**GitHub\u5730\u5740\uff1a\r\n** [https://github.com/hanxinkong/easy-twitter-interactors](https://github.com/hanxinkong/easy-twitter-interactors)\r\n\r\n----\r\n\r\n## \u63a8\u7279\u4e09\u4ef6\u5957\uff08\u6709\u9700\u8981\u53ef\u81ea\u884c\u5b89\u88c5\uff09\r\n\r\n- `easy_twitter_publisher` \u63a8\u7279\u53d1\u5e16,\u56de\u5e16,\u8f6c\u8f7d https://pypi.org/project/easy_twitter_publisher\r\n- `easy_twitter_crawler` \u63a8\u7279\u91c7\u96c6 https://pypi.org/project/easy-twitter-crawler\r\n- `easy_twitter_interactors` \u63a8\u7279\u4e92\u52a8\uff08\u70b9\u8d5e,\u5237\u9605\u8bfb\u91cf\u7b49\uff09 https://pypi.org/project/easy_twitter_interactors\r\n\r\n## \u5b89\u88c5\r\n\r\n<div class=\"termy\">\r\n\r\n```console\r\npip install easy-twitter-interactors\r\n```\r\n\r\n</div>\r\n\r\n## \u4e3b\u8981\u529f\u80fd\r\n\r\n- `likes` \u5bf9\u6307\u5b9a\u5e16\u5b50\u70b9\u8d5e\r\n- `reads` \u5bf9\u6307\u5b9a\u5e16\u5b50\u5237\u9605\u8bfb\u91cf\uff08\u6682\u65e0\uff09\r\n\r\n## \u7b80\u5355\u4f7f\u7528\r\n\r\n\u8bbe\u7f6e\u4ee3\u7406\u53cacookie (\u70b9\u8d5e\u548c\u9605\u8bfb\u5747\u9700\u8981\u8bbe\u7f6ecookie)\r\n\r\n```python\r\nproxy = {\r\n    'http': 'http://127.0.0.1:10808',\r\n    'https': 'http://127.0.0.1:10808'\r\n}\r\ncookie = 'auth_token=686fa28f49400698820d0a3c344c51efdeeaf73a; ct0=5bed99b7faad9dcc742eda564ddbcf37888f8794abd6d4d736919234440be2172da1e9a9fc48bb068db1951d1748ba5467db2bc3e768f122794265da0a9fa6135b4ef40763e7fd91f730d0bb1298136b'\r\n```\r\n\r\n\u70b9\u8d5e\u4f7f\u7528\u6848\u4f8b\uff08\u5bf9\u6307\u5b9a\u5e16\u5b50\u70b9\u8d5e\uff09\r\n\r\n```python\r\nfrom easy_spider_tool import format_json\r\nfrom easy_twitter_interactors import TwitterLikes, get_headers\r\n\r\ntwitter_likes = TwitterLikes()\r\ntwitter_likes.set_proxy(proxy)\r\ntwitter_likes.set_headers(get_headers(cookie))\r\nlikes_info = twitter_likes.likes('1690065356495421444')\r\nprint(format_json(likes_info))\r\n```\r\n\r\n\u70b9\u8d5e\u53c2\u6570\u8bf4\u660e\r\n\r\n| \u5b57\u6bb5\u540d         | \u7c7b\u578b     | \u5fc5\u987b | \u63cf\u8ff0                                                                                     |\r\n|-------------|--------|----|----------------------------------------------------------------------------------------|\r\n| to_tweet_id | string | \u662f  | \u76ee\u6807\u5e16\u5b50id\uff08https://twitter.com/elonmusk/status/1690164670441586688 \u4e2d\u7684 1690164670441586688\uff09 |\r\n\r\n___\r\n\r\n## \u4f9d\u8d56\r\n\r\n\u5185\u7f6e\u4f9d\u8d56\r\n\r\n- `typing` Type Hints for Python.\r\n- `json` Type Hints for Python.\r\n\r\n\u7b2c\u4e09\u65b9\u4f9d\u8d56\r\n\r\n- `requests` An XPath for JSON.\r\n- `loguru` An XPath for JSON.\r\n- `urllib3` Python library used for working with timezone information.\r\n- `easy_spider_tool` Python library used for working with timezone information.\r\n\r\n_\u6ce8\uff1a\u4f9d\u8d56\u987a\u5e8f\u6392\u540d\u4e0d\u5206\u5148\u540e_\r\n\r\n## \u94fe\u63a5\r\n\r\nGithub\uff1ahttps://github.com/hanxinkong/easy-twitter-interactors\r\n\r\n\u5728\u7ebf\u6587\u6863\uff1ahttps://easy-twitter-interactors.xink.top\r\n\r\n## \u8d21\u732e\u8005\r\n\r\n## \u8bb8\u53ef\u8bc1\r\n\r\n\u8be5\u9879\u76ee\u6839\u636e **MIT** \u8bb8\u53ef\u6761\u6b3e\u83b7\u5f97\u8bb8\u53ef.\r\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "\u7b80\u6613\u3001\u597d\u7528\u7684\u63a8\u7279(Twitter)\u70b9\u8d5e\uff0c\u5237\u9605\u8bfb\u91cf\u7a0b\u5e8f",
    "version": "1.0.1",
    "project_urls": {
        "Homepage": "https://easy-twitter-interactors.xink.top/"
    },
    "split_keywords": [
        "easy",
        "twitter",
        "interactors",
        "reads"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "59a529b0d698f4beca0473eb4811246a41fe3b0402c8af4f3e19ed6004a6e4ba",
                "md5": "558c3bd73fc27ff18f44c51b9014f322",
                "sha256": "92ada714514a9a5ec496958edd09f4f3d5a979e3f33608e1a3c8f6bd2756503e"
            },
            "downloads": -1,
            "filename": "easy_twitter_interactors-1.0.1-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "558c3bd73fc27ff18f44c51b9014f322",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.6.8",
            "size": 7755,
            "upload_time": "2023-09-09T03:44:31",
            "upload_time_iso_8601": "2023-09-09T03:44:31.120777Z",
            "url": "https://files.pythonhosted.org/packages/59/a5/29b0d698f4beca0473eb4811246a41fe3b0402c8af4f3e19ed6004a6e4ba/easy_twitter_interactors-1.0.1-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "54c5622660dc25f7641c876a389c0f4802c02310c1c2f65a84675330aec1b73a",
                "md5": "6c45f545dceefb886e901d75f311536d",
                "sha256": "beff131111b183a9ed37d473c63353bcc4fa0342206b8976940b425a48b8b119"
            },
            "downloads": -1,
            "filename": "easy_twitter_interactors-1.0.1.tar.gz",
            "has_sig": false,
            "md5_digest": "6c45f545dceefb886e901d75f311536d",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.6.8",
            "size": 5485,
            "upload_time": "2023-09-09T03:44:34",
            "upload_time_iso_8601": "2023-09-09T03:44:34.194079Z",
            "url": "https://files.pythonhosted.org/packages/54/c5/622660dc25f7641c876a389c0f4802c02310c1c2f65a84675330aec1b73a/easy_twitter_interactors-1.0.1.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2023-09-09 03:44:34",
    "github": false,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "lcname": "easy-twitter-interactors"
}
        
Elapsed time: 0.15631s