Reputation: 40
Im using mgp25 Instagram-Api library in my projects
When i want to upload a photo i get an error: Invalid request options
My image is 629 x 629
pixels and jpg format.
my code:
if($shouldProcess){
$photo = new \InstagramAPI\Media\Photo\InstagramPhoto($target_file);
$uploadResult = $insta->timeline->uploadPhoto($photo->getFile(), ['caption' => $caption]);
}else{
$uploadResult = $insta->timeline->uploadPhoto($target_file, ['caption' => $caption]);
}
Thanks!
Upvotes: 0
Views: 1169
Reputation: 1442
The mgp25 Instagram API is not available anymore because of dmca takedown. See this -> https://github.com/mgp25/Instagram-API
Upvotes: 1