PHPackages                             genxbe/kirby3-instagram - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Image &amp; Media](/categories/media)
4. /
5. genxbe/kirby3-instagram

AbandonedArchivedKirby-plugin[Image &amp; Media](/categories/media)

genxbe/kirby3-instagram
=======================

Kirby3 plugin to fetch instagram photos from your profile.

1.0.9(3y ago)494911[3 issues](https://github.com/genxbe/kirby3-instagram/issues)[1 PRs](https://github.com/genxbe/kirby3-instagram/pulls)MITPHP

Since Apr 7Pushed 1y ago1 watchersCompare

[ Source](https://github.com/genxbe/kirby3-instagram)[ Packagist](https://packagist.org/packages/genxbe/kirby3-instagram)[ RSS](/packages/genxbe-kirby3-instagram/feed)WikiDiscussions master Synced 3d ago

READMEChangelog (10)Dependencies (1)Versions (11)Used By (0)

IMPORTANT NOTICE
================

[](#important-notice)

This plugin won't work anymore starting from 04/12/2024. Because of the changes on the basic display API. (more info: ) Keep an eye on  for a new Kirby instagram plugin.

Kirby3 Instagram feed
=====================

[](#kirby3-instagram-feed)

Fetch instagram photos without the need for app aproval. This plugin will download the photos and/or video thumbnails to local storage. All media will be stored in a json file.

Only the 20 latest photo's will be stored.

This plugin uses the **basic user access token** which you can generate for all testusers of your instagram app. ()

Options
-------

[](#options)

Required are the **`client_id`** (Instagram App ID) and **`client_secret`** (Instagram App Secret). All other options are optional.

```
# site/config/config.php
return [
    'genxbe.instagram' => [
        'client_id' => '',
        'client_secret' => '',
        'assetFolder' => 'instagram',
        'mediaFolder' => 'media',
        'db' => 'instagram.json',
    ],
];
```

Usage
-----

[](#usage)

- find a place to add the `instagramLink` blueprint
- Add your client\_id and client\_secret to your config file, all other options are optional.
- Don't forget to add your website redirect uri to the **Valid OAuth Redirect URIs**

    - You can add multiple website and thus use 1 app for all of your websites
    - Format of the url you need to add is `https://yoursite.com/axi/instagram`
- Add the instagram account you want to use to the test users and ask them to accept the invite (instructions below)
- Ask your user to enable the instagram link on the website, when this process is completed a first time fetch will already be done.
- After the user has linked his Instagram you can start fetching via `php site/plugins/kirby3-instagram/fetch.php`
- If you want to have regular updates you need to schedule this command via the cron. I would advise to do this every 30 or 60 minutes so you don't overload your API rate limit. (More info on )

### Examples

[](#examples)

#### Add linkInstagram to blueprint

[](#add-linkinstagram-to-blueprint)

```
title: Site
preset: pages
unlisted: true

fields:
  linkInstagram: linkInstagram
```

#### After the first fetch you can start parsing the feed

[](#after-the-first-fetch-you-can-start-parsing-the-feed)

You can check for a count of the feed to hide the block when no media is available yet. Since we work with collections you can also use fieldMethods like `limit`, `filterBy`, etc...

```
