fbizi/google-meet
Composer 安装命令:
composer require fbizi/google-meet
包简介
Google calendar events with meet conference
README 文档
README
Lightweight Google Calendar API library for managing events on Google Calendar. You can create event with video conference (google meet), update and cancel. The library focus only on Calendar Events resource.
Installation
Package is available on Packagist, you can install it using Composer.
composer require fbizi/google-meet
Dependencies
- PHP 7.4+
Basic usage
Before use this library make sure to register a Google Application and enable Calendar API on Google Cloude Console, so you can make APIs calls. Follow this guide if you don't have yet.
use FBIZI\Calendar\GoogleCalendar; $calendar = new GoogleCalendar(CLIENT_ID, CLIENT_REDIRECT_URL, CLIENT_SECRET); // Generate authenticate url link so you can call it $url = GoogleCalendar::auth(string $client_redirect_url, string $client_id, string $access_type optional, bool $redirect optional); // check if get the response code after calling the authentication url if(isset($_GET['code']) && !empty($_GET['code'])){ $code = $_GET['code']; $calendar->getAccessToken($code); // if you want to save the token and refresh_token somewhere for use later e.g DB just call this $token_to_save = $calendar->token; $refresh_token_to_save = $calendar->refresh_token; // if want to assign saved token and refresh_token just do this $calendar->token = $token_to_save; $calendar->refresh_token = $refresh_token_to_save; // for event creation $timezone = $calendar->getCalendarTimezone(); // to get user calendar timezone $args = [ "title" => "Event title", // optional "description" => "Event description", // optional "start" => [ "dateTime" => "2024-12-31T12:00:00", "timeZone" => $timezone['value'] ], "end" => [ "dateTime" => "2024-12-31T13:00:00", "timeZone" => $timezone['value'], ], "attendees" => [ ["email" => "test1@test.com"] ], "meet_id" => "jdjhjdhdjdj", // optional ]; $event = GoogleCalendar::eventData(array $args); $data = $calendar->createEvent(array $event, string $calendar_id optional); // on successful will get the event resource // retrive event id or meet link $data['id'] | $data['hangoutLink'] // for event update $timezone = $calendar->getCalendarTimezone(); // to get user calendar timezone $args['attendees'] = [ ["email" => "test1@test.com"], ["email" => "test2@test.com"] // add 1 more attendee ]; $event_id = $data['id']; $event = GoogleCalendar::eventData(array $args); $data = $calendar->updateEvent(string $event_id, array $event, string $calendar_id optional); // on successful will get the event resource // for event cancellation $calendar->cancelEvent($data['id']); // explore other methods such as get event or calendar by id }
Donation
Methods :
If this project help you reduce time to develop, you can give me a cup of coffee :)
fbizi/google-meet 适用场景与选型建议
fbizi/google-meet 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 55 次下载、GitHub Stars 达 0, 最近一次更新时间为 2022 年 10 月 09 日, 在 PHP 生态内属于活跃度较高的组件。
它主要适用于以下技术方向: 「calendar」 「events」 「google」 「meeting」 「Video Call」 等业务场景。在实际项目中,围绕这些方向常见需要落地的问题包括:接口对接、性能调优、并发安全、与既有框架(Laravel / ThinkPHP / Yii / Webman 等)的兼容适配,以及生产环境的日志埋点与稳定性保障。
我们在过去多个企业项目中使用过 fbizi/google-meet 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。
基于 fbizi/google-meet 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。
线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。
承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。
与 fbizi/google-meet 相关的其它包
同方向 / 同关键字的高下载量 PHP Composer 包推荐,方便对比选型:
A modern PHP library for generating iCalendar v2.0 events
Библиотека для реализаций паттерна Pub/Sub
Wireless Cross-Component Communication
A powerful event calendar Tool for Laravel's Nova 5.
Check for holidays - localeaware
Command bus implementation: Commands and domain events
统计信息
- 总下载量: 55
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 1
- 点击次数: 18
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2022-10-09