Vlad Kiselev
Vlad Kiselev

Reputation: 349

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?

Upvotes: 17

Views: 3610

Answers (1)

Marc LaFleur
Marc LaFleur

Reputation: 33114

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.

Upvotes: 4

Related Questions