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

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
Convert Eloquent Models to HLS Video image

Convert Eloquent Models to HLS Video

Read article
Get expert guidance in a few days with a Laravel code review logo

Get expert guidance in a few days with a Laravel code review

Expert code review! Get clear, practical feedback from two Laravel devs with 10+ years of experience helping teams build better apps.

Get expert guidance in a few days with a Laravel code review
Tighten logo

Tighten

We help companies turn great ideas into amazing apps, products, and services.

Tighten
CodeKudu logo

CodeKudu

Stand-ups, Retrospectives, and 360° Feedback for the entire team. 50% off with code LARAVELNEWS.

CodeKudu
DreamzTech logo

DreamzTech

Hire 6-10+ Yrs. experienced skilled Laravel Developers from DreamzTech. We ensure NDA protected, 100% quality delivery. Contact Us & Discuss Your Need.

DreamzTech
Celebian logo

Celebian

Celebian is a social media marketing agency specializing in helping their clients go viral on TikTok. Whether you're looking to reach a bigger audience or gain more Tiktok followers, likes, and views, they've got you covered.

Celebian
PhpStorm logo

PhpStorm

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

PhpStorm