Download the PHP package itwmw/go-cq-http-sdk without Composer

On this page you can find all versions of the php package itwmw/go-cq-http-sdk. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package go-cq-http-sdk

go-cqhttp-sdk

[go-cqhttp](https://github.com/Mrs4s/go-cqhttp)项目的PHP版SDK,拥有完整注释和代码提示

license release php-version

文档 · 下载 · 开始使用

安装

使用示例

处理上报消息

SDK内置消息的处理:

你可以通过中间件模式来处理消息:

使用独立的类来处理消息

也支持callable类型的处理器

注册指定类型的处理器

同样也支持使用独立的类来处理消息

快捷操作

部分类型的消息支持快捷操作,快捷操作的方法为 response,例:

支持

Bot账号相关的Api | API | 功能 | | ------------------------ | ---------------------- | | getLoginInfo | 获取登录号信息 | | setQqProfile | 设置登录号资料 | | qiDianGetAccountInfo | 获取企点账号信息 | | getModelShow | 获取在线机型 | | setModelShow | 设置在线机型 | | getOnlineClients | 获取当前账号在线客户端列表 |
好友相关的Api | API | 功能 | | ------------------------ | ---------------------- | | getStrangerInfo | 获取陌生人信息 | | GetFriendList | 获取好友列表 | | getUnidirectionalFriendList | 获取单向好友列表 | | deleteFriend | 删除好友 | | deleteUnidirectionalFriend | 删除单向好友 | | getOnlineClients | 获取当前账号在线客户端列表 |
消息相关的Api | API | 功能 | | ------------------------ | ---------------------- | | sendPrivateMsg | 发送私聊消息 | | sendGroupMsg | 发送群聊消息 | | sendMsg | 发送消息 | | getMsg | 获取消息 | | deleteMsg | 撤回消息 | | markMsgAsRead | 标记消息已读 | | getForwardMsg | 获取合并转发内容 | | sendGroupForwardMsg | 发送合并转发 ( 群聊 ) | | sendPrivateForwardMsg | 发送合并转发 ( 好友 ) | | getGroupMsgHistory | 获取群消息历史记录 |
图片相关的Api | API | 功能 | | ------------------------ | ---------------------- | | getImage | 获取图片信息 | | canSendImage | 检查是否可以发送图片 | | ocrImage | 图片 OCR |
语音相关的Api | API | 功能 | | ------------------------ | ---------------------- | | getRecord | 获取语音 | | canSendRecord | 检查是否可以发送语音 |
处理请求相关的Api | API | 功能 | | ------------------------ | ---------------------- | | setFriendAddRequest | 处理加好友请求 | | setGroupAddRequest | 处理加群请求/邀请 |
群信息相关的Api | API | 功能 | | ------------------------ | ---------------------- | | getGroupInfo | 获取群信息 | | getGroupList | 获取群列表 | | getGroupMemberInfo | 获取群成员信息 | | getGroupMemberList | 获取群成员列表 | | getGroupHonorInfo | 获取群荣誉信息 | | getGroupSystemMsg | 获取群系统消息 | | getEssenceMsgList | 获取精华消息列表 | | getGroupAtAllRemain | 获取群 @全体成员 剩余次数 |
群设置相关的Api | API | 功能 | | ------------------------ | ---------------------- | | setGroupName | 设置群名 | | setGroupPortrait | 设置群头像 | | setGroupAdmin | 设置群管理员 | | setGroupCard | 设置群名片 ( 群备注 ) | | setGroupSpecialTitle | 设置群组专属头衔 |
群操作相关的Api | API | 功能 | | ------------------------ | ---------------------- | | setGroupBan | 群单人禁言 | | setGroupWholeBan | 群全员禁言 | | setGroupAnonymousBan | 群匿名用户禁言 | | setEssenceMsg | 设置精华消息 | | deleteEssenceMsg | 移出精华消息 | | sendGroupSign | 群打卡 | | setGroupAnonymous | 群设置匿名 | | sendGroupNotice | 发送群公告 | | getGroupNotice | 获取群公告 | | setGroupKick | 群组踢人 | | setGroupLeave | 退出群组 |
群文件相关的Api | API | 功能 | | ------------------------ | ---------------------- | | uploadGroupFile | 上传群文件 | | deleteGroupFile | 删除群文件 | | createGroupFileFolder | 创建群文件文件夹 | | deleteGroupFolder | 删除群文件文件夹 | | getGroupFileSystemInfo | 获取群文件系统信息 | | getGroupRootFiles | 获取群根目录文件列表 | | getGroupFilesByFolder | 获取群子目录文件列表 | | getGroupFileUrl | 获取群文件资源链接 | | uploadPrivateFile | 上传私聊文件 |
Go-CqHttp相关的Api | API | 功能 | | ------------------------ | ---------------------- | | getCookies | 获取 Cookies | | getCsrfToken | 获取 CSRF Token | | getCredentials | 获取 QQ 相关接口凭证 | | getVersionInfo | 获取版本信息 | | getStatus | 获取状态 | | cleanCache | 清理缓存 | | reloadEventFilter | 重载事件过滤器 | | downloadFile | 下载文件到缓存目录 | | checkUrlSafely | 检查链接安全性 | | getWordSlices | 获取中文分词 ( 隐藏 API ) | | handleQuickOperation | 对事件执行快速操作 ( 隐藏 API ) |
CQ 码支持 | 对应的类 | 功能 | | ----------------------------- | ---------------------- | | `Itwmw\GoCqHttp\CqCode\Face` | QQ 表情 | | `Itwmw\GoCqHttp\CqCode\Record` | 语音 | | `Itwmw\GoCqHttp\CqCode\Video` | 短视频 | | `Itwmw\GoCqHttp\CqCode\At` | @某人 | | `Itwmw\GoCqHttp\CqCode\Share` | 链接分享 | | `Itwmw\GoCqHttp\CqCode\Music` | 音乐分享 | | `Itwmw\GoCqHttp\CqCode\MusicCustom` | 自定义音乐分享 | | `Itwmw\GoCqHttp\CqCode\Image` | 图片 | | `Itwmw\GoCqHttp\CqCode\Reply` | 回复 | | `Itwmw\GoCqHttp\CqCode\RedBag` | 红包 | | `Itwmw\GoCqHttp\CqCode\Poke` | 戳一戳 | | `Itwmw\GoCqHttp\CqCode\Gift` | 礼物 | | `Itwmw\GoCqHttp\CqCode\Forward` | 合并转发 | | `Itwmw\GoCqHttp\CqCode\Xml` | XML 消息 | | `Itwmw\GoCqHttp\CqCode\Json` | JSON 消息 | | `Itwmw\GoCqHttp\CqCode\CardImage` | 装逼大图 | | `Itwmw\GoCqHttp\CqCode\Tts` | 文本转语音 | #### 使用示例 发送: 解析接受到的消息:

关于:

QQ群: 852297017


All versions of go-cq-http-sdk with dependencies

PHP Build Version
Package Version
Requires php Version >=8.0
guzzlehttp/guzzle Version ^6.5.8|^7.4.5
ext-mbstring Version *
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package itwmw/go-cq-http-sdk contains the following files

Loading the files please wait ....