Open joshhunt opened 3 years ago
Oh, it turns out the these relationships are documented, but just not how I would have expected, and not everywhere 😅
It's there fine on DestinyCollectiblesComponent
"Destiny.Components.Collectibles.DestinyCollectiblesComponent": {
"type": "object",
"properties": {
"collectibles": {
"type": "object",
"additionalProperties": {
"$ref": "#/components/schemas/Destiny.Components.Collectibles.DestinyCollectibleComponent"
},
"x-mapped-definition": {
"$ref": "#/components/schemas/Destiny.Definitions.Collectibles.DestinyCollectibleDefinition"
},
"x-dictionary-key": {
"type": "integer",
"format": "uint32"
}
},
and on a few other components (it's there on DestinyPresentationNodesComponent
and DestinyItemStatBlockDefinition.stats
), but it would be really nice if it was included in more places (such as DestinyRecordsComponent
) 🙂
In the OpenAPI spec, dictionary keys are specified with the custom extension
x-dictionary-key
. It would be exceptionally helpful (for all three of us who're building tooling from the JSON spec) if this also included thex-mapped-definition
reference for when the dictionary key is a hash referencing definition.For example:
I hope this relationship information is available and can be documented in the API spec!