0

I'm trying to query my Portal's REST API via my-portal-hostname/webadapter/sharing/rest in POSTMAN. I am able to generate a token via /sharing/rest/oauth2/token however I am not able to then use the token to call other endpoints. After sending a POST request in postman I receive HTML code displaying the portal directory login page. I am trying to call the endpoint to unshare an item from a group.

For the POST request I am sending the token as a key in the form-data body.

Any ideas what I am doing wrong?

Katah
1,0707 silver badges12 bronze badges
asked Mar 21, 2022 at 16:01
3
  • You should probably follow a trace of the network requests when it works before trying to go commando. Commented Mar 22, 2022 at 3:27
  • I guess you do not provide to much information about what are you sending and what is the real answer. Anyway, you can find in this GitHub repo some Postman collections for the ArcGIS-REST-API. I hope it helps! Commented Mar 22, 2022 at 9:41
  • Thanks for the replies, the answer was missing a query parameter 'f' to return response as json rather than the default HTML. Commented Mar 23, 2022 at 11:40

1 Answer 1

0

The answer was missing a query parameter f to return response as json rather than the default HTML.

Kadir Şahbaz
78.6k57 gold badges260 silver badges407 bronze badges
answered Mar 23, 2022 at 11:41

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.