microsoftgraph / microsoftgraph/msgraph-sdk-java

PostRequestConfiguration doesn't allow setting of query parameters

Open
#2,364 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

status:waiting-for-triage type:bug
Dominant language
Java
Stars
444
Forks
154
Avg merge
18h 28m
Merged PRs (30d)
4

Description

Describe the bug

When getting a list of users by IDs it is possible to filter and select further with the use of query paramters (same as the get request for all / one user). Unfornuately the Java SDK doesn't allow that. The PostRequestConfiguration only allows to modify the headers of the request.

Expected behavior

Same as the get request:

 List<DirectoryObject> page = graphServiceClient.users().getByIds().post(body, config -> {
    config.queryParameters.select = new String[] {"onPremisesSamAccountName", "userPrincipalName",
                "department"};
 }).getValue();
How to reproduce

see above

SDK Version

6.36.0

Latest version known to work for scenario above?

No response

Known Workarounds

No response

Debug output
Configuration

No response

Other information

No response

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by locating the Java SDK's PostRequestConfiguration and the users().getByIds().post request path. Compare its configuration handling with the corresponding GET request, then add coverage showing that query parameters such as select can be supplied and applied to the request.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
api
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
55/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.