Unable to get channels using graph api - microsoft-graph-api

while fetching channels from the team using graph API is not working. It is not working from today. I am getting the following exception.
https://i.stack.imgur.com/tA1Qv.png

I tried the same with code that worked just fine 3h ago to get channels from a specific team. Now I'm getting the same exception. Same Exception when using Graph-Tester.
Coworker tried it aswell with Graph-Tester, apparently it works just fine for her. Seems like its user related. Propably a bug on Microsofts side.

It seems that it could be a bug. I'm confirming that right now GET /teams/[-groupid-]/channels fails for Delegated permission type requests, both for v1.0 & beta with a 400 Bad Request "Failed to execute Skype backend request GetThreadS2SRequest."
However, it's working for me (200) when I use Application permission type in Postman.

It was fixed by the Microsoft Graph team. Now it's working fine. It's not the only problem with channels. It's a problem with team endpoint API. The graph team is fixed the API related issue.

Related

Graph API fails for Archive mailboxes

I've been using the Microsoft Graph API to access Exchange Online (Office365) In-Place Archives.
It's basically an authenticated GET HTTPS request against https://graph.microsoft.com/v1.0/users/user#company.onmicrosoft.com/mailFolders/ArchiveMsgFolderRoot and it used to work fine.
Starting this week (end of April 2020), the same request against the same resource (no change) started failing with:
404 Response: {'error': {'code': 'ErrorInvalidMailboxItemId', 'message': "Item Id doesn't belong to the current mailbox.", 'innerError': {'request-id': '4a339242-9821-42a9-9622-4b1f7cd2c162', 'date': '2020-04-24T10:01:35'}}}
Other mailboxes (not ArchiveMsgFolderRoot) continue to work fine, no problem there. Only In-Place archives are affected.
How do you access In-places Archives from the Graph API now? Can you share an example?
Same here. We are trying to figure out what exactly changed on MS side.
MS removed support for In-Place Archives in API. All options on the internet are not working anymore. We are implementing a workaround.
Support of ArchiveMsgFolderRoot was never an official feature. There was an announcement that archiving is going be changing coming time.

graph.microsoft.com/beta/teams/***/channels/**/messages POST on this api is not working

https://graph.microsoft.com/beta/teams/fd7c1****************/channels/19***********************/messages POST on this api is not working. It was working fine until yesterday. GET is still working fine. Post request gives me BadRequest status code 400.
This image is of a graph explorer that is not taking a post request on beta/teams/{teamId}/channels/{channelId}/messages
I found a similar issue when I call https://graph.microsoft.com/beta/teams. I try to create a new team with a json (template) body.
The following properties cannot be set in the initial POST request.
Please set them in a subsequent PATCH request: installedApps.
Thank for your response but I realized that the reason that api(above) did not work for me on that day was becuase I had archived the team before hand on the code. So apparently you can not push any message to channel using graph api once the team is archived. All I had to do was to replace the archive portion of the code to the bottom of the function.
Although this is my concern whether if the Microsoft will push this api to the v1. version or not. I am really worried that they will remove this api from the beta version and my app will break again.

Microsoft Graph API - Unknown Error when querying Shifts

When we query the shifts endpoint (in beta ver 0.7.0) with the following code:
var shifts = await graphClient.Teams[$"{this.teamId}"].Schedule.Shifts.Request().GetAsync();
We get the following exception
This was working ~40 days ago with the beta but now we get this error. We can query teams fine so we know the team ID is working but whenever we try to access shifts we get the above error.
Your client code is correct.
I was able to reproduce your error with Graph Explorer by trying to make the call with a user who hadn't consented to the Group.Read.All or Group.ReadWrite.All scopes.
Take a look at your access token using jwt.ms. Please add the missing scope to your application registration.

Microsoft Graph update subscription always results in 403 Forbidden error

Using Microsoft Graph I am successfully creating subscriptions, but when calling HTTP Patch to https://graph.microsoft.com/v1.0/subscriptions/ with a correct (works through Graph Explorer) json payload of
{ "expirationDateTime": "UTCTIME 2 minutes past current expiration"}
I always get 403 Forbidden as a result.
I have the permissions set (I think) correctly to Files.ReadWrite as per https://developer.microsoft.com/en-us/graph/docs/api-reference/v1.0/api/subscription_update. These should be the same permissions as Creating the subscription so can someone help as to why I can create but not update?
The problem you reported should be fixed now. Please let me know if you're still seeing 403s on subscription update requests.
You should set the permission on project config but not only the apps.dev.microsoft or azure app portal.
If you not sure which config file to set, just get started from the official sample code, or just find the keywords "GraphScope" in your project and add the Files.ReadWrite.All.
You get 403 mainly caused by some wrong config. Still need to check on your side. We can just provide the suggestion to assist you.

InternalOAuthError: Failed to obtain access token using passportjs

I am using https://github.com/jaredhanson/passport-oauth2 as my library to authenticate via Instagram, and everything was working fine until this error spontaneously occurred 2 days ago with no explanation as to why it has failed to obtain the access token.
My client IDs and secrets are correct and my client app is live according to instagram/developers. Is there some known solution to this? I haven't changed my code since I got this error so it can't be on my side especially since the error seems to be from the library but that hasn't been updated in a while either.
Any help? Thanks!

Resources