import { Middleware, Context, Next } from 'koa'; declare namespace koaIP { type IPPatternsType = String | RegExp interface koaIPOptionsObject { whitelist?: Array, blacklist?: Array, handler?: (ctx: Context, next: Next) => any } type KoaIPOptions = koaIPOptionsObject | Array | IPPatternsType interface koaIP { (options: KoaIPOptions): Middleware; } } declare const koaIP: koaIP.koaIP; export = koaIP;