schemas/README: Document $id conventions

1. Get the designation of the version correct.
2. That empty `#` fragment is a SHOULD NOT, so just don't.
3. Append `_<source>` to the "filename" where necessary.
This commit is contained in:
Athanasius 2022-09-02 13:46:18 +01:00
parent 08127d261f
commit b3876824f7
No known key found for this signature in database
GPG Key ID: 8C392035DD80FD62

View File

@ -29,7 +29,16 @@ It is best to base any new Schema file on
contents all Schemas specify a top-level JSON Object with the data:
1. `$schemaRef` - Which Schema (including version) this message is for.
2. `header` - Object containing mandatory information about the upload;
2. `$id` - The canonical URL for this schema once it is in live service.
1. Remember to have the version as in `journal/1` not `journal-v1.0`.
2. Do **NOT** end this with a `#` empty fragment. This is
[documented](https://json-schema.org/draft/2020-12/json-schema-core.html#section-8.2.1)
as unnecessary.
3. Where there are two separate schemas for the same kind of data, but one
is for Journal-sourced, and the other for CAPI-sourced, you should have
the "filename" of the schema end with `_<source>`, e.g.
`fcmaterials_journal/1` and `fcmaterials_capi/1`.
3. `header` - Object containing mandatory information about the upload;
1. `uploaderID` - a unique ID for the player uploading this data.
Don't worry about privacy, the EDDN service will hash this with a key
that is regularly changed so no-one knows who an uploader is in-game.