Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author smashballoon

    (@smashballoon)

    Hey mdriess,

    It’s sounds like that may be the case. There’s a way to get around this but it would require you to edit the source code of the plugin and hardcode multiple Access Tokens. First you’d need to sign up for a couple of new, empty Instagram accounts in order to obtain access tokens from a total of 3-4 accounts and then you can select from those 3-4 tokens at random when making an Instagram API request. This then effectively balances the load between the tokens.

    If you open the plugin’s “instagram-feed.php” file then on line 216 you’ll see the following code:

    $data = array(
        'sb_instagram_at' => $sb_instagram_at
    );

    Before this add an array of your Access Tokens and then select one at random, as shown below:

    $access_token_array = array(
        'ACCESS_TOKEN_1',
        'ACCESS_TOKEN_2',
        'ACCESS_TOKEN_3',
        'ACCESS_TOKEN_4'
    );
    $data = array(
        'sb_instagram_at' => $access_token_array[rand(0, 3)]
    );

    Let me know whether that works as a potential solution for you.

    John

    Thread Starter mdriess

    (@mdriess)

    I don’t think we want to hardcode anything in. Will this be resolved in a future update so that the image can be stored locally or so multiple tokens can be rotated through natively?

    Plugin Author smashballoon

    (@smashballoon)

    Hey mdriess,

    Normally I’d say yes – in fact we recently added caching to our Pro plugin to prevent the chance of exceeding the API request limits – but it sounds like Instagram may be shutting off access to their APIs for all plugins on June 3rd of this year and so I’m not sure that we’ll be updating the plugin again until we find out more information about whether or not the plugin will be able to continue to work past this date.

    John

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Error 429 – Instagram API Rate Limiting’ is closed to new replies.