UNPKG

flowviz

Version:

A framework which provides seamless integration with other phylogenetic tools and frameworks, while allowing workflow scheduling and execution, through the Apache Airflow workflow system.

35 lines (29 loc) 659 B
import Request from "./request"; import httpOptions from "./httpOptions"; class ToolService { constructor(baseUrl) { this.baseUrl = `${baseUrl}/tool`; } getTools(onError, onSuccess, loading) { return Request(this.baseUrl, {}, onError, onSuccess, loading); } getTool(toolName, onError, onSuccess, loading) { return Request( `${this.baseUrl}/${toolName}`, {}, onError, onSuccess, loading ); } postTool(body, onError, onSuccess, loading) { return Request( this.baseUrl, httpOptions.post(body), onError, onSuccess, loading ); } } export default ToolService;