Ken Whipday
-
Posts
2 -
Joined
-
Last visited
Content Type
Profiles
Forums
Events
Articles
Downloads
Gallery
Posts posted by Ken Whipday
-
-
Hi Support,
I've hit a problem I'm hoping you can help with. After the user authorises our app in Sage, we get the accessToken and call the businesses API, but the API returns a 403 error.
The request is
request: { debugId: 2, uri: 'https://oauth.accounting.sage.com/businesses', method: 'GET', headers: { 'Content-Type': 'application/json', Authorization: 'Bearer eyJhbG...', host: 'oauth.accounting.sage.com', accept: 'application/json' } }
And the error response is shown below, the body.message property contains the text 'not a valid key=value pair (missing equal sign) in Authorisation header'.
{ debugId: 2, headers: { 'content-type': 'application/json', 'content-length': '2619', connection: 'close', date: 'Wed, 17 Aug 2022 07:58:38 GMT', 'x-amzn-requestid': 'e9ed1f93-dfa7-4537-8c66-c9d6980c7bee', 'x-amzn-errortype': 'IncompleteSignatureException', 'x-amz-apigw-id': 'W_3jRH5ijoEF1CQ=', 'x-cache': 'Error from cloudfront', via: '1.1 1a6cd18714da9809fa8cb07ad66fd4f6.cloudfront.net (CloudFront)', 'x-amz-cf-pop': 'LHR50-P3', 'x-amz-cf-id': 'Tq4pu8aT2deZ-thjnEABbjVBrpNk01nMmpdsyyAY1lRZ5dB4YfpCTQ==' }, statusCode: 403, body: { message: "'ey....2o' not a valid key=value pair (missing equal-sign) in Authorization header: 'Bearer ey....2o'." } }
I've tried adding an equals sign, using different http libraries, but keep getting this error. Using the same token in Postman gives a token expired message, which is what I was expecting from this API call because I'm re-using the token (I get the same issue with a brand new token too).
I can't find any information on this error message in the forum or google search, can you provide any guidance on what might be causing the error?
thanks, Ken
get message 'not a valid key=value pair (missing equal-sign) in Authorization header'
in Support
Posted
Hi Mark,
Thanks, that worked a treat !
cheers, Ken.