Idea ID 2807929
In the REST driver configuration, under subscriber options, you can configure different resources and associated methods that your driver will pass in driver-operation-data. What is not configurable are the HTTP status codes that should be considered a successful response. One example is when calling an HTTP Post (add event) the driver expects 201 because that is the RESTful convention. However many APIs that I build drivers for do not always align perfectly to this convention creating the need to write custom policy to handle certain error status as a success. Similarly, I've seen modifies that we call return a 201 and get an error status as well.
It would be nice to be able to configure a list of status codes or better yet, a regular expression of what we expect to get as a response in the method configuration rather than trying to write policy to go around the default behavior (similar to configuring status codes to retry).
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.