angular-instagram-api-factory is an angularjs module with a instagram api factory.
Author: Jonathan Hornung (JohnnyTheTank)
Usage
- Install via either bower, npm or downloaded files:
bower install --save angular-instagram-api-factory
npm install --save angular-instagram-api-factory
- download angular-instagram-api-factory.zip
- Add
jtt_instagram
to your application's module dependencies. - Include dependencies in your HTML.
- When using bower:
<script src="bower_components/angular-instagram-api-factory/src/angular-instagram-api-factory.min.js"></script>
- When using npm:
<script src="node_modules/angular-instagram-api-factory/src/angular-instagram-api-factory.min.js"></script>
- when using downloaded files
<script src="angular-instagram-api-factory.min.js"></script>
- Use the factory
instagramFactory
factory methods
getMedia
instagramFactory.getMediaFromUserById({
userId: "<USER_ID>",
count: "<COUNT>",
min_id: "<MIN_ID>",
max_id: "<MAX_ID>",
min_timestamp: "<MIN_TIMESTAMP>",
max_timestamp: "<MAX_TIMESTAMP>",
access_token: "<YOUR_ACCESS_TOKEN>",
}).then(function (_data) {
}).catch(function (_data) {
});
instagramFactory.getMediaByTag({
tag: "<TAG>",
count: "<COUNT>",
min_tag_id: "<MIN_TAG_ID>",
max_tag_id: "<MAX_TAG_ID>",
min_timestamp: "<MIN_TIMESTAMP>",
max_timestamp: "<MAX_TIMESTAMP>",
access_token: "<YOUR_ACCESS_TOKEN>",
}).then(function (_data) {
}).catch(function (_data) {
});
instagramFactory.getMediaFromLocationById({
locationId: "<LOCATION_ID>",
count: "<COUNT>",
min_id: "<MIN_ID>",
max_id: "<MAX_ID>",
min_timestamp: "<MIN_TIMESTAMP>",
max_timestamp: "<MAX_TIMESTAMP>",
access_token: "<YOUR_ACCESS_TOKEN>",
}).then(function (_data) {
}).catch(function (_data) {
});
instagramFactory.getMediaByCoordinates({
lat: "<LAT>",
lng: "<LNG>",
distance: "<DISTANCE>",
count: "<COUNT>",
min_timestamp: "<MIN_TIMESTAMP>",
max_timestamp: "<MAX_TIMESTAMP>",
access_token: "<YOUR_ACCESS_TOKEN>",
}).then(function (_data) {
}).catch(function (_data) {
});
getUser
instagramFactory.getUserById({
userId: "<USER_ID>",
access_token: "<YOUR_ACCESS_TOKEN>",
}).then(function (_data) {
}).catch(function (_data) {
});
Instagram JSONP API
License
MIT