tomshaw/google-api
Laravel Google OAuth 2.0 service client with configurable token storage (DB or custom), published config, and migrations. Integrates google/apiclient-services and supports Composer cleanup to include only the Google APIs you need (e.g., Gmail, Calendar).
client->calendar()->createEvent()).Adopt This Package If:
Look Elsewhere If:
*"This package lets us integrate Google services into our Laravel app faster and with less risk. Instead of spending weeks building OAuth 2.0 from scratch or debugging Google’s official SDK, we can:
It’s a low-risk, high-reward choice—like using a pre-built bridge instead of building one from scratch."*
*"This package solves three critical pain points for Google API integration in Laravel:
google/apiclient setup.GoogleClient in controllers) and fluent interfaces (e.g., client->gmail()->send()) for idiomatic code.Gmail, Calendar), reducing bundle size and startup time.Trade-offs:
Recommendation: Use this for auth, data sync, and productivity tools. For unsupported APIs, wrap the official SDK directly."*
*"Key advantages:
client->calendar()->events()->create() for readability.Gmail + Drive) via composer.json.Example Workflow:
// 1. Redirect user to Google for auth
return $client->createAuthUrl();
// 2. Handle callback and store token
$client->fetchAccessTokenWithAuthCode($request->code);
// 3. Use any Google API (e.g., send an email)
$client->gmail()->send($mailable);
When to Avoid: If you need unsupported APIs or legacy PHP/Laravel versions."*
How can I help you explore Laravel packages today?