UNPKG

596 BTypeScriptView Raw
1import { OpAPI, APIConfig } from '../interfaces';
2import APICore from './core/api-core';
3/**
4 * An API factory class for operations
5 */
6export default abstract class OperationAPI<T = APIConfig> extends APICore<T> {
7 /**
8 * Called when the API is created with in another Operation.
9 * This will only be called once during an operation
10 * @returns an Operation API which is one of the following
11 * - an object with function properties
12 * - an instances of a class
13 * - a function
14 */
15 abstract createAPI(...params: any[]): Promise<OpAPI>;
16}