diff --git a/index.d.ts b/index.d.ts index 4dd583c..24868e9 100644 --- a/index.d.ts +++ b/index.d.ts @@ -383,6 +383,28 @@ export interface HookContext extends GetHookData, GetHookGetOnlyData, PostHookDa * @param options options */ xmlParse(xml:string, options?: {}): any + + /** + * get cookie from http header + * + * @param name cookie name + */ + cookieGet(name: string): string + + /** + * set cookie via http header + * + * @param name cookie name + * @param value cookie value + * @param options cookie options + */ + cookieSet(name: string, value: string, options?:{ + maxAge?: number + path?:string + domain?:string + secure?:boolean + httpOnly?:boolean + }): void } export interface HookException {