1 | import { Collection } from 'discord.js';
|
2 | import Connection, { Endpoint } from './Connection';
|
3 | export declare type YAMLConnections = {
|
4 | [name: string]: Endpoint[] | string;
|
5 | };
|
6 | export declare class CMError extends Error {
|
7 | }
|
8 | export default class ConnectionsManager {
|
9 | list: Collection<string, Connection>;
|
10 | constructor();
|
11 | load(): Promise<void>;
|
12 | static validateEndpoints(endpoints: Endpoint[]): Promise<Endpoint[]>;
|
13 | static createAutomaticDiscordChannel(threadID: string, name: string): Promise<Connection>;
|
14 | getWithCreateFallback(threadID: string, name: string): Promise<void | Connection>;
|
15 | getWith(id: string): Connection;
|
16 | get(name: string): Connection | undefined;
|
17 | has(id: string): boolean;
|
18 | save(): Promise<void>;
|
19 | }
|