PHPackages                             sysborg/check-my-domain - 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. [Utility &amp; Helpers](/categories/utility)
4. /
5. sysborg/check-my-domain

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

sysborg/check-my-domain
=======================

A lightweight Laravel package for domain ownership verification using DNS TXT records.

0.0.3(9mo ago)0395↓50%MITPHPPHP ^8.0

Since Jul 23Pushed 9mo agoCompare

[ Source](https://github.com/sysborg/CheckMyDomain)[ Packagist](https://packagist.org/packages/sysborg/check-my-domain)[ RSS](/packages/sysborg-check-my-domain/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (3)Dependencies (3)Versions (4)Used By (0)

✅ CheckMyDomain
===============

[](#-checkmydomain)

A lightweight and developer-friendly Laravel package for verifying domain ownership using **DNS TXT records**.

[![License](https://camo.githubusercontent.com/7013272bd27ece47364536a221edb554cd69683b68a46fc0ee96881174c4214c/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6c6963656e73652d4d49542d626c75652e737667)](https://camo.githubusercontent.com/7013272bd27ece47364536a221edb554cd69683b68a46fc0ee96881174c4214c/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6c6963656e73652d4d49542d626c75652e737667)[![Laravel](https://camo.githubusercontent.com/3d32ce45ddd8e0261ef71c531534bfb7dccc7d894ee6758894f6b36b78f21143/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6c61726176656c2d3825323025374325323039253230253743253230313025323025374325323031312d627269676874677265656e)](https://camo.githubusercontent.com/3d32ce45ddd8e0261ef71c531534bfb7dccc7d894ee6758894f6b36b78f21143/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6c61726176656c2d3825323025374325323039253230253743253230313025323025374325323031312d627269676874677265656e)

---

🚀 Features
----------

[](#-features)

- 🔐 Verifies domain ownership via DNS TXT records.
- ⚙️ Easily configurable and customizable.
- 🔗 Prefix-based hashing for safe and unique TXT records.
- ⚡ Simple to integrate into any Laravel project.

---

📦 Installation
--------------

[](#-installation)

```
composer require sysborg/check-my-domain
```

---

🛠️ Configuration
----------------

[](#️-configuration)

Optionally publish the configuration file:

```
php artisan vendor:publish --tag=check-my-domain-config
```

This will publish the file to: `config/checkMyDomain.php`

### Example config (`config/checkMyDomain.php`)

[](#example-config-configcheckmydomainphp)

```
return [

    'prefix' => 'sbv',

    'settings' => [
        'use-domain' => true,
    ],
];
```

KeyDescription`prefix`Prefix used in the TXT record name/value (e.g., `sbv=...`)`use-domain`If `true`, includes the domain name in the generated hash---

🧠 Usage
-------

[](#-usage)

### Injecting the Service

[](#injecting-the-service)

```
use Facades\Sysborg\CheckMyDomain\Lib\Domain;

$domainService = Domain::methodName(...parameters);
```

### Generating a TXT Record

[](#generating-a-txt-record)

```
$record = Domain::generateTxtRecord('example.com', 'user-123');

// Output: sbv=4f8a3bd9eabf3c22bb9a5e2dd5c03f4c8ae6d2ef9f709137b20a2fd4e9d1
```

### Validating Against DNS

[](#validating-against-dns)

```
$isVerified = Domain::compareTxtRecord('example.com', $record);

if ($isVerified) {
    echo '✅ Domain verified successfully!';
} else {
    echo '❌ Domain verification failed.';
}
```

---

🧪 Testing
---------

[](#-testing)

```
composer test
```

Or use PHPUnit directly if configured:

```
./vendor/bin/phpunit
```

---

📁 Directory Structure
---------------------

[](#-directory-structure)

```
src/
├── config/
│   └── checkMyDomain.php
├── Exceptions/
│   ├── InvalidDomainException.php
│   └── InvalidPrefixException.php
├── Lib/
│   └── Domain.php
├── Providers/
│   └── CheckMyDomainProvider.php

```

---

📚 How It Works
--------------

[](#-how-it-works)

1. The package generates a unique hash based on your prefix, user ID, domain, and timestamp.
2. The user adds the TXT record to their DNS zone (e.g. `sbv=abcdef123456...`).
3. You use `compareTxtRecord()` to query the domain and validate if the correct TXT record is present.

This makes it easy to verify domain ownership for:

- User-generated domains
- SaaS onboarding
- API clients or webhook callbacks

---

🧩 Integration Ideas
-------------------

[](#-integration-ideas)

- 🔗 Connect to onboarding flows (verify user domains).
- 🛡️ Add protection to webhook registration or integrations.
- ⚙️ Automate DNS verification with APIs like Cloudflare.

---

👥 Credits
---------

[](#-credits)

Maintained by [Sysborg](https://sysborg.com.br)Created by [Anderson Arruda](mailto:andmarruda@gmail.com)

---

📄 License
---------

[](#-license)

MIT License. See [LICENSE](LICENSE) file for details.

###  Health Score

28

—

LowBetter than 54% of packages

Maintenance55

Moderate activity, may be stable

Popularity12

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity33

Early-stage or recently created project

 Bus Factor1

Top contributor holds 75% 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

Every ~0 days

Total

3

Last Release

296d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/3a6c206a9669758146bf810648f37de32eb5cd5c07b8faa66c987b84fe3da696?d=identicon)[sysborg](/maintainers/sysborg)

---

Top Contributors

[![andmarruda](https://avatars.githubusercontent.com/u/29872593?v=4)](https://github.com/andmarruda "andmarruda (3 commits)")[![sysborg](https://avatars.githubusercontent.com/u/59512284?v=4)](https://github.com/sysborg "sysborg (1 commits)")

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/sysborg-check-my-domain/health.svg)

```
[![Health](https://phpackages.com/badges/sysborg-check-my-domain/health.svg)](https://phpackages.com/packages/sysborg-check-my-domain)
```

###  Alternatives

[barryvdh/laravel-ide-helper

Laravel IDE Helper, generates correct PHPDocs for all Facade classes, to improve auto-completion.

14.9k123.0M687](/packages/barryvdh-laravel-ide-helper)[orchestra/canvas

Code Generators for Laravel Applications and Packages

21017.2M158](/packages/orchestra-canvas)[illuminate/pipeline

The Illuminate Pipeline package.

9446.6M213](/packages/illuminate-pipeline)[illuminate/pagination

The Illuminate Pagination package.

10532.5M862](/packages/illuminate-pagination)[spatie/laravel-pjax

A pjax middleware for Laravel 5

513371.8k11](/packages/spatie-laravel-pjax)[spatie/laravel-mix-preload

Add preload and prefetch links based your Mix manifest

169176.0k2](/packages/spatie-laravel-mix-preload)

PHPackages © 2026

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