I see on the documentation that you need to set access_type=offline in order to get refresh token. I did set this value in OAuth url and I clearly see it properly set along with other parameters.
original source :Â http://stackoverflow.com/questions/18519185/oauth2-0-cannot-get-refresh-token-even-when-access-type-offline
Is this the first time you are authorizing with the application since you changed the parameter to access_type=offline? You will only retrieve refresh token once when client clicks authorization button to grant you access.
One workaround is to set another parameter approval_prompt=force so that user will always click on authorization button and you can always get refresh token. Otherwise, save refresh token locally so that you don't have to retrieve it again.













