PHP code example of rbadillap / twitterstreaming-laravel
1. Go to this page and download the library: Download rbadillap/twitterstreaming-laravel library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
rbadillap / twitterstreaming-laravel example snippets
'providers' => [
// other service providers..
TwitterStreaming\Laravel\TwitterStreamingServiceProvider::class
],
// Instead of
(new Tracker)
->endpoint(Endpoints\PublicEndpoint::class, 'sample')
// You can call in Laravel
TwitterStreaming::publicSample()
// and continue with the rest of the code
publicFilter()
// alias of endpoint(Endpoints\PublicEndpoint::class, 'filter')
publicSample()
// alias of endpoint(Endpoints\PublicEndpoint::class, 'sample')
user()
// alias of endpoint(Endpoints\UserEndpoint::class)
// this is not necessary
->addExtension(Extensions\Filters::class)
// TwitterStreamingPHP detects automatically if the module are thods to filter tweets
->withoutRTs()
->withoutReplies()
->onlyFromAndroid();
})