Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Client bug]: A list of a site doesn't support $count #1749

Closed
olivermue opened this issue Mar 20, 2023 · 1 comment · Fixed by #1906
Closed

[Client bug]: A list of a site doesn't support $count #1749

olivermue opened this issue Mar 20, 2023 · 1 comment · Fixed by #1906

Comments

@olivermue
Copy link

Describe the bug
The SDK contains the method

var count = await serviceClient.Sites["root"].Lists[myList.Id].Items.Count.GetAsync();

This will be transformed into the following HTTP request

GET https://graph.microsoft.com/v1.0/sites/root/lists/f089c611-fc87-454d-a7f7-cee8ca9ed0c7/items/$count

and returns an 404 status with "error.code": "itemNotFound". Also within the documentation I can't find any hint, that this method is currently supported.

Expected behavior
Either let the graph backend support this call to retrieve the number of elements (what I would prefer 😉) or remove this method from the SDK.

Client version
v5.2.0

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants