In Postman you are sending the header “Authorization: Bearer token” and the api is working.
--header 'Authorization: Bearer eyJ0e... g' \
In HTTPAPI you are not sending a Bearer token and the api is failing.
--
Chris Hiebert
Lead Software Developer
Disclaimer: Any views or opinions presented are solely those of the author and do not necessarily represent those of the company.
From: RPG400-L <rpg400-l-bounces@xxxxxxxxxxxxxxxxxx> On Behalf Of (WalzCraft) Jerry Forss
Sent: Wednesday, October 15, 2025 7:24 AM
To: RPG programming on IBM i <rpg400-l@xxxxxxxxxxxxxxxxxx>
Subject: RE: External Re: Auth 2.0
From postman
curl --location '
https://login.microsoftonline.com/ca4f5969-c10f-40d4-8127-e74b691f95de/oauth2/v2.0/token<
https://login.microsoftonline.com/ca4f5969-c10f-40d4-8127-e74b691f95de/oauth2/v2.0/token_> ' \
--header 'Content-Type: application/x-www-form-urlencoded' \
--header 'Authorization: Bearer eyJ0e... g' \
--header 'Cookie: fpc=Ajxh5I5InBtGiamgtxBp0gFoxTAqAgAAAAeSgeAOAAAA; stsservicecookie=estsfd; x-ms-gateway-slice=estsfd' \
--data-urlencode 'client_id=Our Client ID' \
--data-urlencode 'client_secret=Our Secret' \
--data-urlencode 'scope=
https://tffproduction.onmicrosoft.com/code/.default ' \
--data-urlencode 'grant_type=client_credentials' \
--data-urlencode '='
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2025 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact
[javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.