Interface ICommandOptions

interface ICommandOptions {
    aliases?: string[];
    code: (ctx: Ctx) => Promise<any>;
    guards?: (string | MiddlewareFunction)[];
    name: string;
    schema?: any;
    [key: string]: any;
}

Indexable

  • [key: string]: any

    Custom data for guards, e.g. coin cost

Properties

aliases?: string[]
code: (ctx: Ctx) => Promise<any>
guards?: (string | MiddlewareFunction)[]

Array of guard functions or names (per-command middleware)

name: string
schema?: any