flint/antenna-bundle
Flint Antenna Bundle is a Laravel/PHP package that provides a simple integration layer for Antenna, making installation and configuration straightforward so you can add Antenna functionality to your application with minimal boilerplate.
php artisan vendor:publish --provider="..."). If you already have the package installed, 1.1.0 is an additive minor release—update with composer require vendor/package:^1.1.UsernamePasswordAuthenticator. That class is the main entry point for username/password authentication and, as of 1.1.0, accepts a time_to_live option.use Vendor\Package\Auth\UsernamePasswordAuthenticator;
$authenticator = app(UsernamePasswordAuthenticator::class);
$token = $authenticator->attempt([
'username' => $request->username,
'password' => $request->password,
], [
'time_to_live' => now()->addHours(2), // new in 1.1.0
]);
If the package supports config-driven defaults, set a sensible fallback in config/<package>.php:
'time_to_live' => env('AUTH_TOKEN_TTL', 60 * 60 * 24),
time_to_live option for “remember me” flows—short TTL for normal logins, longer TTL when the user opts in. Pass the option at call time instead of hard-coding it.config/auth.php and use Auth::guard('api')->attempt(...). If not, call the authenticator directly from your login endpoint.UsernamePasswordAuthenticator in the container, or use actingAs when a guard is available. Add a test that asserts the time_to_live option is passed through, since expiry bugs are easy to miss.expires_in or expires_at in your login response using the same TTL you passed to the authenticator. Clients can then refresh proactively instead of reacting to 401s.time_to_live expects seconds, a DateTimeInterface, or a DateInterval. The release note does not specify; check the class signature or package tests. Mixing units is the fastest way to issue tokens that expire immediately or never.time_to_live, the package likely falls back to a configured default. Audit that default before and after upgrading—1.1.0 adds the option but may not change existing defaults.time_to_live to config, run php artisan config:clear locally and config:cache in production. Stale config is a common reason the new option appears ignored.expires_at, not the client clock. If you test with Carbon::setTestNow(), make sure the authenticator uses the same clock.expires_at column; others rely on cache TTL. Check both.attempt, and check the package tests for the expected time_to_live type. If tokens still expire at the old time, confirm you are not reusing a cached authenticator instance in Octane or a queue worker.^1.1 and run your auth tests after upgrading—especially if you call the authenticator with positional arguments or custom subclasses.How can I help you explore Laravel packages today?