PHPackages                             sakshsky/saksh-auth - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Authentication &amp; Authorization](/categories/authentication)
4. /
5. sakshsky/saksh-auth

ActiveLibrary[Authentication &amp; Authorization](/categories/authentication)

sakshsky/saksh-auth
===================

A lightweight, passwordless OTP-based authentication system for Laravel applications.

1.0.0(11mo ago)00MITPHPPHP ^8.1

Since May 18Pushed 11mo ago1 watchersCompare

[ Source](https://github.com/sakshsky/saksh-auth)[ Packagist](https://packagist.org/packages/sakshsky/saksh-auth)[ RSS](/packages/sakshsky-saksh-auth/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (1)Dependencies (3)Versions (2)Used By (0)

Below is the full content of the `README.md` file for the `sakshsky/saksh-auth` Laravel package, as requested, provided directly in the chat.

```
# Saksh Auth - OTP-based Laravel Authentication

A Laravel package for passwordless authentication using one-time passwords (OTPs) sent via email.

## Installation

1. Install the package via Composer:
```bash
composer require sakshsky/saksh-auth
```

2. Publish the migrations and configuration:

```
php artisan vendor:publish --tag=saksh-auth-migrations
php artisan vendor:publish --tag=saksh-auth-config
```

3. Run the migrations:

```
php artisan migrate
```

4. Ensure Laravel Sanctum is installed and configured:

```
php artisan vendor:publish --provider="Laravel\Sanctum\SanctumServiceProvider"
php artisan migrate
```

Configuration
-------------

[](#configuration)

The package configuration is located at `config/saksh-auth.php`. You can customize:

- OTP expiry time
- Email subject
- Email template

You can also set these values in your `.env` file:

```
SAKSH_AUTH_OTP_EXPIRY=10
SAKSH_AUTH_EMAIL_SUBJECT="Your OTP Code"
SAKSH_AUTH_EMAIL_TEMPLATE="Your OTP is: {otp}\n\nThis code will expire at {expires_at}"
```

API Endpoints
-------------

[](#api-endpoints)

- `POST /otp-auth/request-otp`

    - Parameters: `email`, `name` (optional)
    - Returns: Success message and OTP expiration time
- `POST /otp-auth/verify-otp`

    - Parameters: `email`, `otp`
    - Returns: Access token, token type, and user data

Events
------

[](#events)

- `Sakshsky\SakshAuth\Events\OtpGenerated`: Fired when an OTP is generated
- `Sakshsky\SakshAuth\Events\OtpVerified`: Fired when an OTP is verified

Requirements
------------

[](#requirements)

- PHP &gt;= 8.0
- Laravel &gt;= 10.0
- Laravel Sanctum

License
-------

[](#license)

MIT License

```

This `README.md` provides clear instructions for installation, configuration, and usage, along with details about API endpoints, events, requirements, and licensing. If you need modifications (e.g., adding a Packagist badge, contributing guidelines, or a changelog), let me know!

```

###  Health Score

27

—

LowBetter than 49% of packages

Maintenance50

Moderate activity, may be stable

Popularity0

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity45

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 50% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

359d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/d59b51b89c678e3903c93b00ec8bea8d90dbab11391ce844b1c3cb476bc3f10e?d=identicon)[sakshsky](/maintainers/sakshsky)

---

Top Contributors

[![sakshsky](https://avatars.githubusercontent.com/u/210330406?v=4)](https://github.com/sakshsky "sakshsky (1 commits)")[![sakshstore](https://avatars.githubusercontent.com/u/44046755?v=4)](https://github.com/sakshstore "sakshstore (1 commits)")

---

Tags

laravelotpAuthenticationPasswordless

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/sakshsky-saksh-auth/health.svg)

```
[![Health](https://phpackages.com/badges/sakshsky-saksh-auth/health.svg)](https://phpackages.com/packages/sakshsky-saksh-auth)
```

###  Alternatives

[salehhashemi/laravel-otp-manager

Laravel OTP manager

18713.2k](/packages/salehhashemi-laravel-otp-manager)[lakm/nopass

Provides passwordless authentication for your laravel projects.

2213.6k2](/packages/lakm-nopass)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
