Download the PHP package martinbean/socialite-discord-provider without Composer

On this page you can find all versions of the php package martinbean/socialite-discord-provider. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package socialite-discord-provider

Discord provider for Laravel Socialite

A provider for Laravel Socialite that allows authentication as a Discord user or bot.

Installation

Usage

The package registers a Socialite driver with the name of discord.

Before using the driver, create an OAuth application in Discord’s developer portal: https://discord.com/developers/applications

Set your client ID and client secret as environment variables, and then reference them in your config/services.php file. You will also need to add a redirect URL to your application if you intend to authenticate as a user.

The redirect value will need to match a redirect URL in your Discord application settings. It can be relative as above.

Authenticating as a user

Create a controller to redirect and handle the access token callback:

Scopes

Discord supports various scopes when authenticating as a user. You can find a list here: https://discord.com/developers/docs/topics/oauth2#shared-resources-oauth2-scopes

To request additional scopes when authenticating, you can use the scopes method before redirecting:

Authenticating as a bot

Discord allows you to add “bots” to guilds (servers). This is a modified OAuth flow, where you are redirected to Discord to confirm the guild you wish to add a bot to. There is no redirect back to your application when you authorize the request.

You can authenticate as a bot by using the bot method before redirecting:

If you know the guild ID you wish to add your bot to, you may specify it with the guild method:

Additionally, you can disable the guild select:

Note: if you try and disable guild selection without specifying a guild, the package will throw a GuildRequiredException instance.

Issues

If you have any problems using this package, please open an issue on the GitHub repository.


All versions of socialite-discord-provider with dependencies

PHP Build Version
Package Version
Requires facade/ignition-contracts Version ^1.0
laravel/socialite Version ^4.0|^5.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package martinbean/socialite-discord-provider contains the following files

Loading the files please wait ....