Download the PHP package litepie/otp without Composer

On this page you can find all versions of the php package litepie/otp. 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 otp

Laravel OTP Package

Tests Code Style Static Analysis Total Downloads Latest Stable Version License

A comprehensive Laravel package for generating, signing and managing OTP (One-Time Password) codes with multiple channels support.

๐Ÿ“‹ Requirements

๐Ÿš€ Features

๐Ÿ“ฆ Installation

You can install the package via Composer:

Publish Configuration

Publish the configuration file:

Run Migrations

Run the migrations to create the OTPs table:

Set Up Automatic Cleanup (Optional)

Add the following to your app/Console/Kernel.php file to automatically clean up expired OTPs:

๐Ÿ”ง Configuration

The configuration file config/otp.php allows you to customize:

Environment Variables

Add these to your .env file:

๐Ÿ“– Usage

Quick Start

Advanced Usage

Exception Handling

๐ŸŽฏ OTP Types

The package supports multiple OTP types with individual configurations:

Built-in Types

Type Use Case Default Length Default Expiry
login User authentication 6 digits 5 minutes
email_verification Email verification 6 digits 10 minutes
password_reset Password reset 8 characters 15 minutes
two_factor 2FA authentication 6 digits 3 minutes
phone_verification Phone verification 6 digits 5 minutes

Custom Types

Define custom OTP types in your configuration:

๐Ÿ“ก Delivery Channels

Email Channel

Sends OTP via email using Laravel's notification system or traditional mail.

SMS Channel

Send OTPs via SMS using various providers:

Supported SMS Providers:

Database Channel

Store OTP in database for manual retrieval:

Multiple Channels

Send via multiple channels simultaneously:

Custom Channels

Create custom delivery channels:

๐Ÿ“Š Events

The package fires comprehensive events for monitoring and logging:

Available Events

Event Listeners

Example Listener

๐Ÿ› ๏ธ Artisan Commands

Cleanup Expired OTPs

๐Ÿ”’ Security Features

๐Ÿงช Testing

Running Tests

Test Example

๐Ÿ“š Documentation

๐Ÿค Contributing

We welcome contributions! Please see CONTRIBUTING.md for details.

Development Setup

๐Ÿ” Security

If you discover a security vulnerability, please send an email to [email protected]. All security vulnerabilities will be promptly addressed.

๐Ÿ“„ License

The MIT License (MIT). Please see License File for more information.

๐Ÿ’– Support


Made with โค๏ธ by Litepie


All versions of otp with dependencies

PHP Build Version
Package Version
Requires php Version ^8.2
illuminate/support Version ^10.0|^11.0|^12.0
illuminate/database Version ^10.0|^11.0|^12.0
illuminate/mail Version ^10.0|^11.0|^12.0
illuminate/notifications Version ^10.0|^11.0|^12.0
illuminate/console Version ^10.0|^11.0|^12.0
illuminate/cache Version ^10.0|^11.0|^12.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 litepie/otp contains the following files

Loading the files please wait ...