Azure C# clients should be able to set a RequestId property on CloudException
A common scenario for using RequestId is customer support. If a customer has an issue using a client library, they can send the request ID of the response to support, who can then correlate it with server-side logs from the REST API.
Azure C# clients generated by AutoRest currently populate a RequestId property on the AzureOperationResponse, but only in cases where the request succeeds. Arguably it is far more important to get the request ID when the request fails, but there is no property on CloudException on which to set it. For now, a workaround is to get the header directly from CloudException.Response.Headers, but this is less than ideal since the actual name of the header can vary from service to service.
Thanks!