ufxdcollective / instagram-scraper
Scrap Instagram Public Profile
Installs: 12
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Forks: 0
pkg:composer/ufxdcollective/instagram-scraper
Requires
- php: 7.*
- ext-json: *
- guzzlehttp/guzzle: ^6.5
This package is auto-updated.
Last update: 2025-10-18 22:41:45 UTC
README
Usage
use UFXDCollective\InstagramScraper\Scraper;
$cache_dir = __DIR__ . '/cache';
$cache_timeout = 60 * 60 * 24; // 1 day in seconds
$scraper = new Scraper($cache_dir);
// Enable Cache.
$scraper->enableCache($cache_dir, $cache_timeout);
// Get the latest post.
$data = $scraper->latestPost();
// Structure of the $data variable will be:
$data = [
'image' => 'url/of/image/',
'cached_image' => 'cached_filename',
'caption' => 'Image Caption',
];