Skip to content

Streamline server error deserialization when using graph core SDKs #826

@Ndiritu

Description

@Ndiritu

We currently provide different experiences across languages to handle error payloads from Graph when using only the Core SDK.
This is apparent when working with tasks (Page Iterator, Large File Upload) and Batch requests making it difficult for developers to understand the cause of failed requests.

e.g.
.NET Core SDK provides a ServiceException which stores the error payload as a string property for LFU

Java, PHP & Python currently don't expose/deserialize the error payload out of the box

We could agree to:

  • allow passing custom error mappings with the option of adding convenience methods on the GraphServiceClient to create tasks while passing the generated error models under the hood.
  • provide a standard Exception type for the Core SDK that we default to when no custom error mappings are present.

Previous guidance around this, worth referencing. https://github.com/microsoftgraph/msgraph-sdk-design/blob/master/content/ErrorContent.md

Metadata

Metadata

Assignees

No one assigned

    Labels

    type:enhancementEnhancement request targeting an existing experience

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions