Module
x/windmill/windmill-api/services/FlowService.ts
Windmill deno client (separated from the main repo because most of the code is auto-generated from the openapi and not worth committing)
Extremely Popular
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245/* istanbul ignore file *//* tslint:disable *//* eslint-disable */import type { Flow } from '../models/Flow.ts';import type { OpenFlow } from '../models/OpenFlow.ts';import type { OpenFlowWPath } from '../models/OpenFlowWPath.ts';
import type { CancelablePromise } from '../core/CancelablePromise.ts';import { OpenAPI } from '../core/OpenAPI.ts';import { request as __request } from '../core/request.ts';
export class FlowService {
/** * list all available hub flows * @returns any hub flows list * @throws ApiError */ public static listHubFlows(): CancelablePromise<{ flows?: Array<{ id: number; flow_id: number; summary: string; apps: Array<string>; approved: boolean; votes: number; }>; }> { return __request(OpenAPI, { method: 'GET', url: '/flows/hub/list', }); }
/** * get hub flow by id * @returns any flow * @throws ApiError */ public static getHubFlowById({ id, }: { id: number, }): CancelablePromise<{ flow?: OpenFlow; }> { return __request(OpenAPI, { method: 'GET', url: '/flows/hub/get/{id}', path: { 'id': id, }, }); }
/** * list all available flows * @returns Flow All available flow * @throws ApiError */ public static listFlows({ workspace, page, perPage, orderDesc, createdBy, pathStart, pathExact, showArchived, }: { workspace: string, /** * which page to return (start at 1, default 1) */ page?: number, /** * number of items to return for a given page (default 30, max 100) */ perPage?: number, /** * order by desc order (default true) */ orderDesc?: boolean, /** * mask to filter exact matching user creator */ createdBy?: string, /** * mask to filter matching starting path */ pathStart?: string, /** * mask to filter exact matching path */ pathExact?: string, /** * (default false) * show also the archived files. * when multiple archived hash share the same path, only the ones with the latest create_at * are displayed. * */ showArchived?: boolean, }): CancelablePromise<Array<Flow>> { return __request(OpenAPI, { method: 'GET', url: '/w/{workspace}/flows/list', path: { 'workspace': workspace, }, query: { 'page': page, 'per_page': perPage, 'order_desc': orderDesc, 'created_by': createdBy, 'path_start': pathStart, 'path_exact': pathExact, 'show_archived': showArchived, }, }); }
/** * get flow by path * @returns Flow flow details * @throws ApiError */ public static getFlowByPath({ workspace, path, }: { workspace: string, path: string, }): CancelablePromise<Flow> { return __request(OpenAPI, { method: 'GET', url: '/w/{workspace}/flows/get/{path}', path: { 'workspace': workspace, 'path': path, }, }); }
/** * exists flow by path * @returns boolean flow details * @throws ApiError */ public static existsFlowByPath({ workspace, path, }: { workspace: string, path: string, }): CancelablePromise<boolean> { return __request(OpenAPI, { method: 'GET', url: '/w/{workspace}/flows/exists/{path}', path: { 'workspace': workspace, 'path': path, }, }); }
/** * create flow * @returns string flow created * @throws ApiError */ public static createFlow({ workspace, requestBody, }: { workspace: string, /** * Partially filled flow */ requestBody: OpenFlowWPath, }): CancelablePromise<string> { return __request(OpenAPI, { method: 'POST', url: '/w/{workspace}/flows/create', path: { 'workspace': workspace, }, body: requestBody, mediaType: 'application/json', }); }
/** * update flow * @returns string flow updated * @throws ApiError */ public static updateFlow({ workspace, path, requestBody, }: { workspace: string, path: string, /** * Partially filled flow */ requestBody: OpenFlowWPath, }): CancelablePromise<string> { return __request(OpenAPI, { method: 'POST', url: '/w/{workspace}/flows/update/{path}', path: { 'workspace': workspace, 'path': path, }, body: requestBody, mediaType: 'application/json', }); }
/** * archive flow by path * @returns string flow archived * @throws ApiError */ public static archiveFlowByPath({ workspace, path, }: { workspace: string, path: string, }): CancelablePromise<string> { return __request(OpenAPI, { method: 'POST', url: '/w/{workspace}/flows/archive/{path}', path: { 'workspace': workspace, 'path': path, }, }); }
}