SocialiteProviders / SalesForce by m1guelpf

SalesForce OAuth2 Provider for Laravel Socialite
268,467
4
4
Package Data
Maintainer Username: m1guelpf
Maintainer Contact: andy@awendt.com (Andy Wendt)
Package Create Date: 2016-01-11
Package Last Update: 2023-11-07
Home Page: https://socialiteproviders.com/SalesForce/
Language: PHP
License: MIT
Last Refreshed: 2024-02-22 15:00:20
Package Statistics
Total Downloads: 268,467
Monthly Downloads: 12,200
Daily Downloads: 464
Total Stars: 4
Total Watchers: 4
Total Forks: 1
Total Open Issues: 1

SalesForce

composer require socialiteproviders/salesforce

Installation & Basic Usage

Please see the Base Installation Guide, then follow the provider specific instructions below.

Add configuration to config/services.php.

'SalesForce' => [    
  'client_id' => env('SALESFORCE_CLIENT_ID'),  
  'client_secret' => env('SALESFORCE_CLIENT_SECRET'),  
  'redirect' => env('SALESFORCE_REDIRECT_URI') 
],

Add provider event listener

Configure the package's listener to the listen for SocialiteWasCalled events.

Add the event to your listen[] array in app/Providers/EventServiceProvider. See the Base Installation Guide for detailed instructions.

protected $listen = [
    \SocialiteProviders\Manager\SocialiteWasCalled::class => [
        // ... other providers
        'SocialiteProviders\\SalesForce\\SalesForceExtendSocialite@handle',
    ],
];

Usage

You should now be able to use the provider like you would regularly use Socialite (assuming you have the facade installed):

return Socialite::with('SalesForce')->redirect();