The go-to PHP IDE with extensive out-of-the-box support for Laravel and its ecosystem.

Apple

socialiteproviders/apple image

Apple stats

Downloads
2.7M
Stars
39
Open Issues
2
Forks
42

View on GitHub →

Apple OAuth2 Provider for Laravel Socialite

Laravel SocialiteProviders/Apple Package

The socialiteproviders/apple package enables Laravel applications to authenticate users via Apple ID using Laravel Socialite. This integration simplifies the process of adding "Sign In with Apple" functionality to your application.

Key Features:

  • Simple Integration: Leverage Laravel Socialite for streamlined OAuth handling.
  • Configurable: Easily configure client IDs, secrets, and redirect URIs through Laravel's config/services.php.
  • Dynamic Client Secret Management: Supports generating JWT token-based client secrets with a maximum lifetime of 6 months, crucial for maintaining "Sign In with Apple" sessions.
  • Event Listening: Utilize Laravel's event system to hook into Socialite's OAuth flow.
  • User Data: Retrieve basic user information such as id, name, and email.

Installation:

  1. Require the Package:

    composer require socialiteproviders/apple
  2. Configuration: Add the following to your config/services.php:

    'apple' => [
    'client_id' => env('APPLE_CLIENT_ID'),
    'client_secret' => env('APPLE_CLIENT_SECRET'),
    'redirect' => env('APPLE_REDIRECT_URI')
    ],

    Refer to external guides for setting up Apple ID authentication and generating the client secret:

  3. Add Event Listener: Register the event listener in app/Providers/EventServiceProvider:

    protected $listen = [
    \SocialiteProviders\Manager\SocialiteWasCalled::class => [
    \SocialiteProviders\Apple\AppleExtendSocialite::class.'@handle',
    ],
    ];

Basic Usage:

To initiate the authentication process, use:

return Socialite::driver('apple')->redirect();

Additional References:

This package provides a robust solution for integrating Apple's authentication system into Laravel projects, ensuring a smooth user experience with essential security features.

SocialiteProviders photo

Socialite Providers for Laravel

Cube

Laravel Newsletter

Join 40k+ other developers and never miss out on new tips, tutorials, and more.


Socialiteproviders Apple Related Articles

Generate HTML Password Rules Attribute in Laravel 13.9.0 image

Generate HTML Password Rules Attribute in Laravel 13.9.0

Read article
Laravel Web Push Notifications image

Laravel Web Push Notifications

Read article
Laravel Mobile Pass: Generate Apple Wallet and Google Wallet Passes image

Laravel Mobile Pass: Generate Apple Wallet and Google Wallet Passes

Read article
FluentVox: AI Text-to-Speech for Laravel with Voice Cloning and GPU Acceleration image

FluentVox: AI Text-to-Speech for Laravel with Voice Cloning and GPU Acceleration

Read article
The Bifrost is About to Open image

The Bifrost is About to Open

Read article
Create Apple Wallet Passes in Laravel image

Create Apple Wallet Passes in Laravel

Read article
PhpStorm logo

PhpStorm

The go-to PHP IDE with extensive out-of-the-box support for Laravel and its ecosystem.

PhpStorm
Statamic logo

Statamic

The drop-in ready Laravel CMS you’re been waiting for. Go full-stack or headless, flat file or database – it’s up to you.

Statamic
SaaSykit: Laravel SaaS Starter Kit logo

SaaSykit: Laravel SaaS Starter Kit

SaaSykit is a Multi-tenant Laravel SaaS Starter Kit that comes with all features required to run a modern SaaS. Payments, Beautiful Checkout, Admin Panel, User dashboard, Auth, Ready Components, Stats, Blog, Docs and more.

SaaSykit: Laravel SaaS Starter Kit
No Compromises logo

No Compromises

Joel and Aaron, the two seasoned devs from the No Compromises podcast, are now available to hire for your Laravel project. ⬧ Flat rate of $9500/mo. ⬧ No lengthy sales process. ⬧ No contracts. ⬧ 100% money back guarantee.

No Compromises
Securing Laravel logo

Securing Laravel

The essential security resource for Laravel devs, covering everything you need to keep your apps secure. Sign up to receive weekly security tips and monthly in depth articles, diving deep into security concepts you need to know!

Securing Laravel
Typesense Search logo

Typesense Search

Typesense is an open source, blazing-fast search engine, optimized for helping you build delightful search experiences for your sites and apps. Natively integrated with Laravel Scout.

Typesense Search