-
Notifications
You must be signed in to change notification settings - Fork 38
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Subscription to EventService/Subscriptions - 204 response code #53
Comments
While a 201 is more appropriate of a response based on the specification, my interpretation of the spec reads that a 204 may be returned while still succeeding with a POST/PATCH in a few places (it just reads "if the service is unable to return a payload", rather than "service was unable to create/patch a payload", the former being a 2** code and the latter being some 4** code) But yes, 201 should be returned in most of these cases if possible, I'm just not sure if it's 100% reliable when writing a client for it. Will likely still implement 201 but I would want to ask... |
Is my POST body format correct for a successful subscription? Also, from https://www.dmtf.org/sites/default/files/standards/documents/DSP0266_1.6.1.pdf :
|
In terms of the payload, you shouldn't be wrapping the content inside of "EventDestination :", it should just start with the curly braces. I believe some mock-ups have a mock subscription listed (like public-bladed?) Thanks for the spec catch! |
Okay - great! I wasn't sure if I'm not meeting some 'minimum requirement' for subscription POST parameters. |
Just for clarity, this is what the body of the POST request should look like:
"SubscriptionType" is not needed since this is filled in by the service once the Event Destination resource is created. "EventTypes" is also a required property on Create operations. |
Thanks for the clarification! |
I'm attempting to use Node to send a POST request to
/redfish/v1/EventService/Subscriptions
with the following body:I'm assuming something is wrong with my body format but I pulled this from the EventDestination schema. I'm getting a 204 response from RMS and am expecting a 201.
For the full function, see line 272-290 at https://github.com/andrewbossie/SER401-Redfish/blob/US-51-aantes/rfInsight/controllers/RoutesController.js
The text was updated successfully, but these errors were encountered: