gonzalo123 / pushsilex
pushsilext
dev-master / 1.0.x-dev
2015-02-28 19:32 UTC
Requires
- silex/silex: 1.3.x-dev
This package is not auto-updated.
Last update: 2024-11-09 19:35:47 UTC
README
Pushbullet integration with Silex
Usage
use Silex\Application; use PushSilex\Silex\Provider\PushbulletServiceProvider; $app = new Application(['debug' => true]); $myToken = include(__DIR__ . '/../conf/token.php'); $app->register(new PushbulletServiceProvider($myToken)); $app->get("/", function () { return "Usage: GET /note/{title}/{body}"; }); $app->get("/note/{title}/{body}", function (Application $app, $title, $body) { return $app->json($app['pushbullet.note']($title, $body)); }); $app->run();