Skip to content
This repository has been archived by the owner on Jan 20, 2020. It is now read-only.

Commit

Permalink
Added support for method types to generic requests
Browse files Browse the repository at this point in the history
  • Loading branch information
aseba committed Dec 8, 2016
1 parent baeb92a commit 61514eb
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions src/Instagram.php
Original file line number Diff line number Diff line change
Expand Up @@ -101,4 +101,20 @@ public function debug($debug = true)
{
$this->debug = (bool) $debug;
}

public function comment($media_id, $text) {
return $this->generic(
sprintf('media/%s/comments', $media_id),
['text' => $text],
'POST'
);
}

public function delete_comment($media_id, $comment_id) {
return $this->generic(
sprintf('media/%s/comments/%s', $media_id, $comment_id),
[],
'DELETE'
);
}
}

0 comments on commit 61514eb

Please sign in to comment.