Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to create organizational contact using MS Graph or Office 365 REST API

Office 365 administration center allows to create organizational contacts which are shared with all users in organization.

In MS Graph documentation API of this functionality is badly documented and located in BETA section. Moreover, there is no command to create such a contact: https://developer.microsoft.com/en-us/graph/docs/api-reference/beta/resources/orgcontact

It looks like in Graph this functionality was not implemented. Using typical POST request to the /beta/contacts ends with an error response in Json structure: Unsupported resource type 'Contact' for operation 'Create'.

Note 1: I don't have any user logged in. My application uses service/daemon authentication.

Is there any other way to create organizational contact?

like image 236
Vlad Kiselev Avatar asked Apr 28 '17 09:04

Vlad Kiselev


1 Answers

At this time, creating new orgContact objects isn't supported by the Graph API. You also cannot create organizational contacts with the Azure AD Graph API. For more information about organizational contacts, including how they are created in your tenant, see the Contact Entity documentation.

Organization Contacts are documented in the beta section because this API is in fact still in beta. I'm sorry you ran into issues here but with any beta endpoint there is always likelihood of missing/broken features and sparse documentation. There is also a substantial likelihood of breaking changes being rolled out to beta endpoints. As such, we do not recommend using them in production scenarios.

like image 67
Marc LaFleur Avatar answered Oct 15 '22 23:10

Marc LaFleur