Use of "null" in request object is awkward
The claims section of the request object structure makes use of things like:
{{{ "name": null }}}
The null value is awkward and makes the object look and feel malformed. Since a value is required for a proper JSON structure, I suggest we adopt a boolean on these fields with the following behavior:
{{{ "name": true }}}
Is a request to include the claim for "name" in the response.
{{{ "name": false }}}
Is a request to not include the claim for "name" in the response (which might be included by default otherwise).
A lack of claim specification tells the server to just do whatever its default action for that particular claim is.
This calculus gives us a means to both expand and contract the request, and a clear default from a client's perspective.
Comments (4)
-
-
Agreed > Mike.
True may be better than null, though.
-
- changed status to invalid
Reject. True / False does not make sense here.
-
Account Deleted True certainly makes more sense thank "null" at least. Using "null" makes it look like I'm asking for nothing back.
- Log in to comment
It's not clear to me that that "false" form is meaningful, since only the listed claims are to be returned when a request object is used. There's no default set from which claims are being removed in this case.