import { IExecuteFunctions, IExecuteSingleFunctions, ILoadOptionsFunctions } from 'n8n-core'; import { cockpitApiRequest } from './GenericFunctions'; export async function getSingleton( this: IExecuteFunctions | IExecuteSingleFunctions | ILoadOptionsFunctions, resourceName: string, // tslint:disable-next-line:no-any ): Promise { return cockpitApiRequest.call(this, 'get', `/singletons/get/${resourceName}`); } export async function getAllSingletonNames( this: IExecuteFunctions | IExecuteSingleFunctions | ILoadOptionsFunctions, ): Promise { return cockpitApiRequest.call(this, 'GET', `/singletons/listSingletons`, {}); }