1 |
|
2 | import { flags } from '@oclif/command';
|
3 | import * as http from 'http';
|
4 | import * as knex from 'knex';
|
5 | import { TAuthContext } from '@bearer/functions/lib/declaration';
|
6 | import BaseCommand from '../base-command';
|
7 | export default class Invoke extends BaseCommand {
|
8 | static description: string;
|
9 | static flags: {
|
10 | data: flags.IOptionFlag<string | undefined>;
|
11 | file: flags.IOptionFlag<string | undefined>;
|
12 | help: import("@oclif/parser/lib/flags").IBooleanFlag<void>;
|
13 | path: flags.IOptionFlag<string | undefined>;
|
14 | silent: import("@oclif/parser/lib/flags").IBooleanFlag<boolean>;
|
15 | };
|
16 | static args: {
|
17 | name: string;
|
18 | required: boolean;
|
19 | }[];
|
20 | run(): Promise<void>;
|
21 | ensureJson: (maybeJson: string) => void;
|
22 | getFileContent: (filePath: string) => string | undefined;
|
23 | getFunctionContext(): TAuthContext;
|
24 | _startServer: (port: number) => Promise<http.Server>;
|
25 | private _db;
|
26 | db(): Promise<knex.QueryInterface>;
|
27 | getData: (referenceId: string) => Promise<any>;
|
28 | putData: (referenceId: string, data: any) => Promise<void>;
|
29 | }
|