PHPackages                             surfgeo/laravel-aireferral-sdk - 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. surfgeo/laravel-aireferral-sdk

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

surfgeo/laravel-aireferral-sdk
==============================

Track AI bot traffic (ChatGPT, Claude, Perplexity) in Laravel applications

00PHP

Since Jan 6Pushed 4mo agoCompare

[ Source](https://github.com/thebisontech/surfgeo-laravel-aireferral-sdk)[ Packagist](https://packagist.org/packages/surfgeo/laravel-aireferral-sdk)[ RSS](/packages/surfgeo-laravel-aireferral-sdk/feed)WikiDiscussions main Synced 1mo ago

READMEChangelogDependenciesVersions (1)Used By (0)

surfgeo Laravel SDK
===================

[](#surfgeo-laravel-sdk)

Track AI bot traffic in your Laravel applications.

Installation
------------

[](#installation)

```
composer require surfgeo/laravel-aireferral-sdk
```

Quick Start
-----------

[](#quick-start)

### 1. Publish Configuration

[](#1-publish-configuration)

```
php artisan vendor:publish --tag=surfgeo-config
```

Or use the install command:

```
php artisan surfgeo:install
```

### 2. Configure Environment

[](#2-configure-environment)

Add to your `.env` file:

```
SURFGEO_SCRIPT_KEY=sk_your_key_here
SURFGEO_ENABLED=true
```

### 3. Test Connection

[](#3-test-connection)

```
php artisan surfgeo:test
```

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

[](#configuration)

Full configuration options in `config/surfgeo.php`:

```
return [
    'script_key' => env('SURFGEO_SCRIPT_KEY', ''),
    'endpoint' => env('SURFGEO_ENDPOINT', 'https://api.surfgeo.com/api/track'),
    'enabled' => env('SURFGEO_ENABLED', true),
    'timeout' => env('SURFGEO_TIMEOUT', 0.05),
    'debug' => env('SURFGEO_DEBUG', false),
    'async' => env('SURFGEO_ASYNC', false),
    'excluded_paths' => ['/health-check', '/metrics'],
    'excluded_environments' => ['local', 'testing'],
];
```

Usage
-----

[](#usage)

### Automatic Tracking

[](#automatic-tracking)

The middleware automatically tracks all requests. No additional code needed.

### Custom Tracking

[](#custom-tracking)

Use the facade to track custom events:

```
use surfgeo\Laravel\Facades\surfgeo;

surfgeo::track([
    'timestamp' => time(),
    'path' => '/custom-event',
    'method' => 'POST',
    'user_agent' => request()->userAgent(),
]);
```

Features
--------

[](#features)

- ✅ Auto-discovered service provider
- ✅ Laravel HTTP client integration
- ✅ Queue-based tracking (optional)
- ✅ Artisan commands (install, test)
- ✅ Facade for convenience
- ✅ Path and environment exclusions
- ✅ Debug logging

License
-------

[](#license)

MIT

###  Health Score

18

—

LowBetter than 8% of packages

Maintenance52

Moderate activity, may be stable

Popularity0

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity12

Early-stage or recently created project

 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.

### Community

Maintainers

![](https://www.gravatar.com/avatar/245d360475fd81b5e326c4206851ed033aea091268f52905da8ef1116706da70?d=identicon)[bisontech](/maintainers/bisontech)

---

Top Contributors

[![jainamshahxperts](https://avatars.githubusercontent.com/u/206028155?v=4)](https://github.com/jainamshahxperts "jainamshahxperts (1 commits)")[![thebisontech](https://avatars.githubusercontent.com/u/231234924?v=4)](https://github.com/thebisontech "thebisontech (1 commits)")

### Embed Badge

![Health badge](/badges/surfgeo-laravel-aireferral-sdk/health.svg)

```
[![Health](https://phpackages.com/badges/surfgeo-laravel-aireferral-sdk/health.svg)](https://phpackages.com/packages/surfgeo-laravel-aireferral-sdk)
```

PHPackages © 2026

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