Closed johnstontrav closed 10 years ago
John,
Please note I have revised the directory & autoloader structure. You now have a few options for how to do this... you can reference the full namespace & create a token using:
new J42\LaravelFirebase\Token('secret')
Alternatively you can define your secret in the database connection configuration as seen here: https://github.com/j42/laravel-firebase#advanced-request-a-jwt and use the convenience facade:
FirebaseToken::create([], []);
If you have some free time, would you mind writing some solid Markdown documentation for this? I don't need to create custom access tokens in the project I built this for, so it's not something I will be testing extensively myself--if you want to help ensure this functionality performs well in the wild & is production ready, that would be a huge help.
Hi,
I can't seem to create a token manually.
Class 'J42\LaravelFirebase\FirebaseToken' not found
Route::get('/token',function() { $FirebaseTokenGenerator = new J42\LaravelFirebase\FirebaseToken('secret'); $token = $FirebaseTokenGenerator->create([], []); return $token; });