Download the PHP package j42/laravel-firebase without Composer

On this page you can find all versions of the php package j42/laravel-firebase. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package laravel-firebase

laravel-firebase

A Firebase port for Laravel (4.2+)

Configuration

Install via composer. If you have minimum-stability set to stable, you should add a @beta or @dev in order to use the php-jwt library (a dependency managed by firebase for generating JSON web token).

Add the following line to your composer.json and run composer update:

{
  "require": {
    "j42/laravel-firebase": "dev-master"
  }
}

Then add the service providers and facades to config/app.php

'J42\LaravelFirebase\LaravelFirebaseServiceProvider',

...

'Firebase'        => 'J42\LaravelFirebase\LaravelFirebaseFacade'

Access Tokens

Finally, you should configure your firebase connection in the config/database.php array. There are two ways you can define this:

Simple Access Token

Advanced: Request a JWT

This accepts any of the standard options allowed by the firebase security rules and will generate a JSON Web Token for more granular authentication (subject to auth security rules and expirations).

The FirebaseClient instance is loaded into the IoC container as a singleton, containing a Guzzle instance used to interact with Firebase.

Getting Started

Making simple get requests:

Model Syncing

By default this package will keep your Eloquent models in sync with Firebase. That means that whenever eloquent.updated: * is fired, the model will be pushed to Firebase.

This package will automatically look for 'id', '_id', and '$id' variables on the model so that Firebase paths are normalized like so:

To disable this, please ensure 'sync' => false in your database.connections.firebase configuration array.

This works with any package that overwrites the default Eloquent model SO LONG AS it is configured to fire the appropriate saved and updated events. At the moment it is tested with the base Illuminate...Model as well as the Jenssegers MongoDB Eloquent Model

Syncing Models Individually

If you want to add a whitelist of properties to push to firebase automatically whenever a model is updated, you can do so by adding a whitelist of properties to any supported model.

This action happens regardless of the (automatic) sync property in your configuration array. If the $firebase whitelist array is found, then the fields contained will be posted on every update event.

Advanced Use

Create a token manually

All versions of laravel-firebase with dependencies

PHP Build Version
Package Version
Requires php Version >=5.4.0
guzzlehttp/guzzle Version 6.1.*
firebase/php-jwt Version @dev
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package j42/laravel-firebase contains the following files

Loading the files please wait ....