cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Helper I
Helper I

Custom connector for Sharepoint REST API

As mentioned in the azure document for app registration, I was able to create connector for sharepoint rest api.

 

I tested the custom connector in powerapps for the rest api URL /sites/{sitename}/_api/web/getuserbyid({userid})/groups and I got all the sharepoint groups associated with the user and the response in JSON format.

 

When I tried to use the connector in powerapps and after passing all the required parameter.(sitename and userid). The output that is returned is always in xml and powerapps is not able to parse xml.

I did mention in the swagger file to produce and consume json. In the network console I could see they are using proxy url as shown below and response always shows xml 

 

Network consoleNetwork consoleSwagger descriptionSwagger description

 

https://msmanaged-na.azure-apim.net/apim/spapi.5f79410ce145b.5f7edfa0cdba0c396b/399ed19282a847568e50...

 

How do I get the JSON format as a response ?  This solution would help  me to maintain user roles in sharepoint site 

3 REPLIES 3
Highlighted
Community Support
Community Support

Re: Custom connector for Sharepoint REST API

Could you please share the documentation for how to register App for SharePoint REST API?

 

Are you using Azure functions?

 

Regards,

Michael

Community Support Team _ Michael Shao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Highlighted
Helper I
Helper I

Re: Custom connector for Sharepoint REST API

I used the below blog article link for registering application for sharepoint rest api. Please refer the below link 

 

https://powerapps.microsoft.com/en-us/blog/implementing-role-based-permission/

Highlighted
Kudo Kingpin
Kudo Kingpin

Re: Custom connector for Sharepoint REST API

Did you try adding and Accept  header?

Accept: application/json

 

Helpful resources

Announcements
secondImage

New Return to Workplace

Reopen responsibly, monitor intelligently, and protect continuously with solutions for a safer work environment.

August 2020 CYST Challenge

Check out the winners of the recent 'Can You Solve These?' community challenge!

Experience what’s next for Power Apps

Join us for an in-depth look at the new Power Apps features and capabilities at the free Microsoft Business Applications Launch Event.

Check this Out

Helpful information

Featuring samples like Return to the Workplace and Emergency Response Applications

secondImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

Top Solution Authors
Top Kudoed Authors
Users online (3,635)