Documentation
    Preparing search index...

    Interface IInteger

    Integer type schema.

    Represents a JSON Schema integer type with numeric constraints. Maps to TypeScript number with integer validation. Supports range constraints, enum restrictions, and divisibility checks.

    interface IInteger {
        default?: number & tags.Type<"int64">;
        deprecated?: boolean;
        description?: string;
        enum?: (number & tags.Type<"int64">)[];
        example?: any;
        examples?: Record<string, any>;
        exclusiveMaximum?: number & tags.Type<"int64">;
        exclusiveMinimum?: number & tags.Type<"int64">;
        maximum?: number & tags.Type<"int64">;
        minimum?: number & tags.Type<"int64">;
        multipleOf?: number & tags.Type<"uint64"> & tags.ExclusiveMinimum<0>;
        readOnly?: boolean;
        title?: string;
        type: "integer";
        writeOnly?: boolean;
    }

    Hierarchy (View Summary)

    Index

    Properties

    default?: number & tags.Type<"int64">

    Default value when not provided.

    The integer value to use when the LLM omits this parameter.

    deprecated?: boolean

    Whether this type is deprecated.

    When true, indicates the type should no longer be used and may be removed in future versions. Set via the @deprecated JSDoc tag.

    description?: string

    Detailed description of the schema.

    Full documentation for the type, explaining its purpose, constraints, and usage. Extracted from JSDoc comment body. Supports markdown formatting in many JSON Schema consumers.

    enum?: (number & tags.Type<"int64">)[]

    Allowed integer values.

    Restricts the value to specific integer literals. Useful for representing enum-like integer codes or limited value sets.

    example?: any

    Single example value for the schema.

    A representative value that conforms to the schema, useful for documentation and testing. Set via the @example JSDoc tag.

    examples?: Record<string, any>

    Named example values for the schema.

    Multiple examples as key-value pairs, where keys are example names and values are conforming data. Useful for showing different valid states or edge cases.

    exclusiveMaximum?: number & tags.Type<"int64">

    Exclusive maximum value.

    The value must be strictly less than this number.

    exclusiveMinimum?: number & tags.Type<"int64">

    Exclusive minimum value.

    The value must be strictly greater than this number.

    maximum?: number & tags.Type<"int64">

    Maximum value (inclusive).

    The value must be less than or equal to this number.

    minimum?: number & tags.Type<"int64">

    Minimum value (inclusive).

    The value must be greater than or equal to this number.

    multipleOf?: number & tags.Type<"uint64"> & tags.ExclusiveMinimum<0>

    Value must be divisible by this number.

    Used for constraints like "must be even" (multipleOf: 2) or "must be a multiple of 100" (multipleOf: 100).

    readOnly?: boolean

    Whether the property is read-only.

    When true, the property should not be modified by clients and is typically set by the server. Useful for generated IDs, timestamps, etc.

    title?: string

    Short title for the schema.

    A brief, human-readable name for the type. Typically extracted from the first line of a JSDoc comment or the @title tag.

    type: "integer"
    writeOnly?: boolean

    Whether the property is write-only.

    When true, the property is accepted on input but never returned in responses. Common for sensitive data like passwords.