gterrusa / laravel-google-calendar
Laravel Google Calendar 包
0.2.1
2023-04-10 18:17 UTC
Requires
- php: ^7.4|^8.0
- illuminate/contracts: ^7.0|^8.0
- maatwebsite/excel: ^3.1
- rlanvin/php-rrule: ^2.3
- spatie/laravel-google-calendar: ^3.4
- spatie/laravel-package-tools: ^1.9.2
Requires (Dev)
- nunomaduro/collision: ^5.10
- nunomaduro/larastan: ^1.0
- orchestra/testbench: ^6.22
- pestphp/pest: ^1.21
- pestphp/pest-plugin-laravel: ^1.1
- phpstan/extension-installer: ^1.1
- phpstan/phpstan-deprecation-rules: ^1.0
- phpstan/phpstan-phpunit: ^1.0
- phpunit/phpunit: ^9.5
- spatie/laravel-ray: ^1.26
- dev-main
- 0.2.1
- 0.2.0
- 0.1.9
- 0.1.8
- 0.1.7
- 0.1.6
- 0.1.5
- 0.1.4
- 0.1.3
- 0.1.2
- 0.1.1
- 0.1.0
- 0.0.9
- 0.0.8
- 0.0.7
- 0.0.6
- 0.0.5
- 0.0.4
- 0.0.3
- 0.0.2
- 0.0.1
- dev-dependabot/github_actions/stefanzweifel/git-auto-commit-action-5
- dev-dependabot/github_actions/actions/checkout-4
- dev-dependabot/github_actions/ramsey/composer-install-2
This package is auto-updated.
Last update: 2024-09-09 22:34:24 UTC
README
这是一个Spatie Laravel Google Calendar的包装器,它扩展了其使用范围。
安装
您可以通过Composer安装此包
composer require gterrusa/laravel-google-calendar
您可以使用以下命令发布配置文件
php artisan vendor:publish --provider="GTerrusa\LaravelGoogleCalendar\LaravelGoogleCalendarServiceProvider"
这是已发布配置文件的内容
return [ 'default_auth_profile' => env('GOOGLE_CALENDAR_AUTH_PROFILE', 'oauth'), 'auth_profiles' => [ /* * Authenticate using a service account. */ 'service_account' => [ /* * Path to the json file containing the credentials. */ 'credentials_json' => env( 'GOOGLE_SERVICE_ACCOUNT_CREDENTIALS_PATH', storage_path('google-calendar/service-account-credentials.json') ), ], /* * Authenticate with actual google user account. */ 'oauth' => [ /* * Path to the json file containing the oauth2 credentials. */ 'credentials_json' => env( 'GOOGLE_OAUTH_CREDENTIALS_PATH', storage_path('google-calendar/oauth-credentials.json') ), /* * Path to the json file containing the oauth2 token. */ 'token_json' => env( 'GOOGLE_OAUTH_TOKEN_PATH', storage_path('google-calendar/oauth-token.json') ), ] ], /* * The id of the Google Calendar that will be used by default. */ 'calendar_id' => env('GOOGLE_CALENDAR_ID'), ];
Google日历集成
- 在Google Cloud Console中登录或创建一个账户
- 启用Google日历API
- 点击
- APIs & Services
- 凭证
- 创建凭证
- OAuth客户端ID
- Web应用程序
- 包括授权端点并创建。
- 下载凭证并将其内容粘贴到
storage/google-calendar/oauth-credentials.json
- 将
GOOGLE_CALENDAR_ID={{ google-cloud-email-address-here }}
添加到您的.env文件中 - 运行
php artisan laravel-google-calendar:quickstart
并按照提示操作
测试
composer test
更改日志
有关最近更改的更多信息,请参阅更改日志。
贡献
有关详细信息,请参阅贡献指南。
安全漏洞
有关如何报告安全漏洞的详细信息,请参阅我们的安全策略。
致谢
许可
MIT许可(MIT)。有关更多信息,请参阅许可文件。