Can get all applications, but not a single application via Graph.

Dee, Matthew TPC 156 Reputation points
2020-12-09T04:45:15.277+00:00

Hi,

I'm getting

Resource '1153b839-f46e-4d91-8f85-b19ab03e5177' does not exist or one of its queried reference-property objects are not present.

from the following code:

var app = await graph
  .Applications["1153b839-f46e-4d91-8f85-b19ab03e5177"]
  .Request()      
  .GetAsync();

The graph client is for the app, not the user, and the following works just fine:

var apps = await graph
    .Applications
    .Request()
    .GetAsync();

The list of returned application does contain an application with the id of "1153b839-f46e-4d91-8f85-b19ab03e5177", so I know that a) it exists and b) I have the correct API permissions to read Applications.

I'm wondering if it's this issue resurfacing maybe?

Microsoft Graph
Microsoft Graph
A Microsoft programmability model that exposes REST APIs and client libraries to access data on Microsoft 365 services.
10,773 questions
Microsoft Entra ID
Microsoft Entra ID
A Microsoft Entra identity service that provides identity management and access control capabilities. Replaces Azure Active Directory.
19,767 questions
{count} votes

Accepted answer
  1. 2020-12-09T19:03:16.267+00:00

    Hello, please ensure 1153b839-f46e-4d91-8f85-b19ab03e5177 is the object id of the application being queried, not the app Id. Permissions look ok since you're able to query all applications, otherwise you would be getting an 403 status code.

    Please let me know if you need more help. If the answer was helpful to you, please accept it and, optionally, provide feedback so that other members in the community can benefit from it.

    0 comments No comments

1 additional answer

Sort by: Most helpful
  1. Dee, Matthew TPC 156 Reputation points
    2020-12-09T21:19:59.537+00:00

    Doh! Totally my bad, cheers!

    0 comments No comments