The maximum allowed payload size for requests and responses in Microsoft Graph API varies based on the specific endpoint being used and the HTTP method being used (e.g. POST, PATCH, GET, DELETE). Additionally, the maximum payload size may also depend on other factors such as the authentication method being used and the type of data being sent or received.
As a general rule, the maximum payload size for requests and responses in Microsoft Graph API is typically limited to 4MB. However, some endpoints may have lower limits, such as 1MB or 2MB.
To find the specific maximum payload size for a given endpoint and HTTP method, you can consult the Microsoft Graph API documentation. Each endpoint documentation page includes a "Request body" section that specifies the maximum payload size for that endpoint.
For example, the documentation for the /users POST endpoint specifies a maximum payload size of 4MB, while the /users PATCH endpoint has a maximum payload size of 2MB. The /users GET and /users DELETE endpoints do not have a request body, so the maximum payload size for those endpoints is not relevant.
Keep in mind that exceeding the maximum allowed payload size for a given endpoint can result in errors or data loss, so it is important to ensure that your requests and responses stay within the specified limits.