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-12-21 20:12:56 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();