lemon-engine
Version:
Lemon Engine Module to Synchronize Node over DynamoDB + ElastiCache + Elasticsearch by [lemoncloud](https://lemoncloud.io)
27 lines (26 loc) • 1.04 kB
TypeScript
/**
* WEB Proxy Service Exports
* - proxy call to web service.
* - must be matched with `web-api.js` in `lemon-backbone-api`.
*
* #History
* 2019.05.27 - support headers with relaying.
*
* @author steve@lemoncloud.io
* @date 2019-05-23
* @copyright (C) lemoncloud.io 2019 - All Rights Reserved.
*/
import { EnginePluggable, EnginePluginBuilder } from '../common/types';
export interface WebProxy extends EnginePluggable {
/**
* get the current endpoint address.
*/
endpoint: () => string;
do_get: (host: string, path: string, $opt?: any, $param?: any, $body?: any) => any;
do_put: (host: string, path: string, $opt?: any, $param?: any, $body?: any) => any;
do_patch: (host: string, path: string, $opt?: any, $param?: any, $body?: any) => any;
do_post: (host: string, path: string, $opt?: any, $param?: any, $body?: any) => any;
do_delete: (host: string, path: string, $opt?: any, $param?: any, $body?: any) => any;
}
declare const maker: EnginePluginBuilder<WebProxy>;
export default maker;