token load and save + auto token refresh #8

wants to merge 16 commits into


None yet
3 participants

nikopol commented Apr 5, 2012

more than words, here's the way i use it :

nikopol and others added some commits Dec 21, 2011

Added parameter to AccessToken to control automatic refresh function.
Call $token->auto_refresh(1) on a token to enable autorefreshing.

Done this way as array or params given at create time are all passed
into the request sent to the server.
Merge pull request #1 from carlvincent/refresh
make auto refresh behaviour optional
Made site_url a property of the AccessToken
Working with the Salesforce API, you get the base url for API requests
back with your access token - and it may change depending on the
account the user logs in with. Since this needs to be saved and reloaded
with the access token, I've added that property and a new site_url
method that uses the property if set, or delegates to the Client
object (the original behaviour) if not.

I've also added the response content to the die message in request()
as this is useful for debugging. It may be necessary to make this
behaviour optional to shield the end user from the data, but the
result of a die shouldn't really make it to the end user anyway.
Merge pull request #3 from carlvincent/refresh
Moved Site-url attribute to AccessToken object

markov2 commented Jan 9, 2013

I have taken over Net::OAuth2 and merged in three large patch-sets (all very different) plus my own major rework of the module. Major changes. You may have some more ideas for improvements. Please send those via or directly to me at

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment