Constant Contact Logo
Community Home
Resources
  • "Ask a Trainer" Sessions
  • Getting Started
  • Help Center
  • News and Announcements
  • Professional Services
  • Support Forum
Events & Webinars
  • On-Demand Webinars
  • Upcoming Webinars
Learn
  • Be A Marketer
  • Campaign Feedback
  • Community Blog
  • Community Coaches
  • Email Design Tips
  • Marketing Strategies
Groups
  • Nonprofit
  • Real Estate
  • Retail & Ecommerce
  • Small Business Voices
  • The ANZ Hub
Product Ideas
  • Sign up free
  • Log in
  • Constant Contact Community
  • >
  • About MKTG_Team

About MKTG_Team

MKTG_Team
MKTG_Team
Rookie
since ‎09-26-2012
‎11-01-2022
1
Post
0
Kudos
0
Solutions
Badges
First Topic
View All
Latest Contributions by MKTG_Team
  • Topics MKTG_Team has Participated In
  • Latest Contributions by MKTG_Team

Programmatically access contact_data API using Pyt...

by MKTG_Team in API Developer Support
‎03-23-2022 04:12 PM
‎03-23-2022 04:12 PM
Am trying to access the below API to get access token but am getting error mentioned below the code snippet: from requests.auth import HTTPBasicAuth from oauthlib.oauth2 import BackendApplicationClient from requests_oauthlib import OAuth2Session auth_token_url = "https://authz.constantcontact.com/oauth2/default/v1/token" client = BackendApplicationClient(client_id=client_id) oauth = OAuth2Session(client=client) basic_auth = HTTPBasicAuth(client_id, client_secret) token = oauth.fetch_token(token_url=auth_token_url, auth=basic_auth) What am i missing here? I need to get access token to make api call to below url:   https://api.cc.email/v3/contacts?include_count=true   Is there a way to generate access token that doesn't expire as am trying to build a data pipeline using this API call.    Error: UnauthorizedClientError: (unauthorized_client) The client is not authorized to use the provided grant type. Configured grant types: [authorization_code, implicit, refresh_token]. ... View more
  • Tags:
  • oAuth2
  • python
  • requests
  • token
Latest Tags
  • oAuth2
  • python
  • requests
  • token
View All
  • © Constant Contact, Inc. 1996-2025
  • Terms
  • Community Terms
  • Community Guidelines
  • Privacy
  • Vulnerability Disclosure