The LogMeIn API for GoToWebinar says to use this code to refresh an Access Token after it expire:
curl -X POST "https://api.getgo.com/oauth/v2/token" \
-H "Authorization: Basic {Base64 Encoded consumerKey and consumerSecret}" \
-H "Accept:application/json" \
-H "Content-Type: application/x-www-form-urlencoded" \
-d "grant_type=refresh_token&refresh_token={refresh_token}"
Tried recreating it in ColdFusion like this:
<cfhttp url="https://api.getgo.com/oauth/v2/token" method="post" result="httpResp" timeout="60">
<cfhttpparam type="header" name="Accept" value="application/json" />
<cfhttpparam type="header" name="Authorization" value="Basic ...abc123..." />
<cfhttpparam type="header" name="Content-Type" value="application/x-www-form-urlencoded" />
<cfhttpparam type="body" encoded="false" value="grant_type=refresh_token&refresh_token=#refreshToken#" />
</cfhttp>
The error we are getting is "error":"invalid_grant".
Before I delve further, is the ColdFusion translation correct (assuming the refresh_token and Authorization encoded keys are correct)?