Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

Body missing in ApiException

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

Nobody has claimed this yet.

Assessment

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

Research direction

Start with ApiException and compare the existing getResponseHeaders() accessor with the v5 GraphServiceException.getMessage(true) behavior described in the issue. Determine whether the failed response body is retained and whether the existing headers are response or request headers. Done means the intended body accessor and header naming are resolved and covered by the project’s relevant tests.

Written by the indexing model from the issue text.

Description

status:waiting-for-triage type:feature
Is your feature request related to a problem? Please describe the problem.

In v6 I am missing a method to get the body of a failed request, which may help to reproduce an issue.

With v5 I'm able to call graphServiceException.getMessage(true); which contains the headers and body of the failed request. However in v6 there is a method for the headers apiException.getResponseHeaders(), but none for the body.

Question on that: Are these really the responseHeaders and not the requestHeaders of the failed request? I don't see why someone would need the headers of the response message. So maybe this case is just a naming issue.

Describe the solution you'd like.

Add method getRequestBody or getResponseBody analogue to getRequestHeaders or getResponseHeaders

Additional context?

No response

Dominant language
Java
Stars
444
Forks
154
Avg merge
18h 28m
Merged PRs (30d)
4

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.

More from microsoftgraph/msgraph-sdk-java

All issues in microsoftgraph/msgraph-sdk-java

Similar issues

More Java issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.