cancel
Showing results for 
Search instead for 
Did you mean: 

Call Microsoft Graph API from Gateway

Mattias
Active Participant
0 Kudos

We're trying to access Microsoft Graph API to be able to create calender events in Office365, but I'm stuck in the authentication phase. Graph requires Oauth2 or OpenID for authentication, but I do now now if/how I could / how configure the Gateway client to authenticate with Oauth2. We're on Netweaver 7.5 sp 11 if that's any help.

up an application in Azure and collected the app id, I've also run the verification flow in from Postman to make sure that the flow on Azure works as expected, but I'm stuck on the SAP side.

Nb. that I'm trying to create a OData-client, not a service.

Accepted Solutions (1)

Accepted Solutions (1)

gregorw
Active Contributor

You might want to check out the ABAP SDK for Azure where I've contributed Graph support.

Mattias
Active Participant
0 Kudos

Oh, I will definitely have a look at the SDK. We've talked to Microsoft about support for App Insight and heard that it's also on it's way. I only looked at the master branch and didn't see your contribution. Thank you

Mattias
Active Participant
0 Kudos

gregorw Any chance this will be merged into MS's repo? Seems to be only a small thing in the maintainence view to fix.

gregorw
Active Contributor

Hi 9ef2f01b41e84f219aa1e666d8f86042 I would hope for someone who is more experienced with maintenance views to fix this.

Mattias
Active Participant
0 Kudos

gregorw Now I'm finally all up2date with the abapsdk, after som issues with maintanence views being locked when trying to reimport from abapgit.

Anyway, do you have an example what needs to be setup in zrest_config and so on. I'm trying to run the demo program, so I see what ids I should have, but not what settings they're supposed to have.

Answers (2)

Answers (2)

gregorw
Active Contributor

Hi 9ef2f01b41e84f219aa1e666d8f86042 ,

please setup the following SM59 HTTP destinations (starting with MS_AZURE...)

Unfortunately there is not yet a place to maintain the OAuth Client ID for the Azure Graph. So I've put it in the description of the Destination MS_AZURE_GRAPH.

Maintain this configurations in ZREST_CONFIG:

In table ZADF_CONFIG maintain this. The client_secret has to be maintained only for ADB2CTOKEN SAS Key field. In the other entries I only maintaned X:

In ZREST_CONF_MISC I have the following entries:

Hope that helps.

CU
Gregor

Mattias
Active Participant

That helps alot, thank you. I will sit with our AD guy on Monday to make sure I can authenticate agains the AD.

Thank you again

h3n
Participant
0 Kudos

Hi Mattias,

I am also trying to access MS Graph through the SDK but I always getting an error when I start the demo program. The error message is as following: "Error in importing encoded SAS Key value for ADB2CTOKEN"

Can you help?

Regards

Henning