Jump to content

EMiliaEmilia Cheladze

Members
  • Posts

    1
  • Joined

  • Last visited

Everything posted by EMiliaEmilia Cheladze

  1. Hi Mark, I have the same issue as Emon described above. Please find my POST request below. Could you please advise? Many thanks in advance, Yun url_accesstoken = "https://oauth.accounting.sage.com/token"authorization_code= '83xxxxxxxxxca'auth_payload = {'client_id': client_id,'client_secret': client_secret,'code' : authorization_code,'grant_type' : 'authorization_code','redirect_uri': "https://www.more-fire.com/callback"}headers = {'Content-Type' : 'application/x-www-form-urlencoded'}access_token = requests.request("POST", url_accesstoken, headers=headers, data=auth_payload) The entire http request looks like this: print(access_token.request.url) https://oauth.accounting.sage.com/token print(access_token.request.headers) {'User-Agent': 'python-requests/2.25.1', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive', 'Content-Type': 'application/x-www-form-urlencoded', 'Content-Length': '254'} print(access_token.request.body) client_id=dfxxxxxxxc&client_secret=xxxxxxx&code=83xxxxxxx&grant_type=authorization_code&redirect_uri=https%3A%2F%2Fwww.more-fire.com%2Fcallback
×
×
  • Create New...