Conditional access, compliance, intent, app management policies list api do not support pagination

Đang mở
#1,164 1 bình luận 0 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 1 ngày

Chưa có ai nhận issue này.

Đánh giá

Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức phù hợp với người mới
38/100
Loại issue
Lỗi
Độ rõ ràng
Cần làm rõ
Mức độ hoạt động
Sôi nổi
Công nghệ
csharp
Lĩnh vực
api

Hướng nghiên cứu

Start by reproducing the report: call https://graph.microsoft.com/beta/identity/conditionalAccess/policies?$count=true&$top=100 and check whether ODataNextLink is absent — this strongly suggests a service-side behavior rather than an SDK defect, so confirm where the next-link is produced (service response vs. the .NET page extraction in the request adapter) before writing code. Inspect the generated request builder for identity/conditionalAccess/policies and the Kiota-generated page collection classes to see if any client-side trimming drops the link. Done means a clear verdict on whether the fix belongs in this repository, with an issue response or a minimal repro attached either way.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

status:waiting-for-triage type:bug
Describe the bug

According to docs https://learn.microsoft.com/en-us/graph/api/conditionalaccessroot-list-policies?view=graph-rest-beta&tabs=http, this api support pagination via top / skip.

But we faced an issue: we have 164 conditional access policies, we call api with $top=100 parameter, and ODataNextLink is missing in the response. Response contained exactly 100 policies. So we cannot load all policies if specify any top parameter.

Api returns all policies only if we remove the $top completelly. But in this variant we cannot control page and request size, and cannot be sure that all policies are loaded.

Image
Expected behavior

If we provide some $top parameter, which is less then total policies amount, the response should contain ODataNextLink

How to reproduce

Call https://graph.microsoft.com/beta/identity/conditionalAccess/policies?$count=true&$top=100 or with any top which is less then total policies amount in your environment.
See that ODataNextLink is missing.

SDK Version

No response

Latest version known to work for scenario above?

No response

Known Workarounds

Load conditional access policies without any top parameter.
Currently it returns all 164 policies on one page.
But this solution is 'uncontrolled'

Debug output
Click to expand log ```
</details>


### Configuration

_No response_

### Other information

_No response_
Ngôn ngữ chính
C#
Star
114
Fork
36
Merge trung bình
13 giờ 37 phút
Pull request đã merge (30 ngày)
4

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của microsoftgraph/msgraph-beta-sdk-dotnet

Tất cả issue của microsoftgraph/msgraph-beta-sdk-dotnet

Issue tương tự

Thêm issue về C#

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.