summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorAaron Parecki <aaron@parecki.com>2014-12-25 18:50:34 -0800
committerAaron Parecki <aaron@parecki.com>2014-12-25 18:50:34 -0800
commit430609b9005bb93ce2c6b21405cea0ede2b17a9d (patch)
tree090b64c2242ba5e8bbe8342a9a9494dcbeb1bf41 /lib
parent2cd148c792a47fea18d760b723d23569ae52d390 (diff)
adds instagram auth
Diffstat (limited to 'lib')
-rw-r--r--lib/helpers.php11
1 files changed, 11 insertions, 0 deletions
diff --git a/lib/helpers.php b/lib/helpers.php
index 010bd91..456fcfd 100644
--- a/lib/helpers.php
+++ b/lib/helpers.php
@@ -195,3 +195,14 @@ function relative_time($date) {
}
return $rel->timeAgo($date);
}
+
+function instagram_client() {
+ return new Andreyco\Instagram\Client(array(
+ 'apiKey' => Config::$instagramClientID,
+ 'apiSecret' => Config::$instagramClientSecret,
+ 'apiCallback' => Config::$base_url . 'auth/instagram/callback',
+ 'scope' => array('basic','likes'),
+ ));
+}
+
+