How can I specify a field as Summary or Detail

28 views
Skip to first unread message

Niranjan Nanda

unread,
Dec 30, 2016, 5:42:37 AM12/30/16
to JSON Schema
I want to understand if the spec allows to specify a particular field as summary or detail. As an example, schema for a resource (say) book has following properties:

bookId
title
pageCount
dateOfPublication

And, I want to denote bookId and title as summary and treat all the fields as detail. How can I specify this?

Henry H. Andrews

unread,
Dec 30, 2016, 4:26:07 PM12/30/16
to JSON Schema
Hi Niranjan,
  JSON Schema validation deals with the structure of the JSON rather than the usage, so it does not include any such information.  There is some discussion of a possible annotation/documentation vocabulary (separate from the validation and hyper-schema vocabularies) which could add such a thing, but that idea hasn't gotten very far yet.

thanks,
-henry
Reply all
Reply to author
Forward
0 new messages