mirror of
https://github.com/Kong/insomnia
synced 2024-11-08 14:49:53 +00:00
381cf74a19
Co-authored-by: Dimitri Mitropoulos <dimitrimitropoulos@gmail.com>
34 lines
835 B
TypeScript
34 lines
835 B
TypeScript
// @TODO We should make a PR for improving the types of httpsnippet.
|
|
declare module 'httpsnippet' {
|
|
export interface HTTPSnippetClient {
|
|
key: string;
|
|
title: string;
|
|
link: string;
|
|
description: string;
|
|
}
|
|
|
|
export interface HTTPSnippetTarget {
|
|
key: string;
|
|
title: string;
|
|
extname: string;
|
|
default: string;
|
|
clients: HTTPSnippetClient[];
|
|
}
|
|
|
|
class HTTPSnippet {
|
|
constructor(data: any);
|
|
convert(target: string, options?: any): string | false;
|
|
|
|
convert(target: string, client?: string, options?: any): string | false;
|
|
|
|
static addTarget(target: HTTPSnippetTarget): void;
|
|
|
|
static addTargetClient(target: string, client: HTTPSnippetClient): void;
|
|
|
|
static extName(target: string): string;
|
|
static availableTargets(): HTTPSnippetTarget[];
|
|
}
|
|
|
|
export default HTTPSnippet;
|
|
}
|