Interface: IssueParams
Defined in: packages/contracts/src/validation.ts:40
What the schema asked for, on the side of a failure that came from the schema: a limit, the allowed values, the property that is missing or extra, the format, or the named rule a pattern stands for. Taken from Ajv's error parameters for the keywords that carry them and from no other, because only these are known to hold schema facts and never the submitted value. It lets a caller (the gateway) write a sentence a person can act on without parsing Ajv's English.
Properties
allowed?
readonlyoptionalallowed?: readonlyunknown[]
Defined in: packages/contracts/src/validation.ts:44
const (one value) and enum: what the schema accepts.
format?
readonlyoptionalformat?:string
Defined in: packages/contracts/src/validation.ts:48
format: the format's name, such as email.
limit?
readonlyoptionallimit?:number
Defined in: packages/contracts/src/validation.ts:42
minLength, maxLength, minimum, maximum, minItems, maxItems and the exclusive bounds.
property?
readonlyoptionalproperty?:string
Defined in: packages/contracts/src/validation.ts:46
required: the missing property; additionalProperties: the extra one.
rule?
readonlyoptionalrule?:"uuid"|"tenant-scope-path"|"scope-path"|"slug"|"unreserved-label"|"bundle-code"|"display-name"
Defined in: packages/contracts/src/validation.ts:56
pattern: which of the contracts' own rules failed, by name. The regular expression
itself is never carried: it is unreadable to a caller and noise in a log. A pattern
that is not one of PATTERN_RULES has no rule.
type?
readonlyoptionaltype?:string
Defined in: packages/contracts/src/validation.ts:50
type: the expected JSON type, such as string or integer.