PHPackages                             itisbean/weibohit - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. itisbean/weibohit

ActiveLibrary

itisbean/weibohit
=================

Hit the ranking for Weibo

1.2.10(5y ago)7344[1 issues](https://github.com/itisbean/weibo-hit/issues)MITPHPPHP &gt;=5.6.0

Since Oct 16Pushed 5y ago1 watchersCompare

[ Source](https://github.com/itisbean/weibo-hit)[ Packagist](https://packagist.org/packages/itisbean/weibohit)[ Docs](https://github.com/itisbean/weibo-hit)[ RSS](/packages/itisbean-weibohit/feed)WikiDiscussions main Synced 4w ago

READMEChangelog (10)Dependencies (3)Versions (15)Used By (0)

weibo-hit
=========

[](#weibo-hit)

Sina weibo api for php. Including login, post, repost, comment, sign topic...

Composer install
----------------

[](#composer-install)

composer require itisbean/weibohit -vvv

Demo
----

[](#demo)

Demo:  左上角➡️拉開

Usage
-----

[](#usage)

```
// 引入autoload.php（框架中使用不需要）
include_once __DIR__.'/../vendor/autoload.php';
$whitInstance = \Weibohit\Weibohit::init([
    'username' => 'your account',
    'password' => 'your password',
    'doorImgPath' => 'if need door code, the door image would be saved here'
]);
// 發微博
$ret = $whitInstance->post('I am a robot');
// 評論
$whitInstance->comment($ret['data'], 'right');
```

Function
--------

[](#function)

### post

[](#post)

```
/**
 * 发微博
 * @param string $text 发送微博的文字内容
 * @return array
 */
$whitInstance->post($text);
```

### repost

[](#repost)

```
/**
 * 转发
 * @param string $mid 原贴ID
 * @param string $text 发送微博的文字内容
 * @return array
 */
public function repost($mid, $text = '');
```

### comment from pc

[](#comment-from-pc)

```
/**
 * 评论帖子
 * @param string $mid 贴子ID
 * @param string $text 评论内容
 * @return array
 */
public function comment($mid, $text = '');
```

### Comment from mobile

[](#comment-from-mobile)

```
/**
 * 移動端評論帖子
 * @param string $mid
 * @param string $text
 * @param boolean $istry
 * @return array
 */
public function mComment($mid, $text, $istry = false);
```

### like or cancel like

[](#like-or-cancel-like)

```
/**
 * 点赞或取消
 * @param string $mid 贴子ID
 * @return array
 */
public function like($mid);
```

### sign in the super topic

[](#sign-in-the-super-topic)

```
/**
 * 超话签到
 * @param string $tid 超话ID
 * @return array
 */
public function topicSign($tid);
```

### post in the super topic

[](#post-in-the-super-topic)

```
/**
 * 超话发贴
 * @param string $tid 超话ID
 * @param string $text 贴子内容
 * @return array
 */
public function topicPost($tid, $text);
```

### get tv info

[](#get-tv-info)

```
/**
 * 微博视频信息
 * @param string $tvurl
 * @return array
 */
public function getTvinfo($tvurl);
```

### get self info

[](#get-self-info)

```
/**
 * 获取登录用户ID
 * @return array
 */
public function getSelf()
```

### send incrspt cards

[](#send-incrspt-cards)

```
/**
 * 送加油卡
 * @param integer $num 送卡数量
 * @param string $text 发送微博的文字内容
 * @return array
 */
public function incrspt($num = 1, $text = '');
```

###  Health Score

27

—

LowBetter than 49% of packages

Maintenance17

Infrequent updates — may be unmaintained

Popularity15

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity56

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~3 days

Total

14

Last Release

1985d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/b09bb3e4c2760b2cf1ee6ad697aec21185a3b2a4074339892333dfea2c996e36?d=identicon)[dony](/maintainers/dony)

---

Top Contributors

[![itisbean](https://avatars.githubusercontent.com/u/32357214?v=4)](https://github.com/itisbean "itisbean (33 commits)")

---

Tags

weiboweiborankhit

### Embed Badge

![Health badge](/badges/itisbean-weibohit/health.svg)

```
[![Health](https://phpackages.com/badges/itisbean-weibohit/health.svg)](https://phpackages.com/packages/itisbean-weibohit)
```

###  Alternatives

[laravel/socialite

Laravel wrapper around OAuth 1 &amp; OAuth 2 libraries.

5.7k96.9M669](/packages/laravel-socialite)[shopware/platform

The Shopware e-commerce core

3.3k1.5M3](/packages/shopware-platform)[overtrue/socialite

A collection of OAuth 2 packages.

1.4k5.5M86](/packages/overtrue-socialite)[magento/community-edition

Magento 2 (Open Source)

12.1k52.1k10](/packages/magento-community-edition)[civicrm/civicrm-core

Open source constituent relationship management for non-profits, NGOs and advocacy organizations.

728272.9k17](/packages/civicrm-civicrm-core)[shopware/core

Shopware platform is the core for all Shopware ecommerce products.

595.2M385](/packages/shopware-core)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
