How to get Access Token and Refresh Token for gmail in iphone
<pre><code>I am developing gmail chat application,for authentication i am using the fallowing url

https://accounts.google.com/o/oauth2/auth?
scope=https%3A%2F%2Fwww.googleapis.com%2Fauth%2Fuserinfo.email+https%3A%2F%2Fwww.googleapis.com%2Fauth%2Fuserinfo.profile&amp;
redirect_uri=urn:ietf:wg:oauth:2.0:oob&amp;
response_type=code&amp;
client_id=812741506391-h38jh0j4fv0ce1krdkiq0hfvt6n5amrf.apps.googleusercontent.com 

it returns response code.


POST /o/oauth2/token HTTP/1.1
Host: accounts.google.com
Content-Type: application/x-www-form-urlencoded

code=4/v6xr77ewYqhvHSyW6UJ1w7jKwAzu&amp;
client_id=8819981768.apps.googleusercontent.com&amp;
client_secret={client_secret}&amp;
redirect_uri=https://oauth2-login-demo.appspot.com/code&amp;
grant_type=authorization_code


i am tryting to post this using NSMutableURLRequest but shows Method not allowed.can any one help me.thanks inadvance
</code></pre>
