Forum Discussion
yname2480
Nov 03, 2023Copper Contributor
MS Teams graph API stopped working
In our project we were using Microsoft graph teams chat and channel APIs. It was working earlier but it stopped working before a month. Now throwing exception related to subscription. On investigating I found that these are metered APIs and require subscription to be added. Now my doubt is how it was working earlier since last 1.5 years? Is the subscription and payment actually required?
Exception:
com.microsoft.graph.http.GraphServiceException: Error code: PaymentRequired
Error message: To call this API, the app must be associated with an Azure subscription, see https://aka.ms/teams-api-payment-requirements for details.
GET https://graph.microsoft.com/v1.0/users/0dt1863-601e-3269-bf4b-0sc9eh63b665/chats/microsoft
•graph.getAllMessages?model=B&%24top=200
SdkVersion : graph-java/v5.17.0
402 : Payment Required
_[Some information was truncated for brevity, enable debug logging for more details]
1 Reply
Hi yname2480
This is quite a recent change on these APIs. The article you linked stated July 5th, and the onboarding has been done in phases.
So yes, configuring subscription and enabling it is required from now on.