I’ve been trying for some time to document Nextory’s non-HTTP error codes into the definition. Each time I’ve tried, the schema was rejected due to the 4 and 5-digit codes (standard server codes being 3 digits).
Well today, I worked it out! I’ve been trying to work more in the YAML than in Stoplight’s UI but I gave in and used their modelling form, then did a little tweaking.
'1000': description: Input missing or invalid type: object properties: error: type: object properties: msg: type: string description: This error is sent when input is missing or invalid. All API versions. example: Input missing or invalid code: type: number example: 1000 required: - msg - code