6899bad529739b926eab308ebf6684b30fbb5ad5
1. 创建 app/util/HttpClient.php - 公共 HTTP 请求类 - httpGet() 和 httpPost() 方法 - 支持自定义 headers 和 timeout - 统一错误处理和日志 2. 创建 app/util/FeishuUtil.php - 飞书授权工具类,可被其他业务模块复用 - getAppAccessToken() - 获取应用访问令牌(带缓存) - getUserAccessToken() - 获取用户访问令牌 - getUserInfo() - 获取用户信息 - getCompleteUserInfo() - 一步获取完整用户信息 - clearTokenCache() - 清除 token 缓存 3. 重构 app/service/FeishuService.php - 使用新的工具类 - 移除重复的 HTTP 请求方法 - 保持向后兼容 飞书授权流程: 1. app_access_token (应用级令牌) 2. user_access_token (用户级令牌,需要 app_access_token) 3. 用户信息 (需要 user_access_token) Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Description
No description provided
Languages
PHP
48.9%
TypeScript
36.8%
CSS
7.7%
HTML
3.9%
Shell
2.2%
Other
0.5%