companionstudio / instagram-token-agent

A service to keep your Instagram Basic Display API token fresh.
MIT License
133 stars 70 forks source link

Scheduling a refresh of the token with Temporize scheduler fails when checking signature #21

Closed benjamin-hull closed 4 years ago

benjamin-hull commented 4 years ago

Describe the bug

When Temporize fires the webhook to inform the agent that the token is ready to be refreshed, the check for a valid signature fails because the code doesn't have access to the app config.

This is the source of issue #10 .

 NoMethodError - undefined method `webhook_secret' for nil:NilClass:
/instagram-token-agent/lib/instagram_token_agent/client.rb:51:in `signature'