Closed TylerLeonhardt closed 3 years ago
My device is using the C# sdk and I wanted to send a 500 back when an error occurred on the device.
In the C# sdk, you can do this which will send back a 500 via the status property: retValue = new MethodResponse(new byte[0], 500);
retValue = new MethodResponse(new byte[0], 500);
I can confirm 500 is being sent over using the iothub-explorer:
> iothub-explorer device-method mbp error {} {"status":500,"payload":{"rip":true}}
where mbp is the deviceid and error is the direct method name.
In the preconfigured solution, I see this:
which says it succeeded when it should have failed.
Any thoughts?
Note: As of December 10th 2020, Remote Monitoring solution accelerator is no longer supported. All supporting repositories have been archived.
My device is using the C# sdk and I wanted to send a 500 back when an error occurred on the device.
In the C# sdk, you can do this which will send back a 500 via the status property:
retValue = new MethodResponse(new byte[0], 500);
I can confirm 500 is being sent over using the iothub-explorer:
where mbp is the deviceid and error is the direct method name.
In the preconfigured solution, I see this:![microsoftteams-image](https://user-images.githubusercontent.com/2644648/35699782-e72dfeec-0745-11e8-84b2-8d198f948a54.png)
which says it succeeded when it should have failed.
Any thoughts?