- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I'm following the OAuth2 Authorization Code Flow on CC API v3 to get my access and refresh token. However on step 4 I only get the access token. The refresh token is missing. Why?. Here's the response:
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The solution: I re-read the API Server Flow Guide and saw something mentioned that i did not include in my initial attempt: -- you MUST add "offline_access" to the scope to get the refresh token: Here it the paragraph from the doc:
scope — The type of data in Constant Contact that the user is granting your application permission to use. The offline_access scope is required to get a refresh token.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I, too, have the same issue as TACmarketing. It makes not difference if the application is configured as "rotating refresh tokens" or "long lived refresh tokens". Below is a screen shot of the JSON representation of the POST response
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The solution: I re-read the API Server Flow Guide and saw something mentioned that i did not include in my initial attempt: -- you MUST add "offline_access" to the scope to get the refresh token: Here it the paragraph from the doc:
scope — The type of data in Constant Contact that the user is granting your application permission to use. The offline_access scope is required to get a refresh token.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thank you JosePhineo. I missed it too.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello TACmarketing,
Thank you for reaching out to Constant Contact API Developer Support. My team is here to assist outside software developers with questions about building into Constant Contact's API.
It looks like @josephineo already came up with the solution in an above comment but based on your response, it looks like the only scope included in your authentication request was the
“contact_data” scope. In order to obtain a refresh token the “offline_access” scope must also be included in the request. Below I am including the overview documentation for our available OAuth 2.0 flows.
OAuth 2.0 Overview:
https://developer.constantcontact.com/api_guide/auth_overview.html
Please have a look and let us know if you have any other questions!
Regards,
John B.
API Support Specialist
Did I answer your question? If so, please mark my post as an "Accepted Solution" by clicking the Accept as Solution button in the bottom right hand corner of this post.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content