Open odungern opened 4 years ago
With respect to our discussion REST URL-elements (tags): camelCase or hyphenated ( ../dataTypes/,, vs. ../data-types/..):
BUT: I think it is important to have the same tags/tokens in the schema and the API (see #5).
My proposal:
What do you think: @oalt @oeichmann @S-Ruesch ?
My proposal:
- use all lowercase tags starting SpecIF v1.0, both in the schema and the API.
- means we will say datatypes, propertyclasses, resourceclasses and statementclasses - in the schema there are no other in camelCase, so far.
- I think those are not too difficult to read, so that using a dash is not really a 'must'.
In the schema there are more camelCase tags, for example changedAt, changedBy or specifVersion. Or am i wrong? I think i would prefer camelCase or hyphenated for better readability. But i don't have a favorite naming convention.
More important is in my opinion the consistency between schema and API as well as the consistency with standards in various technologies, from JS, JSON, XML and all of the W3C web standards. Then, we arrive at the least common denominator, the lowercase version.
I do not like the idea to give up camel case in the SpecIF schema. I think this is not good for the readability of the JSON data. And I repeat my argumentation I said in the Telco: Different languages resp. technologies have different coding standards. JSON uses camel case in the most cases and Web APIs use the notation with lower case and '-' symbol separation very often. At the end all the names mean the same thing! So for me it would be not the most important thing to have equal formatting for the JSON and the WebAPI. One example for the "diversity approach" is the OpenAPI code generator: From the same OpenAPI spec file it generates code for different languages in different formatting. Example: GET /data-types will result in
e.g. Microsoft API Guidelines