|
Post by ginugeorge on May 2, 2023 9:39:40 GMT
When we are issuing a POST Call to any resource say https://{{ip}}/redfish/v1/AccountService/Accounts for creation of a new Account, the new Account gets created and is displayed in the response with 201 Created as the http status code; also the Location header will contain the URI of the newly created resource. My clarification is the whether the Location Header should list the newly created resource using the Absolute URI i.e. https://{{ip}}/redfish/v1/AccountService/Accounts/<<Account-Instance>> or the Relative URI i.e. /redfish/v1/AccountService/Accounts/<<Account-Instance>>or is it ok to use any of the above formats ?
|
|
|
Post by mraineri on May 2, 2023 13:01:50 GMT
Per RFC7231, you are allowed to use either. However, absolute URIs can be very difficult since the client might be accessing the service through a proxy or other type of layering; relative URIs are much easier for a client to handle in responses. There is an issue in libredfish about this, and the comment from "edtanous" is worth reading: github.com/DMTF/libredfish/issues/156
|
|