@pelican.ts/sdk 0.3.4-next.4 → 0.4.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.husky/pre-commit +3 -0
- package/README.md +1 -5
- package/biome.json +36 -0
- package/bun.lock +24 -1
- package/dist/api/index.d.mts +1641 -0
- package/dist/api/index.d.ts +1641 -0
- package/dist/api/index.js +2100 -0
- package/dist/api/index.mjs +2062 -0
- package/dist/index.d.mts +607 -1415
- package/dist/index.d.ts +607 -1415
- package/dist/index.js +569 -444
- package/dist/index.mjs +559 -442
- package/dist/types.d.ts +10 -10
- package/package.json +60 -49
- package/src/api/client/types/server.ts +64 -51
- package/src/api/client/types/user.ts +18 -19
- package/src/api/client/types/websocket.ts +76 -76
- package/src/api/index.ts +17 -0
- package/src/humane/Account.ts +73 -0
- package/src/humane/Client.ts +44 -0
- package/src/humane/Server.ts +206 -0
- package/src/humane/ServerAllocation.ts +41 -0
- package/src/humane/ServerBackup.ts +37 -0
- package/src/humane/ServerDatabase.ts +37 -0
- package/src/humane/ServerFile.ts +88 -0
- package/src/humane/ServerSchedule.ts +160 -0
- package/src/humane/ServerUser.ts +44 -0
- package/src/index.ts +18 -14
- package/src/utils/sized.ts +3 -6
package/dist/index.d.ts
CHANGED
|
@@ -1,77 +1,7 @@
|
|
|
1
1
|
import { AxiosInstance } from 'axios';
|
|
2
2
|
import WebSocket from 'isomorphic-ws';
|
|
3
|
-
import z from 'zod';
|
|
4
3
|
|
|
5
|
-
type
|
|
6
|
-
[P in K]: {
|
|
7
|
-
[Q in P]: V;
|
|
8
|
-
} & {
|
|
9
|
-
[Q in Exclude<KK, P>]?: never;
|
|
10
|
-
} extends infer O ? {
|
|
11
|
-
[Q in keyof O]: O[Q];
|
|
12
|
-
} : never;
|
|
13
|
-
}[K];
|
|
14
|
-
type PartialBy<T, K extends keyof T> = Omit<T, K> & Partial<Pick<T, K>>;
|
|
15
|
-
type Nullable<T> = T | null;
|
|
16
|
-
|
|
17
|
-
type User = {
|
|
18
|
-
uuid: string;
|
|
19
|
-
username: string;
|
|
20
|
-
email: string;
|
|
21
|
-
language: string;
|
|
22
|
-
image: string;
|
|
23
|
-
admin: boolean;
|
|
24
|
-
root_admin: boolean;
|
|
25
|
-
"2fa_enabled": number;
|
|
26
|
-
created_at: string;
|
|
27
|
-
updated_at: string;
|
|
28
|
-
};
|
|
29
|
-
type APIKey = {
|
|
30
|
-
identifier: string;
|
|
31
|
-
description: string;
|
|
32
|
-
allowed_ips: string[];
|
|
33
|
-
last_used_at: Nullable<string>;
|
|
34
|
-
created_at: string;
|
|
35
|
-
};
|
|
36
|
-
type SSHKey = {
|
|
37
|
-
name: string;
|
|
38
|
-
fingerprint: string;
|
|
39
|
-
pubic_key: string;
|
|
40
|
-
created_at: string;
|
|
41
|
-
};
|
|
42
|
-
type Permission = {
|
|
43
|
-
description: string;
|
|
44
|
-
keys: Record<string, string>;
|
|
45
|
-
};
|
|
46
|
-
|
|
47
|
-
declare class Account {
|
|
48
|
-
private readonly r;
|
|
49
|
-
constructor(requester: AxiosInstance);
|
|
50
|
-
info: () => Promise<User>;
|
|
51
|
-
updateEmail: (newEmail: string, password: string) => Promise<void>;
|
|
52
|
-
updatePassword: (newPassword: string) => Promise<void>;
|
|
53
|
-
apiKeys: {
|
|
54
|
-
list: () => Promise<APIKey[]>;
|
|
55
|
-
create: (description: string, allowed_ips?: string[]) => Promise<APIKey & {
|
|
56
|
-
secret_token: string;
|
|
57
|
-
}>;
|
|
58
|
-
delete: (identifier: string) => Promise<void>;
|
|
59
|
-
};
|
|
60
|
-
sshKeys: {
|
|
61
|
-
list: () => Promise<SSHKey[]>;
|
|
62
|
-
create: (name: string, public_key: string) => Promise<SSHKey>;
|
|
63
|
-
delete: (fingerprint: string) => Promise<void>;
|
|
64
|
-
};
|
|
65
|
-
twoFactor: {
|
|
66
|
-
info: () => Promise<{
|
|
67
|
-
image_url_data: string;
|
|
68
|
-
}>;
|
|
69
|
-
enable: (code: string) => Promise<{
|
|
70
|
-
tokens: string[];
|
|
71
|
-
}>;
|
|
72
|
-
disable: (password: string) => Promise<void>;
|
|
73
|
-
};
|
|
74
|
-
}
|
|
4
|
+
type ServerSignalOption = 'start' | 'stop' | 'restart' | 'kill';
|
|
75
5
|
|
|
76
6
|
type GenericResponse<T, N extends string = string, M = undefined> = {
|
|
77
7
|
object: N;
|
|
@@ -99,29 +29,25 @@ type CustomListResponse<T, M> = {
|
|
|
99
29
|
meta?: M;
|
|
100
30
|
};
|
|
101
31
|
|
|
102
|
-
type
|
|
32
|
+
type ServerDatabase$1 = {
|
|
33
|
+
id: string;
|
|
34
|
+
host: {
|
|
35
|
+
address: string;
|
|
36
|
+
port: number;
|
|
37
|
+
};
|
|
103
38
|
name: string;
|
|
104
|
-
description: string;
|
|
105
|
-
env_variable: string;
|
|
106
|
-
default_value: string;
|
|
107
|
-
server_value: string;
|
|
108
|
-
is_editable: boolean;
|
|
109
|
-
rules: string;
|
|
110
|
-
};
|
|
111
|
-
|
|
112
|
-
type ServerSubuser = {
|
|
113
|
-
uuid: string;
|
|
114
39
|
username: string;
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
permissions: SubuserPermission[] | string[];
|
|
40
|
+
connections_from: string;
|
|
41
|
+
max_connections: number;
|
|
42
|
+
relationships?: {
|
|
43
|
+
password: GenericResponse<{
|
|
44
|
+
password: string;
|
|
45
|
+
}, "database_password">;
|
|
46
|
+
};
|
|
123
47
|
};
|
|
124
|
-
|
|
48
|
+
|
|
49
|
+
type PartialBy<T, K extends keyof T> = Omit<T, K> & Partial<Pick<T, K>>;
|
|
50
|
+
type Nullable<T> = T | null;
|
|
125
51
|
|
|
126
52
|
type ServerLimits = {
|
|
127
53
|
memory: number;
|
|
@@ -139,98 +65,41 @@ type FeatureLimits = {
|
|
|
139
65
|
backups: number;
|
|
140
66
|
};
|
|
141
67
|
|
|
142
|
-
type
|
|
143
|
-
id: number;
|
|
144
|
-
ip: string;
|
|
145
|
-
alias: Nullable<string>;
|
|
146
|
-
port: number;
|
|
147
|
-
notes: Nullable<string>;
|
|
148
|
-
is_default: boolean;
|
|
149
|
-
};
|
|
150
|
-
|
|
151
|
-
type Server = {
|
|
152
|
-
server_owner: boolean;
|
|
153
|
-
identifier: string;
|
|
154
|
-
internal_id?: number;
|
|
155
|
-
uuid: string;
|
|
68
|
+
type StartupParams = {
|
|
156
69
|
name: string;
|
|
157
|
-
node: string;
|
|
158
|
-
is_node_under_maintenance: boolean;
|
|
159
|
-
sftp_details: {
|
|
160
|
-
ip: string;
|
|
161
|
-
alias: Nullable<string>;
|
|
162
|
-
port: number;
|
|
163
|
-
};
|
|
164
70
|
description: string;
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
status: Nullable<unknown>;
|
|
171
|
-
is_suspended: boolean;
|
|
172
|
-
is_installing: boolean;
|
|
173
|
-
is_transferring: boolean;
|
|
174
|
-
relationships: {
|
|
175
|
-
allocations: GenericListResponse<GenericResponse<ServerAllocation, "allocation">>;
|
|
176
|
-
variables: GenericListResponse<GenericResponse<EggVariable, "egg_variable">>;
|
|
177
|
-
egg?: GenericResponse<{
|
|
178
|
-
uuid: string;
|
|
179
|
-
name: string;
|
|
180
|
-
}, "egg">;
|
|
181
|
-
subusers: GenericListResponse<GenericResponse<ServerSubuser, "server_subuser">>;
|
|
182
|
-
};
|
|
183
|
-
};
|
|
184
|
-
type ServerStats = {
|
|
185
|
-
current_state: "installing" | "install_failed" | "reinstall_failed" | "suspended" | "restoring_backup" | "running" | "stopped" | "offline";
|
|
186
|
-
is_suspended: boolean;
|
|
187
|
-
resources: ServerResources;
|
|
188
|
-
};
|
|
189
|
-
type ServerResources = {
|
|
190
|
-
memory_bytes: number;
|
|
191
|
-
cpu_absolute: number;
|
|
192
|
-
disk_bytes: number;
|
|
193
|
-
network_tx_bytes: number;
|
|
194
|
-
network_rx_bytes: number;
|
|
195
|
-
uptime: number;
|
|
71
|
+
env_variables: string;
|
|
72
|
+
default_value: string;
|
|
73
|
+
server_value: string;
|
|
74
|
+
is_editable: boolean;
|
|
75
|
+
rules: string;
|
|
196
76
|
};
|
|
197
|
-
type
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
is_api: boolean;
|
|
201
|
-
ip: string;
|
|
202
|
-
description: Nullable<string>;
|
|
203
|
-
properties: Record<string, string>;
|
|
204
|
-
has_additional_metadata: boolean;
|
|
205
|
-
timestamp: string;
|
|
77
|
+
type StartupMeta = {
|
|
78
|
+
startup_command: string;
|
|
79
|
+
raw_startup_command: string;
|
|
206
80
|
};
|
|
207
81
|
|
|
208
|
-
type
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
port: number;
|
|
213
|
-
};
|
|
82
|
+
type ServerBackup$1 = {
|
|
83
|
+
uuid: string;
|
|
84
|
+
is_successful: boolean;
|
|
85
|
+
is_locked: boolean;
|
|
214
86
|
name: string;
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
password: string;
|
|
221
|
-
}, "database_password">;
|
|
222
|
-
};
|
|
87
|
+
ignored_files: string[];
|
|
88
|
+
checksum: Nullable<string>;
|
|
89
|
+
bytes: number;
|
|
90
|
+
created_at: string;
|
|
91
|
+
completed_at: Nullable<string>;
|
|
223
92
|
};
|
|
224
93
|
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
}
|
|
94
|
+
type EggVariable = {
|
|
95
|
+
name: string;
|
|
96
|
+
description: string;
|
|
97
|
+
env_variable: string;
|
|
98
|
+
default_value: string;
|
|
99
|
+
server_value: string;
|
|
100
|
+
is_editable: boolean;
|
|
101
|
+
rules: string;
|
|
102
|
+
};
|
|
234
103
|
|
|
235
104
|
type FileObject = {
|
|
236
105
|
name: string;
|
|
@@ -244,38 +113,6 @@ type FileObject = {
|
|
|
244
113
|
modified_at: string;
|
|
245
114
|
};
|
|
246
115
|
|
|
247
|
-
declare class ServerFiles {
|
|
248
|
-
private readonly r;
|
|
249
|
-
private readonly id;
|
|
250
|
-
constructor(requester: AxiosInstance, id: string);
|
|
251
|
-
list: (path?: string) => Promise<FileObject[]>;
|
|
252
|
-
/**
|
|
253
|
-
* Return the contents of a file. To read binary file (non-editable) use {@link download} instead
|
|
254
|
-
*/
|
|
255
|
-
contents: (path: string) => Promise<string>;
|
|
256
|
-
downloadGetUrl: (path: string) => Promise<string>;
|
|
257
|
-
download: (path: string) => Promise<ArrayBuffer>;
|
|
258
|
-
rename: (root: string | undefined, files: {
|
|
259
|
-
from: string;
|
|
260
|
-
to: string;
|
|
261
|
-
}[]) => Promise<void>;
|
|
262
|
-
copy: (location: string) => Promise<void>;
|
|
263
|
-
write: (path: string, content: string) => Promise<void>;
|
|
264
|
-
compress: (root: string | undefined, files: string[], archive_name?: string, extension?: "zip" | "tgz" | "tar.gz" | "txz" | "tar.xz" | "tbz2" | "tar.bz2") => Promise<void>;
|
|
265
|
-
decompress: (root: string | undefined, file: string) => Promise<void>;
|
|
266
|
-
delete: (root: string | undefined, files: string[]) => Promise<void>;
|
|
267
|
-
createFolder: (root: string | undefined, name: string) => Promise<void>;
|
|
268
|
-
chmod: (root: string | undefined, files: Array<{
|
|
269
|
-
file: string;
|
|
270
|
-
mode: number;
|
|
271
|
-
}>) => Promise<void>;
|
|
272
|
-
pullFromRemote: (url: string, directory?: string, filename?: string, // Unused
|
|
273
|
-
use_header?: boolean, // Unused
|
|
274
|
-
foreground?: boolean) => Promise<void>;
|
|
275
|
-
uploadGetUrl: () => Promise<string>;
|
|
276
|
-
upload: (file: File, root?: string) => Promise<void>;
|
|
277
|
-
}
|
|
278
|
-
|
|
279
116
|
type Schedule = {
|
|
280
117
|
id: number;
|
|
281
118
|
name: string;
|
|
@@ -308,12 +145,290 @@ type ScheduleTask = {
|
|
|
308
145
|
updated_at: Nullable<string>;
|
|
309
146
|
};
|
|
310
147
|
|
|
311
|
-
|
|
148
|
+
type SocketEventPayloadMap = {
|
|
149
|
+
[SOCKET_EVENT.AUTH_SUCCESS]: undefined;
|
|
150
|
+
[SOCKET_EVENT.STATUS]: PowerState;
|
|
151
|
+
[SOCKET_EVENT.CONSOLE_OUTPUT]: string;
|
|
152
|
+
[SOCKET_EVENT.STATS]: StatsWsJson;
|
|
153
|
+
[SOCKET_EVENT.DAEMON_ERROR]: undefined;
|
|
154
|
+
[SOCKET_EVENT.DAEMON_MESSAGE]: string;
|
|
155
|
+
[SOCKET_EVENT.INSTALL_OUTPUT]: string;
|
|
156
|
+
[SOCKET_EVENT.INSTALL_STARTED]: undefined;
|
|
157
|
+
[SOCKET_EVENT.INSTALL_COMPLETED]: undefined;
|
|
158
|
+
[SOCKET_EVENT.TRANSFER_LOGS]: string;
|
|
159
|
+
[SOCKET_EVENT.TRANSFER_STATUS]: string;
|
|
160
|
+
[SOCKET_EVENT.BACKUP_COMPLETED]: BackupCompletedJson;
|
|
161
|
+
[SOCKET_EVENT.BACKUP_RESTORE_COMPLETED]: undefined;
|
|
162
|
+
[SOCKET_EVENT.TOKEN_EXPIRING]: undefined;
|
|
163
|
+
[SOCKET_EVENT.TOKEN_EXPIRED]: undefined;
|
|
164
|
+
[SOCKET_EVENT.JWT_ERROR]: string;
|
|
165
|
+
};
|
|
166
|
+
type Listener<E extends SOCKET_EVENT> = SocketEventPayloadMap[E] extends undefined ? () => void : (payload: SocketEventPayloadMap[E]) => void;
|
|
167
|
+
type CloseEventLike = Parameters<NonNullable<WebSocket["onclose"]>>[0];
|
|
168
|
+
type ErrorEventLike = Parameters<NonNullable<WebSocket["onerror"]>>[0];
|
|
169
|
+
declare class ServerWebsocket {
|
|
312
170
|
private readonly r;
|
|
313
|
-
private readonly
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
171
|
+
private readonly serverId;
|
|
172
|
+
private socket?;
|
|
173
|
+
private currentToken?;
|
|
174
|
+
private readonly bus;
|
|
175
|
+
private debugLogging;
|
|
176
|
+
private stripColors;
|
|
177
|
+
private detachMessageListener?;
|
|
178
|
+
constructor(requester: AxiosInstance, id: string, stripColors?: boolean);
|
|
179
|
+
on<E extends SOCKET_EVENT>(event: E, listener: Listener<E>): () => void;
|
|
180
|
+
deregister<E extends SOCKET_EVENT>(event: E, listener: Listener<E>): void;
|
|
181
|
+
private emit;
|
|
182
|
+
connect(resumable?: boolean, debugLogging?: boolean): Promise<void>;
|
|
183
|
+
onSocketDisconnect(handler: (event: CloseEventLike) => void): void;
|
|
184
|
+
onSocketError(handler: (event: ErrorEventLike) => void): void;
|
|
185
|
+
makeResumable(disconnectsToo: boolean): void;
|
|
186
|
+
private attachMessageListener;
|
|
187
|
+
private handleIncomingMessage;
|
|
188
|
+
private parseMessage;
|
|
189
|
+
private normalisePayload;
|
|
190
|
+
private dispatchMessage;
|
|
191
|
+
private refreshCredentials;
|
|
192
|
+
private authenticate;
|
|
193
|
+
disconnect(): void;
|
|
194
|
+
requestStats(): void;
|
|
195
|
+
requestLogs(): void;
|
|
196
|
+
private send;
|
|
197
|
+
getStats(): Promise<StatsWsJson>;
|
|
198
|
+
getLogs(): Promise<string[]>;
|
|
199
|
+
sendPoweraction(action: ServerSignalOption): void;
|
|
200
|
+
sendCommand(cmd: string): void;
|
|
201
|
+
}
|
|
202
|
+
|
|
203
|
+
/**
|
|
204
|
+
* Source: https://github.com/pterodactyl/panel/blob/1.0-develop/resources/scripts/components/server/events.ts
|
|
205
|
+
*/
|
|
206
|
+
declare enum SOCKET_EVENT {
|
|
207
|
+
AUTH_SUCCESS = "auth success",
|
|
208
|
+
DAEMON_MESSAGE = "daemon message",
|
|
209
|
+
DAEMON_ERROR = "daemon error",
|
|
210
|
+
INSTALL_OUTPUT = "install output",
|
|
211
|
+
INSTALL_STARTED = "install started",
|
|
212
|
+
INSTALL_COMPLETED = "install completed",
|
|
213
|
+
CONSOLE_OUTPUT = "console output",
|
|
214
|
+
STATUS = "status",
|
|
215
|
+
STATS = "stats",
|
|
216
|
+
TRANSFER_LOGS = "transfer logs",
|
|
217
|
+
TRANSFER_STATUS = "transfer status",
|
|
218
|
+
BACKUP_COMPLETED = "backup completed",
|
|
219
|
+
BACKUP_RESTORE_COMPLETED = "backup restore completed",
|
|
220
|
+
TOKEN_EXPIRING = "token expiring",
|
|
221
|
+
TOKEN_EXPIRED = "token expired",
|
|
222
|
+
JWT_ERROR = "jwt error"
|
|
223
|
+
}
|
|
224
|
+
type BackupCompletedJson = {
|
|
225
|
+
checksum: string;
|
|
226
|
+
checksum_type: "sha1";
|
|
227
|
+
file_size: number;
|
|
228
|
+
is_successful: boolean;
|
|
229
|
+
uuid: string;
|
|
230
|
+
};
|
|
231
|
+
type PowerState = "starting" | "stopping" | "running" | "offline";
|
|
232
|
+
type StatsWsJson = {
|
|
233
|
+
memory_bytes: number;
|
|
234
|
+
memory_limit_bytes: number;
|
|
235
|
+
cpu_absolute: number;
|
|
236
|
+
network: {
|
|
237
|
+
rx_bytes: number;
|
|
238
|
+
tx_bytes: number;
|
|
239
|
+
};
|
|
240
|
+
state: PowerState;
|
|
241
|
+
uptime: number;
|
|
242
|
+
disk_bytes: number;
|
|
243
|
+
};
|
|
244
|
+
|
|
245
|
+
type ServerAllocation$1 = {
|
|
246
|
+
id: number;
|
|
247
|
+
ip: string;
|
|
248
|
+
alias: Nullable<string>;
|
|
249
|
+
port: number;
|
|
250
|
+
notes: Nullable<string>;
|
|
251
|
+
is_default: boolean;
|
|
252
|
+
};
|
|
253
|
+
|
|
254
|
+
type ServerSubuser = {
|
|
255
|
+
uuid: string;
|
|
256
|
+
username: string;
|
|
257
|
+
email: string;
|
|
258
|
+
language: string;
|
|
259
|
+
image: string;
|
|
260
|
+
admin: false;
|
|
261
|
+
root_admin: false;
|
|
262
|
+
"2fa_enabled": boolean;
|
|
263
|
+
created_at: string;
|
|
264
|
+
permissions: SubuserPermission[] | string[];
|
|
265
|
+
};
|
|
266
|
+
type SubuserPermission = "activity.read" | "allocation.create" | "allocation.delete" | "allocation.read" | "allocation.update" | "backup.create" | "backup.delete" | "backup.download" | "backup.read" | "backup.restore" | "control.console" | "control.restart" | "control.start" | "control.stop" | "database.create" | "database.delete" | "database.read" | "database.update" | "database.view-password" | "file.archive" | "file.create" | "file.delete" | "file.read" | "file.read-content" | "file.sftp" | "file.update" | "schedule.create" | "schedule.delete" | "schedule.read" | "schedule.update" | "settings.description" | "settings.reinstall" | "settings.rename" | "startup.docker-image" | "startup.read" | "startup.update" | "user.create" | "user.delete" | "user.read" | "user.update" | "websocket.connect";
|
|
267
|
+
|
|
268
|
+
type Server$1 = {
|
|
269
|
+
server_owner: boolean;
|
|
270
|
+
identifier: string;
|
|
271
|
+
internal_id?: number;
|
|
272
|
+
uuid: string;
|
|
273
|
+
name: string;
|
|
274
|
+
node: string;
|
|
275
|
+
is_node_under_maintenance: boolean;
|
|
276
|
+
sftp_details: {
|
|
277
|
+
ip: string;
|
|
278
|
+
alias: Nullable<string>;
|
|
279
|
+
port: number;
|
|
280
|
+
};
|
|
281
|
+
description: string;
|
|
282
|
+
limits: ServerLimits;
|
|
283
|
+
invocation: string;
|
|
284
|
+
docker_image: string;
|
|
285
|
+
egg_features: Nullable<string[]>;
|
|
286
|
+
feature_limits: FeatureLimits;
|
|
287
|
+
status: Nullable<unknown>;
|
|
288
|
+
is_suspended: boolean;
|
|
289
|
+
is_installing: boolean;
|
|
290
|
+
is_transferring: boolean;
|
|
291
|
+
relationships: {
|
|
292
|
+
allocations: GenericListResponse<GenericResponse<ServerAllocation$1, "allocation">>;
|
|
293
|
+
variables: GenericListResponse<GenericResponse<EggVariable, "egg_variable">>;
|
|
294
|
+
egg?: GenericResponse<{
|
|
295
|
+
uuid: string;
|
|
296
|
+
name: string;
|
|
297
|
+
}, "egg">;
|
|
298
|
+
subusers?: GenericListResponse<GenericResponse<ServerSubuser, "server_subuser">>;
|
|
299
|
+
};
|
|
300
|
+
};
|
|
301
|
+
type ServerStats = {
|
|
302
|
+
current_state: "installing" | "install_failed" | "reinstall_failed" | "suspended" | "restoring_backup" | "running" | "stopped" | "offline";
|
|
303
|
+
is_suspended: boolean;
|
|
304
|
+
resources: ServerResources;
|
|
305
|
+
};
|
|
306
|
+
type ServerResources = {
|
|
307
|
+
memory_bytes: number;
|
|
308
|
+
cpu_absolute: number;
|
|
309
|
+
disk_bytes: number;
|
|
310
|
+
network_tx_bytes: number;
|
|
311
|
+
network_rx_bytes: number;
|
|
312
|
+
uptime: number;
|
|
313
|
+
};
|
|
314
|
+
type ServerActivityLog = {
|
|
315
|
+
id: string;
|
|
316
|
+
event: string;
|
|
317
|
+
is_api: boolean;
|
|
318
|
+
ip: string;
|
|
319
|
+
description: Nullable<string>;
|
|
320
|
+
properties: Record<string, string>;
|
|
321
|
+
has_additional_metadata: boolean;
|
|
322
|
+
timestamp: string;
|
|
323
|
+
};
|
|
324
|
+
|
|
325
|
+
type User = {
|
|
326
|
+
uuid: string;
|
|
327
|
+
username: string;
|
|
328
|
+
email: string;
|
|
329
|
+
language: string;
|
|
330
|
+
image: string;
|
|
331
|
+
admin: boolean;
|
|
332
|
+
root_admin: boolean;
|
|
333
|
+
"2fa_enabled": boolean;
|
|
334
|
+
created_at: string;
|
|
335
|
+
updated_at: string;
|
|
336
|
+
};
|
|
337
|
+
type APIKey = {
|
|
338
|
+
identifier: string;
|
|
339
|
+
description: string;
|
|
340
|
+
allowed_ips: string[];
|
|
341
|
+
last_used_at: Nullable<string>;
|
|
342
|
+
created_at: string;
|
|
343
|
+
};
|
|
344
|
+
type SSHKey = {
|
|
345
|
+
name: string;
|
|
346
|
+
fingerprint: string;
|
|
347
|
+
pubic_key: string;
|
|
348
|
+
created_at: string;
|
|
349
|
+
};
|
|
350
|
+
type Permission = {
|
|
351
|
+
description: string;
|
|
352
|
+
keys: Record<string, string>;
|
|
353
|
+
};
|
|
354
|
+
|
|
355
|
+
declare class Account$1 {
|
|
356
|
+
private readonly r;
|
|
357
|
+
constructor(requester: AxiosInstance);
|
|
358
|
+
info: () => Promise<User>;
|
|
359
|
+
updateEmail: (newEmail: string, password: string) => Promise<void>;
|
|
360
|
+
updatePassword: (newPassword: string) => Promise<void>;
|
|
361
|
+
apiKeys: {
|
|
362
|
+
list: () => Promise<APIKey[]>;
|
|
363
|
+
create: (description: string, allowed_ips?: string[]) => Promise<APIKey & {
|
|
364
|
+
secret_token: string;
|
|
365
|
+
}>;
|
|
366
|
+
delete: (identifier: string) => Promise<void>;
|
|
367
|
+
};
|
|
368
|
+
sshKeys: {
|
|
369
|
+
list: () => Promise<SSHKey[]>;
|
|
370
|
+
create: (name: string, public_key: string) => Promise<SSHKey>;
|
|
371
|
+
delete: (fingerprint: string) => Promise<void>;
|
|
372
|
+
};
|
|
373
|
+
twoFactor: {
|
|
374
|
+
info: () => Promise<{
|
|
375
|
+
image_url_data: string;
|
|
376
|
+
}>;
|
|
377
|
+
enable: (code: string) => Promise<{
|
|
378
|
+
tokens: string[];
|
|
379
|
+
}>;
|
|
380
|
+
disable: (password: string) => Promise<void>;
|
|
381
|
+
};
|
|
382
|
+
}
|
|
383
|
+
|
|
384
|
+
declare class ServerDatabases {
|
|
385
|
+
private readonly r;
|
|
386
|
+
private readonly id;
|
|
387
|
+
constructor(requester: AxiosInstance, id: string);
|
|
388
|
+
list: (include?: ("password")[], page?: number) => Promise<ServerDatabase$1[]>;
|
|
389
|
+
create: (database: string, remote: string) => Promise<ServerDatabase$1>;
|
|
390
|
+
rotatePassword: (database_id: string) => Promise<ServerDatabase$1>;
|
|
391
|
+
delete: (database_id: string) => Promise<void>;
|
|
392
|
+
}
|
|
393
|
+
|
|
394
|
+
declare class ServerFiles {
|
|
395
|
+
private readonly r;
|
|
396
|
+
private readonly id;
|
|
397
|
+
constructor(requester: AxiosInstance, id: string);
|
|
398
|
+
list: (path?: string) => Promise<FileObject[]>;
|
|
399
|
+
/**
|
|
400
|
+
* Return the contents of a file. To read binary file (non-editable) use {@link download} instead
|
|
401
|
+
*/
|
|
402
|
+
contents: (path: string) => Promise<string>;
|
|
403
|
+
downloadGetUrl: (path: string) => Promise<string>;
|
|
404
|
+
download: (path: string) => Promise<ArrayBuffer>;
|
|
405
|
+
rename: (root: string | undefined, files: {
|
|
406
|
+
from: string;
|
|
407
|
+
to: string;
|
|
408
|
+
}[]) => Promise<void>;
|
|
409
|
+
copy: (location: string) => Promise<void>;
|
|
410
|
+
write: (path: string, content: string) => Promise<void>;
|
|
411
|
+
compress: (root: string | undefined, files: string[], archive_name?: string, extension?: "zip" | "tgz" | "tar.gz" | "txz" | "tar.xz" | "tbz2" | "tar.bz2") => Promise<void>;
|
|
412
|
+
decompress: (root: string | undefined, file: string) => Promise<void>;
|
|
413
|
+
delete: (root: string | undefined, files: string[]) => Promise<void>;
|
|
414
|
+
createFolder: (root: string | undefined, name: string) => Promise<void>;
|
|
415
|
+
chmod: (root: string | undefined, files: Array<{
|
|
416
|
+
file: string;
|
|
417
|
+
mode: number;
|
|
418
|
+
}>) => Promise<void>;
|
|
419
|
+
pullFromRemote: (url: string, directory?: string, filename?: string, // Unused
|
|
420
|
+
use_header?: boolean, // Unused
|
|
421
|
+
foreground?: boolean) => Promise<void>;
|
|
422
|
+
uploadGetUrl: () => Promise<string>;
|
|
423
|
+
upload: (file: File, root?: string) => Promise<void>;
|
|
424
|
+
}
|
|
425
|
+
|
|
426
|
+
declare class ServerSchedules {
|
|
427
|
+
private readonly r;
|
|
428
|
+
private readonly id;
|
|
429
|
+
constructor(requester: AxiosInstance, id: string);
|
|
430
|
+
list: () => Promise<Schedule[]>;
|
|
431
|
+
create: (params: ScheduleCreateParams) => Promise<Schedule>;
|
|
317
432
|
control: (sched_id: number) => ScheduleControl;
|
|
318
433
|
}
|
|
319
434
|
type ScheduleCreateParams = {
|
|
@@ -346,10 +461,10 @@ declare class ServerAllocations {
|
|
|
346
461
|
private readonly r;
|
|
347
462
|
private readonly id;
|
|
348
463
|
constructor(requester: AxiosInstance, id: string);
|
|
349
|
-
list: () => Promise<ServerAllocation[]>;
|
|
350
|
-
autoAssign: () => Promise<ServerAllocation>;
|
|
351
|
-
setNotes: (alloc_id: number, notes: string) => Promise<ServerAllocation>;
|
|
352
|
-
setPrimary: (alloc_id: number) => Promise<ServerAllocation>;
|
|
464
|
+
list: () => Promise<ServerAllocation$1[]>;
|
|
465
|
+
autoAssign: () => Promise<ServerAllocation$1>;
|
|
466
|
+
setNotes: (alloc_id: number, notes: string) => Promise<ServerAllocation$1>;
|
|
467
|
+
setPrimary: (alloc_id: number) => Promise<ServerAllocation$1>;
|
|
353
468
|
unassign: (alloc_id: number) => Promise<void>;
|
|
354
469
|
}
|
|
355
470
|
|
|
@@ -364,163 +479,38 @@ declare class ServerUsers {
|
|
|
364
479
|
delete: (user_uuid: string) => Promise<void>;
|
|
365
480
|
}
|
|
366
481
|
|
|
367
|
-
type ServerBackup = {
|
|
368
|
-
uuid: string;
|
|
369
|
-
is_successful: boolean;
|
|
370
|
-
is_locked: boolean;
|
|
371
|
-
name: string;
|
|
372
|
-
ignored_files: string[];
|
|
373
|
-
checksum: Nullable<string>;
|
|
374
|
-
bytes: number;
|
|
375
|
-
created_at: string;
|
|
376
|
-
completed_at: Nullable<string>;
|
|
377
|
-
};
|
|
378
|
-
|
|
379
482
|
declare class ServerBackups {
|
|
380
483
|
private readonly r;
|
|
381
484
|
private readonly id;
|
|
382
485
|
constructor(requester: AxiosInstance, id: string);
|
|
383
|
-
list: (page?: number) => Promise<ServerBackup[]>;
|
|
486
|
+
list: (page?: number) => Promise<ServerBackup$1[]>;
|
|
384
487
|
create: (args: {
|
|
385
488
|
name?: string;
|
|
386
489
|
is_locked: boolean;
|
|
387
490
|
ignored_files: string[];
|
|
388
|
-
}) => Promise<ServerBackup>;
|
|
389
|
-
info: (backup_uuid: string) => Promise<ServerBackup>;
|
|
491
|
+
}) => Promise<ServerBackup$1>;
|
|
492
|
+
info: (backup_uuid: string) => Promise<ServerBackup$1>;
|
|
390
493
|
downloadGetUrl: (backup_uuid: string) => Promise<string>;
|
|
391
494
|
download: (backup_uuid: string) => Promise<ArrayBuffer>;
|
|
392
495
|
delete: (backup_uuid: string) => Promise<void>;
|
|
393
496
|
}
|
|
394
497
|
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
rules: string;
|
|
403
|
-
};
|
|
404
|
-
type StartupMeta = {
|
|
405
|
-
startup_command: string;
|
|
406
|
-
raw_startup_command: string;
|
|
407
|
-
};
|
|
408
|
-
|
|
409
|
-
declare class ServerStartup {
|
|
410
|
-
private readonly r;
|
|
411
|
-
private readonly id;
|
|
412
|
-
constructor(requester: AxiosInstance, id: string);
|
|
413
|
-
list: () => Promise<CustomListResponse<StartupParams, StartupMeta>>;
|
|
414
|
-
set: (key: string, value: string) => Promise<StartupParams>;
|
|
415
|
-
}
|
|
416
|
-
|
|
417
|
-
declare class ServerSettings {
|
|
418
|
-
private readonly r;
|
|
419
|
-
private readonly id;
|
|
420
|
-
constructor(requester: AxiosInstance, id: string);
|
|
421
|
-
rename: (name: string) => Promise<void>;
|
|
422
|
-
updateDescription: (description: Nullable<string>) => Promise<void>;
|
|
423
|
-
reinstall: () => Promise<void>;
|
|
424
|
-
changeDockerImage: (image: string) => Promise<void>;
|
|
425
|
-
}
|
|
426
|
-
|
|
427
|
-
/**
|
|
428
|
-
* Source: https://github.com/pterodactyl/panel/blob/1.0-develop/resources/scripts/components/server/events.ts
|
|
429
|
-
*/
|
|
430
|
-
declare enum SOCKET_EVENT {
|
|
431
|
-
AUTH_SUCCESS = "auth success",
|
|
432
|
-
DAEMON_MESSAGE = "daemon message",
|
|
433
|
-
DAEMON_ERROR = "daemon error",
|
|
434
|
-
INSTALL_OUTPUT = "install output",
|
|
435
|
-
INSTALL_STARTED = "install started",
|
|
436
|
-
INSTALL_COMPLETED = "install completed",
|
|
437
|
-
CONSOLE_OUTPUT = "console output",
|
|
438
|
-
STATUS = "status",
|
|
439
|
-
STATS = "stats",
|
|
440
|
-
TRANSFER_LOGS = "transfer logs",
|
|
441
|
-
TRANSFER_STATUS = "transfer status",
|
|
442
|
-
BACKUP_COMPLETED = "backup completed",
|
|
443
|
-
BACKUP_RESTORE_COMPLETED = "backup restore completed",
|
|
444
|
-
TOKEN_EXPIRING = "token expiring",
|
|
445
|
-
TOKEN_EXPIRED = "token expired",
|
|
446
|
-
JWT_ERROR = "jwt error"
|
|
447
|
-
}
|
|
448
|
-
type BackupCompletedJson = {
|
|
449
|
-
checksum: string;
|
|
450
|
-
checksum_type: 'sha1';
|
|
451
|
-
file_size: number;
|
|
452
|
-
is_successful: boolean;
|
|
453
|
-
uuid: string;
|
|
454
|
-
};
|
|
455
|
-
type PowerState = 'starting' | 'stopping' | 'running' | 'offline';
|
|
456
|
-
type StatsWsJson = {
|
|
457
|
-
memory_bytes: number;
|
|
458
|
-
memory_limit_bytes: number;
|
|
459
|
-
cpu_absolute: number;
|
|
460
|
-
network: {
|
|
461
|
-
rx_bytes: number;
|
|
462
|
-
tx_bytes: number;
|
|
463
|
-
};
|
|
464
|
-
state: PowerState;
|
|
465
|
-
uptime: number;
|
|
466
|
-
disk_bytes: number;
|
|
467
|
-
};
|
|
468
|
-
|
|
469
|
-
type ServerSignalOption = 'start' | 'stop' | 'restart' | 'kill';
|
|
498
|
+
declare class ServerStartup {
|
|
499
|
+
private readonly r;
|
|
500
|
+
private readonly id;
|
|
501
|
+
constructor(requester: AxiosInstance, id: string);
|
|
502
|
+
list: () => Promise<CustomListResponse<StartupParams, StartupMeta>>;
|
|
503
|
+
set: (key: string, value: string) => Promise<StartupParams>;
|
|
504
|
+
}
|
|
470
505
|
|
|
471
|
-
|
|
472
|
-
[SOCKET_EVENT.AUTH_SUCCESS]: undefined;
|
|
473
|
-
[SOCKET_EVENT.STATUS]: PowerState;
|
|
474
|
-
[SOCKET_EVENT.CONSOLE_OUTPUT]: string;
|
|
475
|
-
[SOCKET_EVENT.STATS]: StatsWsJson;
|
|
476
|
-
[SOCKET_EVENT.DAEMON_ERROR]: undefined;
|
|
477
|
-
[SOCKET_EVENT.DAEMON_MESSAGE]: string;
|
|
478
|
-
[SOCKET_EVENT.INSTALL_OUTPUT]: string;
|
|
479
|
-
[SOCKET_EVENT.INSTALL_STARTED]: undefined;
|
|
480
|
-
[SOCKET_EVENT.INSTALL_COMPLETED]: undefined;
|
|
481
|
-
[SOCKET_EVENT.TRANSFER_LOGS]: string;
|
|
482
|
-
[SOCKET_EVENT.TRANSFER_STATUS]: string;
|
|
483
|
-
[SOCKET_EVENT.BACKUP_COMPLETED]: BackupCompletedJson;
|
|
484
|
-
[SOCKET_EVENT.BACKUP_RESTORE_COMPLETED]: undefined;
|
|
485
|
-
[SOCKET_EVENT.TOKEN_EXPIRING]: undefined;
|
|
486
|
-
[SOCKET_EVENT.TOKEN_EXPIRED]: undefined;
|
|
487
|
-
[SOCKET_EVENT.JWT_ERROR]: string;
|
|
488
|
-
};
|
|
489
|
-
type Listener<E extends SOCKET_EVENT> = SocketEventPayloadMap[E] extends undefined ? () => void : (payload: SocketEventPayloadMap[E]) => void;
|
|
490
|
-
type CloseEventLike = Parameters<NonNullable<WebSocket["onclose"]>>[0];
|
|
491
|
-
type ErrorEventLike = Parameters<NonNullable<WebSocket["onerror"]>>[0];
|
|
492
|
-
declare class ServerWebsocket {
|
|
506
|
+
declare class ServerSettings {
|
|
493
507
|
private readonly r;
|
|
494
|
-
private readonly
|
|
495
|
-
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
private detachMessageListener?;
|
|
501
|
-
constructor(requester: AxiosInstance, id: string, stripColors?: boolean);
|
|
502
|
-
on<E extends SOCKET_EVENT>(event: E, listener: Listener<E>): () => void;
|
|
503
|
-
deregister<E extends SOCKET_EVENT>(event: E, listener: Listener<E>): void;
|
|
504
|
-
private emit;
|
|
505
|
-
connect(resumable?: boolean, debugLogging?: boolean): Promise<void>;
|
|
506
|
-
onSocketDisconnect(handler: (event: CloseEventLike) => void): void;
|
|
507
|
-
onSocketError(handler: (event: ErrorEventLike) => void): void;
|
|
508
|
-
makeResumable(disconnectsToo: boolean): void;
|
|
509
|
-
private attachMessageListener;
|
|
510
|
-
private handleIncomingMessage;
|
|
511
|
-
private parseMessage;
|
|
512
|
-
private normalisePayload;
|
|
513
|
-
private dispatchMessage;
|
|
514
|
-
private refreshCredentials;
|
|
515
|
-
private authenticate;
|
|
516
|
-
disconnect(): void;
|
|
517
|
-
requestStats(): void;
|
|
518
|
-
requestLogs(): void;
|
|
519
|
-
private send;
|
|
520
|
-
getStats(): Promise<StatsWsJson>;
|
|
521
|
-
getLogs(): Promise<string[]>;
|
|
522
|
-
sendPoweraction(action: ServerSignalOption): void;
|
|
523
|
-
sendCommand(cmd: string): void;
|
|
508
|
+
private readonly id;
|
|
509
|
+
constructor(requester: AxiosInstance, id: string);
|
|
510
|
+
rename: (name: string) => Promise<void>;
|
|
511
|
+
updateDescription: (description: Nullable<string>) => Promise<void>;
|
|
512
|
+
reinstall: () => Promise<void>;
|
|
513
|
+
changeDockerImage: (image: string) => Promise<void>;
|
|
524
514
|
}
|
|
525
515
|
|
|
526
516
|
declare class ServerActivity {
|
|
@@ -544,7 +534,7 @@ declare class ServerClient {
|
|
|
544
534
|
variables: ServerStartup;
|
|
545
535
|
settings: ServerSettings;
|
|
546
536
|
constructor(requester: AxiosInstance, id: string);
|
|
547
|
-
info: (include?: ("egg" | "subusers")[]) => Promise<Server>;
|
|
537
|
+
info: (include?: ("egg" | "subusers")[]) => Promise<Server$1>;
|
|
548
538
|
websocket: (stripColors?: boolean) => ServerWebsocket;
|
|
549
539
|
resources: () => Promise<ServerStats>;
|
|
550
540
|
command: (command: string) => Promise<void>;
|
|
@@ -552,1090 +542,292 @@ declare class ServerClient {
|
|
|
552
542
|
}
|
|
553
543
|
|
|
554
544
|
declare class Client$1 {
|
|
555
|
-
account: Account;
|
|
545
|
+
account: Account$1;
|
|
556
546
|
private readonly r;
|
|
557
547
|
constructor(requester: AxiosInstance);
|
|
558
548
|
get $r(): AxiosInstance;
|
|
559
549
|
listPermissions: () => Promise<Record<string, Permission>>;
|
|
560
|
-
listServers: (type?: "accessible" | "mine" | "admin" | "admin-all", page?: number, per_page?: number, include?: ("egg" | "subusers")[]) => Promise<Server[]>;
|
|
550
|
+
listServers: (type?: "accessible" | "mine" | "admin" | "admin-all", page?: number, per_page?: number, include?: ("egg" | "subusers")[]) => Promise<Server$1[]>;
|
|
561
551
|
server: (uuid: string) => ServerClient;
|
|
562
552
|
}
|
|
563
553
|
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
|
|
571
|
-
|
|
572
|
-
|
|
573
|
-
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
limits: ServerLimits;
|
|
585
|
-
feature_limits: FeatureLimits;
|
|
586
|
-
user: number;
|
|
587
|
-
node: number;
|
|
588
|
-
allocation: number;
|
|
589
|
-
egg: number;
|
|
590
|
-
container: Container;
|
|
591
|
-
created_at: string;
|
|
592
|
-
updated_at: Nullable<string>;
|
|
593
|
-
};
|
|
594
|
-
|
|
595
|
-
type ApplicationUser = {
|
|
596
|
-
id: number;
|
|
597
|
-
external_id: Nullable<string>;
|
|
598
|
-
uuid: string;
|
|
599
|
-
username: string;
|
|
600
|
-
email: string;
|
|
601
|
-
language: string;
|
|
602
|
-
root_admin: string;
|
|
603
|
-
"2fa_enabled": boolean;
|
|
604
|
-
"2fa": boolean;
|
|
605
|
-
created_at: string;
|
|
606
|
-
updated_at: Nullable<string>;
|
|
607
|
-
relationships?: {
|
|
608
|
-
servers: GenericListResponse<GenericResponse<ApplicationServer>>;
|
|
609
|
-
};
|
|
610
|
-
};
|
|
611
|
-
type ApplicationUserApiKey = {
|
|
612
|
-
id: number;
|
|
613
|
-
user_id: number;
|
|
614
|
-
key_type: 1;
|
|
615
|
-
identifier: string;
|
|
616
|
-
memo: string;
|
|
617
|
-
allowed_ips: Array<string>;
|
|
618
|
-
permissions: [];
|
|
619
|
-
last_used_at: Nullable<string>;
|
|
620
|
-
expires_at: Nullable<string>;
|
|
621
|
-
created_at: string;
|
|
622
|
-
updated_at: string;
|
|
623
|
-
};
|
|
624
|
-
|
|
625
|
-
declare class Users {
|
|
626
|
-
private readonly r;
|
|
627
|
-
constructor(requester: AxiosInstance);
|
|
628
|
-
list: (opts: ListType, page?: number) => Promise<ApplicationUser[]>;
|
|
629
|
-
info: (id: number, { include }: {
|
|
630
|
-
include?: ("servers")[];
|
|
631
|
-
}) => Promise<ApplicationUser>;
|
|
632
|
-
infoByExternal: (external_id: string, { include }: {
|
|
633
|
-
include?: ("servers")[];
|
|
634
|
-
}) => Promise<ApplicationUser>;
|
|
635
|
-
create: (user: z.infer<typeof CreateSchema>) => Promise<ApplicationUser>;
|
|
636
|
-
update: (id: number, user: z.infer<typeof CreateSchema>) => Promise<ApplicationUser>;
|
|
637
|
-
delete: (id: number) => Promise<void>;
|
|
638
|
-
addRoles: (id: number, roles: number[]) => Promise<void>;
|
|
639
|
-
removeRoles: (id: number, roles: number[]) => Promise<void>;
|
|
640
|
-
apiKeys: {
|
|
641
|
-
list: (id: number) => Promise<ApplicationUserApiKey[]>;
|
|
642
|
-
create: (id: number, description: string, allowed_ips?: string[]) => Promise<ApplicationUserApiKey & {
|
|
643
|
-
secret_token: string;
|
|
644
|
-
}>;
|
|
645
|
-
delete: (id: number, identifier: string) => Promise<void>;
|
|
646
|
-
};
|
|
647
|
-
}
|
|
648
|
-
type ListType = {
|
|
649
|
-
include?: ("servers")[];
|
|
650
|
-
filters?: ListFilters;
|
|
651
|
-
sort?: ListSort;
|
|
652
|
-
};
|
|
653
|
-
type ListFilters = {
|
|
654
|
-
[key in "email" | "uuid" | "username" | "external_id"]: string;
|
|
655
|
-
};
|
|
656
|
-
type ListSort = ExactlyOneKey<"id" | "uuid", "asc" | "desc">;
|
|
657
|
-
declare const CreateSchema: z.ZodObject<{
|
|
658
|
-
email: z.ZodEmail;
|
|
659
|
-
external_id: z.ZodOptional<z.ZodString>;
|
|
660
|
-
username: z.ZodString;
|
|
661
|
-
password: z.ZodOptional<z.ZodString>;
|
|
662
|
-
language: z.ZodEnum<{
|
|
663
|
-
id: "id";
|
|
664
|
-
af: "af";
|
|
665
|
-
ak: "ak";
|
|
666
|
-
am: "am";
|
|
667
|
-
ar: "ar";
|
|
668
|
-
as: "as";
|
|
669
|
-
az: "az";
|
|
670
|
-
be: "be";
|
|
671
|
-
bg: "bg";
|
|
672
|
-
bm: "bm";
|
|
673
|
-
bn: "bn";
|
|
674
|
-
bo: "bo";
|
|
675
|
-
br: "br";
|
|
676
|
-
bs: "bs";
|
|
677
|
-
ca: "ca";
|
|
678
|
-
ce: "ce";
|
|
679
|
-
cs: "cs";
|
|
680
|
-
cv: "cv";
|
|
681
|
-
cy: "cy";
|
|
682
|
-
da: "da";
|
|
683
|
-
de: "de";
|
|
684
|
-
dz: "dz";
|
|
685
|
-
ee: "ee";
|
|
686
|
-
el: "el";
|
|
687
|
-
en: "en";
|
|
688
|
-
eo: "eo";
|
|
689
|
-
es: "es";
|
|
690
|
-
et: "et";
|
|
691
|
-
eu: "eu";
|
|
692
|
-
fa: "fa";
|
|
693
|
-
ff: "ff";
|
|
694
|
-
fi: "fi";
|
|
695
|
-
fo: "fo";
|
|
696
|
-
fr: "fr";
|
|
697
|
-
fy: "fy";
|
|
698
|
-
ga: "ga";
|
|
699
|
-
gd: "gd";
|
|
700
|
-
gl: "gl";
|
|
701
|
-
gu: "gu";
|
|
702
|
-
gv: "gv";
|
|
703
|
-
ha: "ha";
|
|
704
|
-
he: "he";
|
|
705
|
-
hi: "hi";
|
|
706
|
-
hr: "hr";
|
|
707
|
-
hu: "hu";
|
|
708
|
-
hy: "hy";
|
|
709
|
-
ia: "ia";
|
|
710
|
-
ig: "ig";
|
|
711
|
-
ii: "ii";
|
|
712
|
-
is: "is";
|
|
713
|
-
it: "it";
|
|
714
|
-
ja: "ja";
|
|
715
|
-
jv: "jv";
|
|
716
|
-
ka: "ka";
|
|
717
|
-
ki: "ki";
|
|
718
|
-
kk: "kk";
|
|
719
|
-
kl: "kl";
|
|
720
|
-
km: "km";
|
|
721
|
-
kn: "kn";
|
|
722
|
-
ko: "ko";
|
|
723
|
-
ks: "ks";
|
|
724
|
-
ku: "ku";
|
|
725
|
-
kw: "kw";
|
|
726
|
-
ky: "ky";
|
|
727
|
-
lb: "lb";
|
|
728
|
-
lg: "lg";
|
|
729
|
-
ln: "ln";
|
|
730
|
-
lo: "lo";
|
|
731
|
-
lt: "lt";
|
|
732
|
-
lu: "lu";
|
|
733
|
-
lv: "lv";
|
|
734
|
-
mg: "mg";
|
|
735
|
-
mi: "mi";
|
|
736
|
-
mk: "mk";
|
|
737
|
-
ml: "ml";
|
|
738
|
-
mn: "mn";
|
|
739
|
-
mr: "mr";
|
|
740
|
-
ms: "ms";
|
|
741
|
-
mt: "mt";
|
|
742
|
-
my: "my";
|
|
743
|
-
nb: "nb";
|
|
744
|
-
nd: "nd";
|
|
745
|
-
ne: "ne";
|
|
746
|
-
nl: "nl";
|
|
747
|
-
nn: "nn";
|
|
748
|
-
no: "no";
|
|
749
|
-
om: "om";
|
|
750
|
-
or: "or";
|
|
751
|
-
os: "os";
|
|
752
|
-
pa: "pa";
|
|
753
|
-
pl: "pl";
|
|
754
|
-
ps: "ps";
|
|
755
|
-
pt: "pt";
|
|
756
|
-
qu: "qu";
|
|
757
|
-
rm: "rm";
|
|
758
|
-
rn: "rn";
|
|
759
|
-
ro: "ro";
|
|
760
|
-
ru: "ru";
|
|
761
|
-
rw: "rw";
|
|
762
|
-
sa: "sa";
|
|
763
|
-
sc: "sc";
|
|
764
|
-
sd: "sd";
|
|
765
|
-
se: "se";
|
|
766
|
-
sg: "sg";
|
|
767
|
-
si: "si";
|
|
768
|
-
sk: "sk";
|
|
769
|
-
sl: "sl";
|
|
770
|
-
sn: "sn";
|
|
771
|
-
so: "so";
|
|
772
|
-
sq: "sq";
|
|
773
|
-
sr: "sr";
|
|
774
|
-
su: "su";
|
|
775
|
-
sv: "sv";
|
|
776
|
-
sw: "sw";
|
|
777
|
-
ta: "ta";
|
|
778
|
-
te: "te";
|
|
779
|
-
tg: "tg";
|
|
780
|
-
th: "th";
|
|
781
|
-
ti: "ti";
|
|
782
|
-
tk: "tk";
|
|
783
|
-
to: "to";
|
|
784
|
-
tr: "tr";
|
|
785
|
-
tt: "tt";
|
|
786
|
-
ug: "ug";
|
|
787
|
-
uk: "uk";
|
|
788
|
-
ur: "ur";
|
|
789
|
-
uz: "uz";
|
|
790
|
-
vi: "vi";
|
|
791
|
-
wo: "wo";
|
|
792
|
-
xh: "xh";
|
|
793
|
-
yi: "yi";
|
|
794
|
-
yo: "yo";
|
|
795
|
-
zh: "zh";
|
|
796
|
-
zu: "zu";
|
|
554
|
+
declare class Account {
|
|
555
|
+
private readonly client;
|
|
556
|
+
readonly uuid: string;
|
|
557
|
+
readonly username: string;
|
|
558
|
+
private $email;
|
|
559
|
+
get email(): string;
|
|
560
|
+
readonly language: string;
|
|
561
|
+
readonly image: string;
|
|
562
|
+
readonly admin: boolean;
|
|
563
|
+
readonly root_admin: boolean;
|
|
564
|
+
private $has2faEnabled;
|
|
565
|
+
get has2faEnabled(): boolean;
|
|
566
|
+
readonly createdAt: Date;
|
|
567
|
+
readonly updatedAt: Date;
|
|
568
|
+
constructor(client: Client$1, user: User);
|
|
569
|
+
updateEmail: (newEmail: string, password: string) => Promise<void>;
|
|
570
|
+
updatePassword: (newPassword: string) => Promise<void>;
|
|
571
|
+
listApiKeys: () => Promise<APIKey[]>;
|
|
572
|
+
createApiKey: (description: string, allowed_ips?: string[]) => Promise<APIKey & {
|
|
573
|
+
secret_token: string;
|
|
797
574
|
}>;
|
|
798
|
-
|
|
799
|
-
|
|
800
|
-
|
|
801
|
-
|
|
802
|
-
|
|
803
|
-
|
|
804
|
-
"Africa/Bamako": "Africa/Bamako";
|
|
805
|
-
"Africa/Bangui": "Africa/Bangui";
|
|
806
|
-
"Africa/Banjul": "Africa/Banjul";
|
|
807
|
-
"Africa/Bissau": "Africa/Bissau";
|
|
808
|
-
"Africa/Blantyre": "Africa/Blantyre";
|
|
809
|
-
"Africa/Brazzaville": "Africa/Brazzaville";
|
|
810
|
-
"Africa/Bujumbura": "Africa/Bujumbura";
|
|
811
|
-
"Africa/Cairo": "Africa/Cairo";
|
|
812
|
-
"Africa/Casablanca": "Africa/Casablanca";
|
|
813
|
-
"Africa/Ceuta": "Africa/Ceuta";
|
|
814
|
-
"Africa/Conakry": "Africa/Conakry";
|
|
815
|
-
"Africa/Dakar": "Africa/Dakar";
|
|
816
|
-
"Africa/Dar_es_Salaam": "Africa/Dar_es_Salaam";
|
|
817
|
-
"Africa/Djibouti": "Africa/Djibouti";
|
|
818
|
-
"Africa/Douala": "Africa/Douala";
|
|
819
|
-
"Africa/El_Aaiun": "Africa/El_Aaiun";
|
|
820
|
-
"Africa/Freetown": "Africa/Freetown";
|
|
821
|
-
"Africa/Gaborone": "Africa/Gaborone";
|
|
822
|
-
"Africa/Harare": "Africa/Harare";
|
|
823
|
-
"Africa/Johannesburg": "Africa/Johannesburg";
|
|
824
|
-
"Africa/Juba": "Africa/Juba";
|
|
825
|
-
"Africa/Kampala": "Africa/Kampala";
|
|
826
|
-
"Africa/Khartoum": "Africa/Khartoum";
|
|
827
|
-
"Africa/Kigali": "Africa/Kigali";
|
|
828
|
-
"Africa/Kinshasa": "Africa/Kinshasa";
|
|
829
|
-
"Africa/Lagos": "Africa/Lagos";
|
|
830
|
-
"Africa/Libreville": "Africa/Libreville";
|
|
831
|
-
"Africa/Lome": "Africa/Lome";
|
|
832
|
-
"Africa/Luanda": "Africa/Luanda";
|
|
833
|
-
"Africa/Lubumbashi": "Africa/Lubumbashi";
|
|
834
|
-
"Africa/Lusaka": "Africa/Lusaka";
|
|
835
|
-
"Africa/Malabo": "Africa/Malabo";
|
|
836
|
-
"Africa/Maputo": "Africa/Maputo";
|
|
837
|
-
"Africa/Maseru": "Africa/Maseru";
|
|
838
|
-
"Africa/Mbabane": "Africa/Mbabane";
|
|
839
|
-
"Africa/Mogadishu": "Africa/Mogadishu";
|
|
840
|
-
"Africa/Monrovia": "Africa/Monrovia";
|
|
841
|
-
"Africa/Nairobi": "Africa/Nairobi";
|
|
842
|
-
"Africa/Ndjamena": "Africa/Ndjamena";
|
|
843
|
-
"Africa/Niamey": "Africa/Niamey";
|
|
844
|
-
"Africa/Nouakchott": "Africa/Nouakchott";
|
|
845
|
-
"Africa/Ouagadougou": "Africa/Ouagadougou";
|
|
846
|
-
"Africa/Porto-Novo": "Africa/Porto-Novo";
|
|
847
|
-
"Africa/Sao_Tome": "Africa/Sao_Tome";
|
|
848
|
-
"Africa/Tripoli": "Africa/Tripoli";
|
|
849
|
-
"Africa/Tunis": "Africa/Tunis";
|
|
850
|
-
"Africa/Windhoek": "Africa/Windhoek";
|
|
851
|
-
"America/Adak": "America/Adak";
|
|
852
|
-
"America/Anchorage": "America/Anchorage";
|
|
853
|
-
"America/Anguilla": "America/Anguilla";
|
|
854
|
-
"America/Antigua": "America/Antigua";
|
|
855
|
-
"America/Araguaina": "America/Araguaina";
|
|
856
|
-
"America/Argentina/Buenos_Aires": "America/Argentina/Buenos_Aires";
|
|
857
|
-
"America/Argentina/Catamarca": "America/Argentina/Catamarca";
|
|
858
|
-
"America/Argentina/Cordoba": "America/Argentina/Cordoba";
|
|
859
|
-
"America/Argentina/Jujuy": "America/Argentina/Jujuy";
|
|
860
|
-
"America/Argentina/La_Rioja": "America/Argentina/La_Rioja";
|
|
861
|
-
"America/Argentina/Mendoza": "America/Argentina/Mendoza";
|
|
862
|
-
"America/Argentina/Rio_Gallegos": "America/Argentina/Rio_Gallegos";
|
|
863
|
-
"America/Argentina/Salta": "America/Argentina/Salta";
|
|
864
|
-
"America/Argentina/San_Juan": "America/Argentina/San_Juan";
|
|
865
|
-
"America/Argentina/San_Luis": "America/Argentina/San_Luis";
|
|
866
|
-
"America/Argentina/Tucuman": "America/Argentina/Tucuman";
|
|
867
|
-
"America/Argentina/Ushuaia": "America/Argentina/Ushuaia";
|
|
868
|
-
"America/Aruba": "America/Aruba";
|
|
869
|
-
"America/Asuncion": "America/Asuncion";
|
|
870
|
-
"America/Atikokan": "America/Atikokan";
|
|
871
|
-
"America/Bahia": "America/Bahia";
|
|
872
|
-
"America/Bahia_Banderas": "America/Bahia_Banderas";
|
|
873
|
-
"America/Barbados": "America/Barbados";
|
|
874
|
-
"America/Belem": "America/Belem";
|
|
875
|
-
"America/Belize": "America/Belize";
|
|
876
|
-
"America/Blanc-Sablon": "America/Blanc-Sablon";
|
|
877
|
-
"America/Boa_Vista": "America/Boa_Vista";
|
|
878
|
-
"America/Bogota": "America/Bogota";
|
|
879
|
-
"America/Boise": "America/Boise";
|
|
880
|
-
"America/Cambridge_Bay": "America/Cambridge_Bay";
|
|
881
|
-
"America/Campo_Grande": "America/Campo_Grande";
|
|
882
|
-
"America/Cancun": "America/Cancun";
|
|
883
|
-
"America/Caracas": "America/Caracas";
|
|
884
|
-
"America/Cayenne": "America/Cayenne";
|
|
885
|
-
"America/Cayman": "America/Cayman";
|
|
886
|
-
"America/Chicago": "America/Chicago";
|
|
887
|
-
"America/Chihuahua": "America/Chihuahua";
|
|
888
|
-
"America/Ciudad_Juarez": "America/Ciudad_Juarez";
|
|
889
|
-
"America/Costa_Rica": "America/Costa_Rica";
|
|
890
|
-
"America/Coyhaique": "America/Coyhaique";
|
|
891
|
-
"America/Creston": "America/Creston";
|
|
892
|
-
"America/Cuiaba": "America/Cuiaba";
|
|
893
|
-
"America/Curacao": "America/Curacao";
|
|
894
|
-
"America/Danmarkshavn": "America/Danmarkshavn";
|
|
895
|
-
"America/Dawson": "America/Dawson";
|
|
896
|
-
"America/Dawson_Creek": "America/Dawson_Creek";
|
|
897
|
-
"America/Denver": "America/Denver";
|
|
898
|
-
"America/Detroit": "America/Detroit";
|
|
899
|
-
"America/Dominica": "America/Dominica";
|
|
900
|
-
"America/Edmonton": "America/Edmonton";
|
|
901
|
-
"America/Eirunepe": "America/Eirunepe";
|
|
902
|
-
"America/El_Salvador": "America/El_Salvador";
|
|
903
|
-
"America/Fort_Nelson": "America/Fort_Nelson";
|
|
904
|
-
"America/Fortaleza": "America/Fortaleza";
|
|
905
|
-
"America/Glace_Bay": "America/Glace_Bay";
|
|
906
|
-
"America/Goose_Bay": "America/Goose_Bay";
|
|
907
|
-
"America/Grand_Turk": "America/Grand_Turk";
|
|
908
|
-
"America/Grenada": "America/Grenada";
|
|
909
|
-
"America/Guadeloupe": "America/Guadeloupe";
|
|
910
|
-
"America/Guatemala": "America/Guatemala";
|
|
911
|
-
"America/Guayaquil": "America/Guayaquil";
|
|
912
|
-
"America/Guyana": "America/Guyana";
|
|
913
|
-
"America/Halifax": "America/Halifax";
|
|
914
|
-
"America/Havana": "America/Havana";
|
|
915
|
-
"America/Hermosillo": "America/Hermosillo";
|
|
916
|
-
"America/Indiana/Indianapolis": "America/Indiana/Indianapolis";
|
|
917
|
-
"America/Indiana/Knox": "America/Indiana/Knox";
|
|
918
|
-
"America/Indiana/Marengo": "America/Indiana/Marengo";
|
|
919
|
-
"America/Indiana/Petersburg": "America/Indiana/Petersburg";
|
|
920
|
-
"America/Indiana/Tell_City": "America/Indiana/Tell_City";
|
|
921
|
-
"America/Indiana/Vevay": "America/Indiana/Vevay";
|
|
922
|
-
"America/Indiana/Vincennes": "America/Indiana/Vincennes";
|
|
923
|
-
"America/Indiana/Winamac": "America/Indiana/Winamac";
|
|
924
|
-
"America/Inuvik": "America/Inuvik";
|
|
925
|
-
"America/Iqaluit": "America/Iqaluit";
|
|
926
|
-
"America/Jamaica": "America/Jamaica";
|
|
927
|
-
"America/Juneau": "America/Juneau";
|
|
928
|
-
"America/Kentucky/Louisville": "America/Kentucky/Louisville";
|
|
929
|
-
"America/Kentucky/Monticello": "America/Kentucky/Monticello";
|
|
930
|
-
"America/Kralendijk": "America/Kralendijk";
|
|
931
|
-
"America/La_Paz": "America/La_Paz";
|
|
932
|
-
"America/Lima": "America/Lima";
|
|
933
|
-
"America/Los_Angeles": "America/Los_Angeles";
|
|
934
|
-
"America/Lower_Princes": "America/Lower_Princes";
|
|
935
|
-
"America/Maceio": "America/Maceio";
|
|
936
|
-
"America/Managua": "America/Managua";
|
|
937
|
-
"America/Manaus": "America/Manaus";
|
|
938
|
-
"America/Marigot": "America/Marigot";
|
|
939
|
-
"America/Martinique": "America/Martinique";
|
|
940
|
-
"America/Matamoros": "America/Matamoros";
|
|
941
|
-
"America/Mazatlan": "America/Mazatlan";
|
|
942
|
-
"America/Menominee": "America/Menominee";
|
|
943
|
-
"America/Merida": "America/Merida";
|
|
944
|
-
"America/Metlakatla": "America/Metlakatla";
|
|
945
|
-
"America/Mexico_City": "America/Mexico_City";
|
|
946
|
-
"America/Miquelon": "America/Miquelon";
|
|
947
|
-
"America/Moncton": "America/Moncton";
|
|
948
|
-
"America/Monterrey": "America/Monterrey";
|
|
949
|
-
"America/Montevideo": "America/Montevideo";
|
|
950
|
-
"America/Montserrat": "America/Montserrat";
|
|
951
|
-
"America/Nassau": "America/Nassau";
|
|
952
|
-
"America/New_York": "America/New_York";
|
|
953
|
-
"America/Nome": "America/Nome";
|
|
954
|
-
"America/Noronha": "America/Noronha";
|
|
955
|
-
"America/North_Dakota/Beulah": "America/North_Dakota/Beulah";
|
|
956
|
-
"America/North_Dakota/Center": "America/North_Dakota/Center";
|
|
957
|
-
"America/North_Dakota/New_Salem": "America/North_Dakota/New_Salem";
|
|
958
|
-
"America/Nuuk": "America/Nuuk";
|
|
959
|
-
"America/Ojinaga": "America/Ojinaga";
|
|
960
|
-
"America/Panama": "America/Panama";
|
|
961
|
-
"America/Paramaribo": "America/Paramaribo";
|
|
962
|
-
"America/Phoenix": "America/Phoenix";
|
|
963
|
-
"America/Port-au-Prince": "America/Port-au-Prince";
|
|
964
|
-
"America/Port_of_Spain": "America/Port_of_Spain";
|
|
965
|
-
"America/Porto_Velho": "America/Porto_Velho";
|
|
966
|
-
"America/Puerto_Rico": "America/Puerto_Rico";
|
|
967
|
-
"America/Punta_Arenas": "America/Punta_Arenas";
|
|
968
|
-
"America/Rankin_Inlet": "America/Rankin_Inlet";
|
|
969
|
-
"America/Recife": "America/Recife";
|
|
970
|
-
"America/Regina": "America/Regina";
|
|
971
|
-
"America/Resolute": "America/Resolute";
|
|
972
|
-
"America/Rio_Branco": "America/Rio_Branco";
|
|
973
|
-
"America/Santarem": "America/Santarem";
|
|
974
|
-
"America/Santiago": "America/Santiago";
|
|
975
|
-
"America/Santo_Domingo": "America/Santo_Domingo";
|
|
976
|
-
"America/Sao_Paulo": "America/Sao_Paulo";
|
|
977
|
-
"America/Scoresbysund": "America/Scoresbysund";
|
|
978
|
-
"America/Sitka": "America/Sitka";
|
|
979
|
-
"America/St_Barthelemy": "America/St_Barthelemy";
|
|
980
|
-
"America/St_Johns": "America/St_Johns";
|
|
981
|
-
"America/St_Kitts": "America/St_Kitts";
|
|
982
|
-
"America/St_Lucia": "America/St_Lucia";
|
|
983
|
-
"America/St_Thomas": "America/St_Thomas";
|
|
984
|
-
"America/St_Vincent": "America/St_Vincent";
|
|
985
|
-
"America/Swift_Current": "America/Swift_Current";
|
|
986
|
-
"America/Tegucigalpa": "America/Tegucigalpa";
|
|
987
|
-
"America/Thule": "America/Thule";
|
|
988
|
-
"America/Tijuana": "America/Tijuana";
|
|
989
|
-
"America/Toronto": "America/Toronto";
|
|
990
|
-
"America/Tortola": "America/Tortola";
|
|
991
|
-
"America/Vancouver": "America/Vancouver";
|
|
992
|
-
"America/Whitehorse": "America/Whitehorse";
|
|
993
|
-
"America/Winnipeg": "America/Winnipeg";
|
|
994
|
-
"America/Yakutat": "America/Yakutat";
|
|
995
|
-
"Antarctica/Casey": "Antarctica/Casey";
|
|
996
|
-
"Antarctica/Davis": "Antarctica/Davis";
|
|
997
|
-
"Antarctica/DumontDUrville": "Antarctica/DumontDUrville";
|
|
998
|
-
"Antarctica/Macquarie": "Antarctica/Macquarie";
|
|
999
|
-
"Antarctica/Mawson": "Antarctica/Mawson";
|
|
1000
|
-
"Antarctica/McMurdo": "Antarctica/McMurdo";
|
|
1001
|
-
"Antarctica/Palmer": "Antarctica/Palmer";
|
|
1002
|
-
"Antarctica/Rothera": "Antarctica/Rothera";
|
|
1003
|
-
"Antarctica/Syowa": "Antarctica/Syowa";
|
|
1004
|
-
"Antarctica/Troll": "Antarctica/Troll";
|
|
1005
|
-
"Antarctica/Vostok": "Antarctica/Vostok";
|
|
1006
|
-
"Arctic/Longyearbyen": "Arctic/Longyearbyen";
|
|
1007
|
-
"Asia/Aden": "Asia/Aden";
|
|
1008
|
-
"Asia/Almaty": "Asia/Almaty";
|
|
1009
|
-
"Asia/Amman": "Asia/Amman";
|
|
1010
|
-
"Asia/Anadyr": "Asia/Anadyr";
|
|
1011
|
-
"Asia/Aqtau": "Asia/Aqtau";
|
|
1012
|
-
"Asia/Aqtobe": "Asia/Aqtobe";
|
|
1013
|
-
"Asia/Ashgabat": "Asia/Ashgabat";
|
|
1014
|
-
"Asia/Atyrau": "Asia/Atyrau";
|
|
1015
|
-
"Asia/Baghdad": "Asia/Baghdad";
|
|
1016
|
-
"Asia/Bahrain": "Asia/Bahrain";
|
|
1017
|
-
"Asia/Baku": "Asia/Baku";
|
|
1018
|
-
"Asia/Bangkok": "Asia/Bangkok";
|
|
1019
|
-
"Asia/Barnaul": "Asia/Barnaul";
|
|
1020
|
-
"Asia/Beirut": "Asia/Beirut";
|
|
1021
|
-
"Asia/Bishkek": "Asia/Bishkek";
|
|
1022
|
-
"Asia/Brunei": "Asia/Brunei";
|
|
1023
|
-
"Asia/Chita": "Asia/Chita";
|
|
1024
|
-
"Asia/Colombo": "Asia/Colombo";
|
|
1025
|
-
"Asia/Damascus": "Asia/Damascus";
|
|
1026
|
-
"Asia/Dhaka": "Asia/Dhaka";
|
|
1027
|
-
"Asia/Dili": "Asia/Dili";
|
|
1028
|
-
"Asia/Dubai": "Asia/Dubai";
|
|
1029
|
-
"Asia/Dushanbe": "Asia/Dushanbe";
|
|
1030
|
-
"Asia/Famagusta": "Asia/Famagusta";
|
|
1031
|
-
"Asia/Gaza": "Asia/Gaza";
|
|
1032
|
-
"Asia/Hebron": "Asia/Hebron";
|
|
1033
|
-
"Asia/Ho_Chi_Minh": "Asia/Ho_Chi_Minh";
|
|
1034
|
-
"Asia/Hong_Kong": "Asia/Hong_Kong";
|
|
1035
|
-
"Asia/Hovd": "Asia/Hovd";
|
|
1036
|
-
"Asia/Irkutsk": "Asia/Irkutsk";
|
|
1037
|
-
"Asia/Jakarta": "Asia/Jakarta";
|
|
1038
|
-
"Asia/Jayapura": "Asia/Jayapura";
|
|
1039
|
-
"Asia/Jerusalem": "Asia/Jerusalem";
|
|
1040
|
-
"Asia/Kabul": "Asia/Kabul";
|
|
1041
|
-
"Asia/Kamchatka": "Asia/Kamchatka";
|
|
1042
|
-
"Asia/Karachi": "Asia/Karachi";
|
|
1043
|
-
"Asia/Kathmandu": "Asia/Kathmandu";
|
|
1044
|
-
"Asia/Khandyga": "Asia/Khandyga";
|
|
1045
|
-
"Asia/Kolkata": "Asia/Kolkata";
|
|
1046
|
-
"Asia/Krasnoyarsk": "Asia/Krasnoyarsk";
|
|
1047
|
-
"Asia/Kuala_Lumpur": "Asia/Kuala_Lumpur";
|
|
1048
|
-
"Asia/Kuching": "Asia/Kuching";
|
|
1049
|
-
"Asia/Kuwait": "Asia/Kuwait";
|
|
1050
|
-
"Asia/Macau": "Asia/Macau";
|
|
1051
|
-
"Asia/Magadan": "Asia/Magadan";
|
|
1052
|
-
"Asia/Makassar": "Asia/Makassar";
|
|
1053
|
-
"Asia/Manila": "Asia/Manila";
|
|
1054
|
-
"Asia/Muscat": "Asia/Muscat";
|
|
1055
|
-
"Asia/Nicosia": "Asia/Nicosia";
|
|
1056
|
-
"Asia/Novokuznetsk": "Asia/Novokuznetsk";
|
|
1057
|
-
"Asia/Novosibirsk": "Asia/Novosibirsk";
|
|
1058
|
-
"Asia/Omsk": "Asia/Omsk";
|
|
1059
|
-
"Asia/Oral": "Asia/Oral";
|
|
1060
|
-
"Asia/Phnom_Penh": "Asia/Phnom_Penh";
|
|
1061
|
-
"Asia/Pontianak": "Asia/Pontianak";
|
|
1062
|
-
"Asia/Pyongyang": "Asia/Pyongyang";
|
|
1063
|
-
"Asia/Qatar": "Asia/Qatar";
|
|
1064
|
-
"Asia/Qostanay": "Asia/Qostanay";
|
|
1065
|
-
"Asia/Qyzylorda": "Asia/Qyzylorda";
|
|
1066
|
-
"Asia/Riyadh": "Asia/Riyadh";
|
|
1067
|
-
"Asia/Sakhalin": "Asia/Sakhalin";
|
|
1068
|
-
"Asia/Samarkand": "Asia/Samarkand";
|
|
1069
|
-
"Asia/Seoul": "Asia/Seoul";
|
|
1070
|
-
"Asia/Shanghai": "Asia/Shanghai";
|
|
1071
|
-
"Asia/Singapore": "Asia/Singapore";
|
|
1072
|
-
"Asia/Srednekolymsk": "Asia/Srednekolymsk";
|
|
1073
|
-
"Asia/Taipei": "Asia/Taipei";
|
|
1074
|
-
"Asia/Tashkent": "Asia/Tashkent";
|
|
1075
|
-
"Asia/Tbilisi": "Asia/Tbilisi";
|
|
1076
|
-
"Asia/Tehran": "Asia/Tehran";
|
|
1077
|
-
"Asia/Thimphu": "Asia/Thimphu";
|
|
1078
|
-
"Asia/Tokyo": "Asia/Tokyo";
|
|
1079
|
-
"Asia/Tomsk": "Asia/Tomsk";
|
|
1080
|
-
"Asia/Ulaanbaatar": "Asia/Ulaanbaatar";
|
|
1081
|
-
"Asia/Urumqi": "Asia/Urumqi";
|
|
1082
|
-
"Asia/Ust-Nera": "Asia/Ust-Nera";
|
|
1083
|
-
"Asia/Vientiane": "Asia/Vientiane";
|
|
1084
|
-
"Asia/Vladivostok": "Asia/Vladivostok";
|
|
1085
|
-
"Asia/Yakutsk": "Asia/Yakutsk";
|
|
1086
|
-
"Asia/Yangon": "Asia/Yangon";
|
|
1087
|
-
"Asia/Yekaterinburg": "Asia/Yekaterinburg";
|
|
1088
|
-
"Asia/Yerevan": "Asia/Yerevan";
|
|
1089
|
-
"Atlantic/Azores": "Atlantic/Azores";
|
|
1090
|
-
"Atlantic/Bermuda": "Atlantic/Bermuda";
|
|
1091
|
-
"Atlantic/Canary": "Atlantic/Canary";
|
|
1092
|
-
"Atlantic/Cape_Verde": "Atlantic/Cape_Verde";
|
|
1093
|
-
"Atlantic/Faroe": "Atlantic/Faroe";
|
|
1094
|
-
"Atlantic/Madeira": "Atlantic/Madeira";
|
|
1095
|
-
"Atlantic/Reykjavik": "Atlantic/Reykjavik";
|
|
1096
|
-
"Atlantic/South_Georgia": "Atlantic/South_Georgia";
|
|
1097
|
-
"Atlantic/St_Helena": "Atlantic/St_Helena";
|
|
1098
|
-
"Atlantic/Stanley": "Atlantic/Stanley";
|
|
1099
|
-
"Australia/Adelaide": "Australia/Adelaide";
|
|
1100
|
-
"Australia/Brisbane": "Australia/Brisbane";
|
|
1101
|
-
"Australia/Broken_Hill": "Australia/Broken_Hill";
|
|
1102
|
-
"Australia/Darwin": "Australia/Darwin";
|
|
1103
|
-
"Australia/Eucla": "Australia/Eucla";
|
|
1104
|
-
"Australia/Hobart": "Australia/Hobart";
|
|
1105
|
-
"Australia/Lindeman": "Australia/Lindeman";
|
|
1106
|
-
"Australia/Lord_Howe": "Australia/Lord_Howe";
|
|
1107
|
-
"Australia/Melbourne": "Australia/Melbourne";
|
|
1108
|
-
"Australia/Perth": "Australia/Perth";
|
|
1109
|
-
"Australia/Sydney": "Australia/Sydney";
|
|
1110
|
-
"Europe/Amsterdam": "Europe/Amsterdam";
|
|
1111
|
-
"Europe/Andorra": "Europe/Andorra";
|
|
1112
|
-
"Europe/Astrakhan": "Europe/Astrakhan";
|
|
1113
|
-
"Europe/Athens": "Europe/Athens";
|
|
1114
|
-
"Europe/Belgrade": "Europe/Belgrade";
|
|
1115
|
-
"Europe/Berlin": "Europe/Berlin";
|
|
1116
|
-
"Europe/Bratislava": "Europe/Bratislava";
|
|
1117
|
-
"Europe/Brussels": "Europe/Brussels";
|
|
1118
|
-
"Europe/Bucharest": "Europe/Bucharest";
|
|
1119
|
-
"Europe/Budapest": "Europe/Budapest";
|
|
1120
|
-
"Europe/Busingen": "Europe/Busingen";
|
|
1121
|
-
"Europe/Chisinau": "Europe/Chisinau";
|
|
1122
|
-
"Europe/Copenhagen": "Europe/Copenhagen";
|
|
1123
|
-
"Europe/Dublin": "Europe/Dublin";
|
|
1124
|
-
"Europe/Gibraltar": "Europe/Gibraltar";
|
|
1125
|
-
"Europe/Guernsey": "Europe/Guernsey";
|
|
1126
|
-
"Europe/Helsinki": "Europe/Helsinki";
|
|
1127
|
-
"Europe/Isle_of_Man": "Europe/Isle_of_Man";
|
|
1128
|
-
"Europe/Istanbul": "Europe/Istanbul";
|
|
1129
|
-
"Europe/Jersey": "Europe/Jersey";
|
|
1130
|
-
"Europe/Kaliningrad": "Europe/Kaliningrad";
|
|
1131
|
-
"Europe/Kirov": "Europe/Kirov";
|
|
1132
|
-
"Europe/Kyiv": "Europe/Kyiv";
|
|
1133
|
-
"Europe/Lisbon": "Europe/Lisbon";
|
|
1134
|
-
"Europe/Ljubljana": "Europe/Ljubljana";
|
|
1135
|
-
"Europe/London": "Europe/London";
|
|
1136
|
-
"Europe/Luxembourg": "Europe/Luxembourg";
|
|
1137
|
-
"Europe/Madrid": "Europe/Madrid";
|
|
1138
|
-
"Europe/Malta": "Europe/Malta";
|
|
1139
|
-
"Europe/Mariehamn": "Europe/Mariehamn";
|
|
1140
|
-
"Europe/Minsk": "Europe/Minsk";
|
|
1141
|
-
"Europe/Monaco": "Europe/Monaco";
|
|
1142
|
-
"Europe/Moscow": "Europe/Moscow";
|
|
1143
|
-
"Europe/Oslo": "Europe/Oslo";
|
|
1144
|
-
"Europe/Paris": "Europe/Paris";
|
|
1145
|
-
"Europe/Podgorica": "Europe/Podgorica";
|
|
1146
|
-
"Europe/Prague": "Europe/Prague";
|
|
1147
|
-
"Europe/Riga": "Europe/Riga";
|
|
1148
|
-
"Europe/Rome": "Europe/Rome";
|
|
1149
|
-
"Europe/Samara": "Europe/Samara";
|
|
1150
|
-
"Europe/San_Marino": "Europe/San_Marino";
|
|
1151
|
-
"Europe/Sarajevo": "Europe/Sarajevo";
|
|
1152
|
-
"Europe/Saratov": "Europe/Saratov";
|
|
1153
|
-
"Europe/Simferopol": "Europe/Simferopol";
|
|
1154
|
-
"Europe/Skopje": "Europe/Skopje";
|
|
1155
|
-
"Europe/Sofia": "Europe/Sofia";
|
|
1156
|
-
"Europe/Stockholm": "Europe/Stockholm";
|
|
1157
|
-
"Europe/Tallinn": "Europe/Tallinn";
|
|
1158
|
-
"Europe/Tirane": "Europe/Tirane";
|
|
1159
|
-
"Europe/Ulyanovsk": "Europe/Ulyanovsk";
|
|
1160
|
-
"Europe/Vaduz": "Europe/Vaduz";
|
|
1161
|
-
"Europe/Vatican": "Europe/Vatican";
|
|
1162
|
-
"Europe/Vienna": "Europe/Vienna";
|
|
1163
|
-
"Europe/Vilnius": "Europe/Vilnius";
|
|
1164
|
-
"Europe/Volgograd": "Europe/Volgograd";
|
|
1165
|
-
"Europe/Warsaw": "Europe/Warsaw";
|
|
1166
|
-
"Europe/Zagreb": "Europe/Zagreb";
|
|
1167
|
-
"Europe/Zurich": "Europe/Zurich";
|
|
1168
|
-
"Indian/Antananarivo": "Indian/Antananarivo";
|
|
1169
|
-
"Indian/Chagos": "Indian/Chagos";
|
|
1170
|
-
"Indian/Christmas": "Indian/Christmas";
|
|
1171
|
-
"Indian/Cocos": "Indian/Cocos";
|
|
1172
|
-
"Indian/Comoro": "Indian/Comoro";
|
|
1173
|
-
"Indian/Kerguelen": "Indian/Kerguelen";
|
|
1174
|
-
"Indian/Mahe": "Indian/Mahe";
|
|
1175
|
-
"Indian/Maldives": "Indian/Maldives";
|
|
1176
|
-
"Indian/Mauritius": "Indian/Mauritius";
|
|
1177
|
-
"Indian/Mayotte": "Indian/Mayotte";
|
|
1178
|
-
"Indian/Reunion": "Indian/Reunion";
|
|
1179
|
-
"Pacific/Apia": "Pacific/Apia";
|
|
1180
|
-
"Pacific/Auckland": "Pacific/Auckland";
|
|
1181
|
-
"Pacific/Bougainville": "Pacific/Bougainville";
|
|
1182
|
-
"Pacific/Chatham": "Pacific/Chatham";
|
|
1183
|
-
"Pacific/Chuuk": "Pacific/Chuuk";
|
|
1184
|
-
"Pacific/Easter": "Pacific/Easter";
|
|
1185
|
-
"Pacific/Efate": "Pacific/Efate";
|
|
1186
|
-
"Pacific/Fakaofo": "Pacific/Fakaofo";
|
|
1187
|
-
"Pacific/Fiji": "Pacific/Fiji";
|
|
1188
|
-
"Pacific/Funafuti": "Pacific/Funafuti";
|
|
1189
|
-
"Pacific/Galapagos": "Pacific/Galapagos";
|
|
1190
|
-
"Pacific/Gambier": "Pacific/Gambier";
|
|
1191
|
-
"Pacific/Guadalcanal": "Pacific/Guadalcanal";
|
|
1192
|
-
"Pacific/Guam": "Pacific/Guam";
|
|
1193
|
-
"Pacific/Honolulu": "Pacific/Honolulu";
|
|
1194
|
-
"Pacific/Kanton": "Pacific/Kanton";
|
|
1195
|
-
"Pacific/Kiritimati": "Pacific/Kiritimati";
|
|
1196
|
-
"Pacific/Kosrae": "Pacific/Kosrae";
|
|
1197
|
-
"Pacific/Kwajalein": "Pacific/Kwajalein";
|
|
1198
|
-
"Pacific/Majuro": "Pacific/Majuro";
|
|
1199
|
-
"Pacific/Marquesas": "Pacific/Marquesas";
|
|
1200
|
-
"Pacific/Midway": "Pacific/Midway";
|
|
1201
|
-
"Pacific/Nauru": "Pacific/Nauru";
|
|
1202
|
-
"Pacific/Niue": "Pacific/Niue";
|
|
1203
|
-
"Pacific/Norfolk": "Pacific/Norfolk";
|
|
1204
|
-
"Pacific/Noumea": "Pacific/Noumea";
|
|
1205
|
-
"Pacific/Pago_Pago": "Pacific/Pago_Pago";
|
|
1206
|
-
"Pacific/Palau": "Pacific/Palau";
|
|
1207
|
-
"Pacific/Pitcairn": "Pacific/Pitcairn";
|
|
1208
|
-
"Pacific/Pohnpei": "Pacific/Pohnpei";
|
|
1209
|
-
"Pacific/Port_Moresby": "Pacific/Port_Moresby";
|
|
1210
|
-
"Pacific/Rarotonga": "Pacific/Rarotonga";
|
|
1211
|
-
"Pacific/Saipan": "Pacific/Saipan";
|
|
1212
|
-
"Pacific/Tahiti": "Pacific/Tahiti";
|
|
1213
|
-
"Pacific/Tarawa": "Pacific/Tarawa";
|
|
1214
|
-
"Pacific/Tongatapu": "Pacific/Tongatapu";
|
|
1215
|
-
"Pacific/Wake": "Pacific/Wake";
|
|
1216
|
-
"Pacific/Wallis": "Pacific/Wallis";
|
|
1217
|
-
UTC: "UTC";
|
|
575
|
+
deleteApiKey: (identifier: string) => Promise<void>;
|
|
576
|
+
listSshKeys: () => Promise<SSHKey[]>;
|
|
577
|
+
createSshKey: (name: string, public_key: string) => Promise<SSHKey>;
|
|
578
|
+
deleteSshKey: (fingerprint: string) => Promise<void>;
|
|
579
|
+
get2faQR: () => Promise<{
|
|
580
|
+
image_url_data: string;
|
|
1218
581
|
}>;
|
|
1219
|
-
|
|
1220
|
-
|
|
1221
|
-
|
|
1222
|
-
|
|
1223
|
-
short: string;
|
|
1224
|
-
long: string;
|
|
1225
|
-
created_at: string;
|
|
1226
|
-
updated_at: string | null;
|
|
1227
|
-
};
|
|
1228
|
-
|
|
1229
|
-
type Node$1 = {
|
|
1230
|
-
id: number;
|
|
1231
|
-
uuid: string;
|
|
1232
|
-
public: boolean;
|
|
1233
|
-
name: string;
|
|
1234
|
-
description: Nullable<string>;
|
|
1235
|
-
fqdn: string;
|
|
1236
|
-
scheme: "https" | "http";
|
|
1237
|
-
behind_proxy: boolean;
|
|
1238
|
-
maintenance_mode: boolean;
|
|
1239
|
-
memory: number;
|
|
1240
|
-
memory_overallocate: number;
|
|
1241
|
-
disk: number;
|
|
1242
|
-
disk_overallocate: number;
|
|
1243
|
-
cpu: number;
|
|
1244
|
-
cpu_overallocate: number;
|
|
1245
|
-
upload_size: number;
|
|
1246
|
-
daemon_listen: number;
|
|
1247
|
-
daemon_sftp: number;
|
|
1248
|
-
daemon_sftp_alias: Nullable<string>;
|
|
1249
|
-
daemon_base: string;
|
|
1250
|
-
daemon_connect: number;
|
|
1251
|
-
created_at: string;
|
|
1252
|
-
updated_at: Nullable<string>;
|
|
1253
|
-
tags: string[];
|
|
1254
|
-
allocated_resources: {
|
|
1255
|
-
memory: number;
|
|
1256
|
-
disk: number;
|
|
1257
|
-
cpu: number;
|
|
1258
|
-
};
|
|
1259
|
-
relationships?: {
|
|
1260
|
-
allocations?: GenericListResponse<GenericResponse<Allocation, "allocation">>;
|
|
1261
|
-
location?: GenericResponse<Location, "location">;
|
|
1262
|
-
servers?: GenericListResponse<GenericResponse<ApplicationServer, "server">>;
|
|
1263
|
-
};
|
|
1264
|
-
};
|
|
1265
|
-
type NodeConfiguration = {
|
|
1266
|
-
debug: boolean;
|
|
1267
|
-
uuid: string;
|
|
1268
|
-
token_id: string;
|
|
1269
|
-
token: string;
|
|
1270
|
-
api: {
|
|
1271
|
-
host: string;
|
|
1272
|
-
port: number;
|
|
1273
|
-
upload_limit: number;
|
|
1274
|
-
ssl: {
|
|
1275
|
-
enabled: boolean;
|
|
1276
|
-
cert: string;
|
|
1277
|
-
key: string;
|
|
1278
|
-
};
|
|
1279
|
-
};
|
|
1280
|
-
system: {
|
|
1281
|
-
data: string;
|
|
1282
|
-
sftp: {
|
|
1283
|
-
bind_port: number;
|
|
1284
|
-
};
|
|
1285
|
-
};
|
|
1286
|
-
allowed_mounts: string[];
|
|
1287
|
-
remote: string;
|
|
1288
|
-
};
|
|
1289
|
-
|
|
1290
|
-
type Allocation = {
|
|
1291
|
-
id: number;
|
|
1292
|
-
ip: string;
|
|
1293
|
-
alias: Nullable<string>;
|
|
1294
|
-
port: number;
|
|
1295
|
-
notes: Nullable<string>;
|
|
1296
|
-
assigned: boolean;
|
|
1297
|
-
};
|
|
1298
|
-
type AllocationRel = Allocation & {
|
|
1299
|
-
relationships?: {
|
|
1300
|
-
node?: GenericResponse<Node$1, "node">;
|
|
1301
|
-
server?: GenericResponse<ApplicationServer, "server">;
|
|
1302
|
-
};
|
|
1303
|
-
};
|
|
1304
|
-
|
|
1305
|
-
declare class NodesAllocations {
|
|
1306
|
-
private readonly r;
|
|
1307
|
-
private readonly id;
|
|
1308
|
-
constructor(requester: AxiosInstance, id: number);
|
|
1309
|
-
list: (include?: ("node" | "server")[]) => Promise<AllocationRel[]>;
|
|
1310
|
-
create: (ip: string, ports: string[], alias?: string) => Promise<void>;
|
|
1311
|
-
delete: (alloc_id: number) => Promise<void>;
|
|
582
|
+
enable2fa: (code: string) => Promise<{
|
|
583
|
+
tokens: string[];
|
|
584
|
+
}>;
|
|
585
|
+
disable2fa: (password: string) => Promise<void>;
|
|
1312
586
|
}
|
|
1313
587
|
|
|
1314
|
-
declare class
|
|
1315
|
-
private readonly
|
|
1316
|
-
|
|
1317
|
-
|
|
1318
|
-
|
|
1319
|
-
|
|
1320
|
-
|
|
1321
|
-
|
|
1322
|
-
|
|
1323
|
-
|
|
1324
|
-
|
|
1325
|
-
|
|
1326
|
-
|
|
1327
|
-
|
|
1328
|
-
update: (id: number, node: z.infer<typeof NodeCreateSchema>) => Promise<Node$1>;
|
|
1329
|
-
delete: (id: number) => Promise<void>;
|
|
1330
|
-
allocations: (server_id: number) => NodesAllocations;
|
|
588
|
+
declare class ServerAllocation {
|
|
589
|
+
private readonly client;
|
|
590
|
+
readonly alias: Nullable<string>;
|
|
591
|
+
readonly id: number;
|
|
592
|
+
readonly ip: string;
|
|
593
|
+
private $isDefault;
|
|
594
|
+
get isDefault(): boolean;
|
|
595
|
+
private $notes;
|
|
596
|
+
get notes(): Nullable<string>;
|
|
597
|
+
readonly port: number;
|
|
598
|
+
constructor(client: ServerClient, alloc: ServerAllocation$1);
|
|
599
|
+
setNotes: (notes: string) => Promise<void>;
|
|
600
|
+
makeDefault: () => Promise<void>;
|
|
601
|
+
unassign: () => Promise<void>;
|
|
1331
602
|
}
|
|
1332
|
-
declare const NodeCreateSchema: z.ZodObject<{
|
|
1333
|
-
name: z.ZodString;
|
|
1334
|
-
description: z.ZodOptional<z.ZodString>;
|
|
1335
|
-
public: z.ZodOptional<z.ZodBoolean>;
|
|
1336
|
-
fqdn: z.ZodString;
|
|
1337
|
-
scheme: z.ZodEnum<{
|
|
1338
|
-
https: "https";
|
|
1339
|
-
http: "http";
|
|
1340
|
-
}>;
|
|
1341
|
-
behind_proxy: z.ZodOptional<z.ZodBoolean>;
|
|
1342
|
-
memory: z.ZodNumber;
|
|
1343
|
-
memory_overallocate: z.ZodNumber;
|
|
1344
|
-
disk: z.ZodNumber;
|
|
1345
|
-
disk_overallocate: z.ZodNumber;
|
|
1346
|
-
cpu: z.ZodNumber;
|
|
1347
|
-
cpu_overallocate: z.ZodNumber;
|
|
1348
|
-
daemon_base: z.ZodOptional<z.ZodString>;
|
|
1349
|
-
daemon_sftp: z.ZodNumber;
|
|
1350
|
-
daemon_sftp_alias: z.ZodOptional<z.ZodString>;
|
|
1351
|
-
daemon_listen: z.ZodNumber;
|
|
1352
|
-
daemon_connect: z.ZodNumber;
|
|
1353
|
-
maintenance_mode: z.ZodOptional<z.ZodBoolean>;
|
|
1354
|
-
upload_size: z.ZodNumber;
|
|
1355
|
-
tags: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
1356
|
-
}, z.core.$strip>;
|
|
1357
603
|
|
|
1358
|
-
declare class
|
|
1359
|
-
private readonly
|
|
1360
|
-
|
|
1361
|
-
|
|
1362
|
-
|
|
1363
|
-
|
|
1364
|
-
|
|
1365
|
-
|
|
1366
|
-
|
|
604
|
+
declare class ServerBackup {
|
|
605
|
+
private readonly client;
|
|
606
|
+
readonly bytes: number;
|
|
607
|
+
readonly checksum: Nullable<string>;
|
|
608
|
+
readonly completedAt: Nullable<Date>;
|
|
609
|
+
readonly createdAt: Date;
|
|
610
|
+
readonly ignoredFiles: string[];
|
|
611
|
+
readonly isLocked: boolean;
|
|
612
|
+
readonly isSuccessful: boolean;
|
|
613
|
+
readonly name: string;
|
|
614
|
+
readonly uuid: string;
|
|
615
|
+
constructor(client: ServerClient, backup: ServerBackup$1);
|
|
616
|
+
downloadGetUrl: () => Promise<string>;
|
|
617
|
+
download: () => Promise<ArrayBuffer>;
|
|
618
|
+
delete: () => Promise<void>;
|
|
1367
619
|
}
|
|
1368
620
|
|
|
1369
|
-
declare class
|
|
1370
|
-
private readonly
|
|
1371
|
-
|
|
1372
|
-
|
|
1373
|
-
|
|
1374
|
-
|
|
1375
|
-
|
|
1376
|
-
|
|
1377
|
-
|
|
1378
|
-
|
|
1379
|
-
|
|
1380
|
-
|
|
1381
|
-
|
|
1382
|
-
|
|
1383
|
-
transferCancel: () => Promise<void>;
|
|
621
|
+
declare class ServerDatabase {
|
|
622
|
+
private readonly client;
|
|
623
|
+
readonly allowConnectionsFrom: string;
|
|
624
|
+
readonly host: string;
|
|
625
|
+
readonly port: number;
|
|
626
|
+
readonly id: string;
|
|
627
|
+
readonly maxConnections: number;
|
|
628
|
+
readonly name: string;
|
|
629
|
+
private $password?;
|
|
630
|
+
get password(): string | undefined;
|
|
631
|
+
readonly username: string;
|
|
632
|
+
constructor(client: ServerClient, database: ServerDatabase$1);
|
|
633
|
+
rotatePassword: () => Promise<void>;
|
|
634
|
+
delete: () => Promise<void>;
|
|
1384
635
|
}
|
|
1385
|
-
declare const CreateServerSchema: z.ZodObject<{
|
|
1386
|
-
external_id: z.ZodOptional<z.ZodString>;
|
|
1387
|
-
name: z.ZodString;
|
|
1388
|
-
description: z.ZodOptional<z.ZodString>;
|
|
1389
|
-
user: z.ZodNumber;
|
|
1390
|
-
egg: z.ZodNumber;
|
|
1391
|
-
docker_image: z.ZodOptional<z.ZodString>;
|
|
1392
|
-
startup: z.ZodOptional<z.ZodString>;
|
|
1393
|
-
environment: z.ZodRecord<z.ZodString, z.ZodString>;
|
|
1394
|
-
skip_scripts: z.ZodOptional<z.ZodBoolean>;
|
|
1395
|
-
oom_killer: z.ZodOptional<z.ZodBoolean>;
|
|
1396
|
-
start_on_completion: z.ZodOptional<z.ZodBoolean>;
|
|
1397
|
-
docker_labels: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
1398
|
-
limits: z.ZodObject<{
|
|
1399
|
-
memory: z.ZodNumber;
|
|
1400
|
-
swap: z.ZodNumber;
|
|
1401
|
-
disk: z.ZodNumber;
|
|
1402
|
-
io: z.ZodNumber;
|
|
1403
|
-
threads: z.ZodOptional<z.ZodString>;
|
|
1404
|
-
cpu: z.ZodNumber;
|
|
1405
|
-
}, z.core.$strip>;
|
|
1406
|
-
feature_limits: z.ZodObject<{
|
|
1407
|
-
databases: z.ZodNumber;
|
|
1408
|
-
allocations: z.ZodNumber;
|
|
1409
|
-
backups: z.ZodNumber;
|
|
1410
|
-
}, z.core.$strip>;
|
|
1411
|
-
allocation: z.ZodOptional<z.ZodObject<{
|
|
1412
|
-
default: z.ZodString;
|
|
1413
|
-
additional: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
1414
|
-
}, z.core.$strip>>;
|
|
1415
|
-
deploy: z.ZodOptional<z.ZodObject<{
|
|
1416
|
-
tags: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
1417
|
-
dedicated_ip: z.ZodOptional<z.ZodBoolean>;
|
|
1418
|
-
port_range: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
1419
|
-
}, z.core.$strip>>;
|
|
1420
|
-
}, z.core.$strip>;
|
|
1421
|
-
declare const UpdateDetailsSchema: z.ZodObject<{
|
|
1422
|
-
user: z.ZodNumber;
|
|
1423
|
-
description: z.ZodOptional<z.ZodString>;
|
|
1424
|
-
name: z.ZodString;
|
|
1425
|
-
external_id: z.ZodOptional<z.ZodString>;
|
|
1426
|
-
docker_labels: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
1427
|
-
}, z.core.$strip>;
|
|
1428
|
-
declare const UpdateBuildSchema: z.ZodObject<{
|
|
1429
|
-
oom_killer: z.ZodOptional<z.ZodBoolean>;
|
|
1430
|
-
limits: z.ZodObject<{
|
|
1431
|
-
memory: z.ZodNumber;
|
|
1432
|
-
swap: z.ZodNumber;
|
|
1433
|
-
disk: z.ZodNumber;
|
|
1434
|
-
io: z.ZodNumber;
|
|
1435
|
-
threads: z.ZodOptional<z.ZodString>;
|
|
1436
|
-
cpu: z.ZodNumber;
|
|
1437
|
-
}, z.core.$strip>;
|
|
1438
|
-
feature_limits: z.ZodObject<{
|
|
1439
|
-
databases: z.ZodNumber;
|
|
1440
|
-
allocations: z.ZodNumber;
|
|
1441
|
-
backups: z.ZodNumber;
|
|
1442
|
-
}, z.core.$strip>;
|
|
1443
|
-
allocation: z.ZodOptional<z.ZodNumber>;
|
|
1444
|
-
add_allocations: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
1445
|
-
remove_allocations: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
1446
|
-
}, z.core.$strip>;
|
|
1447
|
-
declare const UpdateStartupSchema: z.ZodObject<{
|
|
1448
|
-
egg: z.ZodNumber;
|
|
1449
|
-
startup: z.ZodOptional<z.ZodString>;
|
|
1450
|
-
environment: z.ZodRecord<z.ZodString, z.ZodString>;
|
|
1451
|
-
skip_scripts: z.ZodOptional<z.ZodBoolean>;
|
|
1452
|
-
image: z.ZodOptional<z.ZodString>;
|
|
1453
|
-
}, z.core.$strip>;
|
|
1454
|
-
|
|
1455
|
-
type DatabaseHost = {
|
|
1456
|
-
id: number;
|
|
1457
|
-
name: string;
|
|
1458
|
-
host: string;
|
|
1459
|
-
port: number;
|
|
1460
|
-
username: string;
|
|
1461
|
-
created_at: string;
|
|
1462
|
-
updated_at: Nullable<string>;
|
|
1463
|
-
};
|
|
1464
636
|
|
|
1465
|
-
declare class
|
|
1466
|
-
private readonly
|
|
1467
|
-
|
|
1468
|
-
|
|
1469
|
-
|
|
1470
|
-
|
|
1471
|
-
|
|
1472
|
-
|
|
637
|
+
declare class ServerFile {
|
|
638
|
+
private readonly client;
|
|
639
|
+
private readonly dir;
|
|
640
|
+
private readonly path;
|
|
641
|
+
readonly createdAt: Date;
|
|
642
|
+
readonly isFile: boolean;
|
|
643
|
+
readonly isSymlink: boolean;
|
|
644
|
+
readonly mimetype: string;
|
|
645
|
+
readonly mode: string;
|
|
646
|
+
readonly modeBits: string;
|
|
647
|
+
readonly modifiedAt: Date;
|
|
648
|
+
readonly name: string;
|
|
649
|
+
readonly size: number;
|
|
650
|
+
constructor(client: ServerClient, file: FileObject, dir?: string);
|
|
651
|
+
get isArchive(): boolean;
|
|
652
|
+
/**
|
|
653
|
+
* Return the contents of a file. To read binary file (non-editable) use {@link download} instead
|
|
654
|
+
*/
|
|
655
|
+
contents: () => Promise<string>;
|
|
656
|
+
downloadGetUrl: () => Promise<string>;
|
|
657
|
+
download: () => Promise<ArrayBuffer>;
|
|
658
|
+
rename: (newName: string) => Promise<void>;
|
|
659
|
+
copy: () => Promise<void>;
|
|
660
|
+
write: (content: string) => Promise<void>;
|
|
661
|
+
compress: (archive_name?: string, extension?: "zip" | "tgz" | "tar.gz" | "txz" | "tar.xz" | "tbz2" | "tar.bz2") => Promise<void>;
|
|
662
|
+
decompress: () => Promise<void>;
|
|
663
|
+
delete: () => Promise<void>;
|
|
664
|
+
chmod: (mode: number) => Promise<void>;
|
|
1473
665
|
}
|
|
1474
|
-
declare const CreateDBHostSchema: z.ZodObject<{
|
|
1475
|
-
name: z.ZodString;
|
|
1476
|
-
host: z.ZodString;
|
|
1477
|
-
port: z.ZodNumber;
|
|
1478
|
-
username: z.ZodString;
|
|
1479
|
-
password: z.ZodOptional<z.ZodString>;
|
|
1480
|
-
node_ids: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
1481
|
-
max_databases: z.ZodOptional<z.ZodNumber>;
|
|
1482
|
-
}, z.core.$strip>;
|
|
1483
|
-
|
|
1484
|
-
type Role = {
|
|
1485
|
-
id: number;
|
|
1486
|
-
name: string;
|
|
1487
|
-
created_at: string;
|
|
1488
|
-
updated_at: string;
|
|
1489
|
-
};
|
|
1490
666
|
|
|
1491
|
-
declare class
|
|
1492
|
-
private readonly
|
|
1493
|
-
|
|
1494
|
-
|
|
1495
|
-
|
|
1496
|
-
|
|
1497
|
-
|
|
1498
|
-
|
|
1499
|
-
|
|
667
|
+
declare class ServerSchedule {
|
|
668
|
+
private readonly client;
|
|
669
|
+
readonly createdAt: Date;
|
|
670
|
+
private $cron;
|
|
671
|
+
get cron(): {
|
|
672
|
+
day_of_week: string;
|
|
673
|
+
day_of_month: string;
|
|
674
|
+
hour: string;
|
|
675
|
+
minute: string;
|
|
676
|
+
};
|
|
677
|
+
readonly id: number;
|
|
678
|
+
private $isActive;
|
|
679
|
+
get isActive(): boolean;
|
|
680
|
+
private $isProcessing;
|
|
681
|
+
get isProcessing(): boolean;
|
|
682
|
+
readonly lastRunAt: Nullable<Date>;
|
|
683
|
+
private $name;
|
|
684
|
+
get name(): string;
|
|
685
|
+
readonly nextRunAt: Date;
|
|
686
|
+
private $onlyWhenOnline;
|
|
687
|
+
get onlyWhenOnline(): boolean;
|
|
688
|
+
readonly tasks: ServerScheduleTask[];
|
|
689
|
+
private $updatedAt;
|
|
690
|
+
get updatedAt(): Date;
|
|
691
|
+
constructor(client: ServerClient, schedule: Schedule);
|
|
692
|
+
update: (opts: {
|
|
1500
693
|
name: string;
|
|
694
|
+
is_active?: boolean;
|
|
695
|
+
only_when_online?: boolean;
|
|
696
|
+
minute: string;
|
|
697
|
+
hour: string;
|
|
698
|
+
day_of_week: string;
|
|
699
|
+
month: string;
|
|
700
|
+
day_of_month: string;
|
|
1501
701
|
}) => Promise<void>;
|
|
1502
|
-
delete: (
|
|
702
|
+
delete: () => Promise<void>;
|
|
703
|
+
execute: () => Promise<void>;
|
|
1503
704
|
}
|
|
1504
|
-
|
|
1505
|
-
|
|
1506
|
-
|
|
1507
|
-
|
|
1508
|
-
|
|
1509
|
-
|
|
1510
|
-
|
|
1511
|
-
|
|
1512
|
-
|
|
1513
|
-
|
|
1514
|
-
|
|
1515
|
-
|
|
1516
|
-
|
|
1517
|
-
|
|
1518
|
-
|
|
1519
|
-
|
|
1520
|
-
|
|
1521
|
-
|
|
1522
|
-
|
|
1523
|
-
|
|
1524
|
-
|
|
1525
|
-
|
|
1526
|
-
privileged: boolean;
|
|
1527
|
-
install: string;
|
|
1528
|
-
entry: string;
|
|
1529
|
-
container: string;
|
|
1530
|
-
extends: Nullable<number>;
|
|
1531
|
-
};
|
|
1532
|
-
created_at: string;
|
|
1533
|
-
updated_at: Nullable<string>;
|
|
1534
|
-
};
|
|
1535
|
-
type FileConfig = {
|
|
1536
|
-
parser: string;
|
|
1537
|
-
find: Record<string, string>;
|
|
1538
|
-
};
|
|
1539
|
-
type ApplicationEggVariable = Omit<EggVariable, "server_value" | "is_editable" | "rules"> & {
|
|
1540
|
-
rules: string[];
|
|
1541
|
-
sort: number;
|
|
1542
|
-
user_viewable: boolean;
|
|
1543
|
-
user_editable: boolean;
|
|
1544
|
-
};
|
|
1545
|
-
type ExportedEgg = {
|
|
1546
|
-
meta: {
|
|
1547
|
-
version: "PLCN_v3";
|
|
1548
|
-
update_url: Nullable<string>;
|
|
1549
|
-
};
|
|
1550
|
-
exported_at: string;
|
|
1551
|
-
name: string;
|
|
1552
|
-
author: string;
|
|
1553
|
-
description: string;
|
|
1554
|
-
uuid: string;
|
|
1555
|
-
image: Nullable<string>;
|
|
1556
|
-
docker_images: Record<string, string>;
|
|
1557
|
-
features: string[];
|
|
1558
|
-
tags: string[];
|
|
1559
|
-
file_denylist: string[];
|
|
1560
|
-
startup_commands: Record<string, string>;
|
|
1561
|
-
config: Omit<Egg["config"], "extends" | "file_denylist">;
|
|
1562
|
-
scripts: {
|
|
1563
|
-
installation: {
|
|
1564
|
-
script: string;
|
|
1565
|
-
container: string;
|
|
1566
|
-
entrypoint: string;
|
|
1567
|
-
};
|
|
1568
|
-
};
|
|
1569
|
-
variables: ApplicationEggVariable[];
|
|
1570
|
-
};
|
|
1571
|
-
|
|
1572
|
-
declare class Eggs {
|
|
1573
|
-
private readonly r;
|
|
1574
|
-
constructor(r: AxiosInstance);
|
|
1575
|
-
list: () => Promise<Egg[]>;
|
|
1576
|
-
info: (id: number) => Promise<Egg>;
|
|
1577
|
-
export: (id: number, format: "json" | "yaml") => Promise<string>;
|
|
1578
|
-
infoExportable: (id: number) => Promise<ExportedEgg>;
|
|
705
|
+
declare class ServerScheduleTask {
|
|
706
|
+
private readonly client;
|
|
707
|
+
private readonly scheduleId;
|
|
708
|
+
private $action;
|
|
709
|
+
get action(): "command" | "power" | "backup" | "delete_files";
|
|
710
|
+
private $continueOnFailure;
|
|
711
|
+
get continueOnFailure(): boolean;
|
|
712
|
+
readonly createdAt: Date;
|
|
713
|
+
readonly id: number;
|
|
714
|
+
private $isQueued;
|
|
715
|
+
get isQueued(): boolean;
|
|
716
|
+
private $payload;
|
|
717
|
+
get payload(): string;
|
|
718
|
+
private $sequenceId;
|
|
719
|
+
get sequenceId(): number;
|
|
720
|
+
private $timeOffset;
|
|
721
|
+
get timeOffset(): number;
|
|
722
|
+
private $updatedAt;
|
|
723
|
+
get updatedAt(): Nullable<Date>;
|
|
724
|
+
constructor(client: ServerClient, scheduleId: number, task: ScheduleTask);
|
|
725
|
+
delete: () => Promise<void>;
|
|
726
|
+
update: (opts: PartialBy<Pick<ScheduleTask, "action" | "payload" | "time_offset" | "sequence_id" | "continue_on_failure">, "payload" | "sequence_id" | "continue_on_failure">) => Promise<void>;
|
|
1579
727
|
}
|
|
1580
728
|
|
|
1581
|
-
|
|
1582
|
-
|
|
1583
|
-
uuid: string;
|
|
1584
|
-
|
|
1585
|
-
|
|
1586
|
-
|
|
1587
|
-
|
|
1588
|
-
|
|
1589
|
-
|
|
1590
|
-
|
|
729
|
+
declare class ServerUser {
|
|
730
|
+
private readonly client;
|
|
731
|
+
readonly uuid: string;
|
|
732
|
+
readonly username: string;
|
|
733
|
+
readonly email: string;
|
|
734
|
+
readonly language: string;
|
|
735
|
+
readonly image: string;
|
|
736
|
+
readonly admin: boolean;
|
|
737
|
+
readonly root_admin: boolean;
|
|
738
|
+
readonly has2faEnabled: boolean;
|
|
739
|
+
readonly createdAt: Date;
|
|
740
|
+
private $permissions;
|
|
741
|
+
get permissions(): string[] | SubuserPermission[];
|
|
742
|
+
constructor(client: ServerClient, user: ServerSubuser);
|
|
743
|
+
update: (permissions: SubuserPermission[] | string[]) => Promise<void>;
|
|
744
|
+
delete: () => Promise<void>;
|
|
745
|
+
}
|
|
1591
746
|
|
|
1592
|
-
declare class
|
|
1593
|
-
private readonly
|
|
1594
|
-
|
|
1595
|
-
|
|
1596
|
-
|
|
1597
|
-
|
|
1598
|
-
|
|
1599
|
-
|
|
1600
|
-
|
|
1601
|
-
|
|
1602
|
-
|
|
1603
|
-
|
|
1604
|
-
|
|
1605
|
-
|
|
1606
|
-
|
|
1607
|
-
|
|
1608
|
-
|
|
747
|
+
declare class Server {
|
|
748
|
+
private readonly client;
|
|
749
|
+
readonly ownsServer: boolean;
|
|
750
|
+
readonly identifier: string;
|
|
751
|
+
readonly internalId?: number;
|
|
752
|
+
readonly uuid: string;
|
|
753
|
+
private $name;
|
|
754
|
+
get name(): string;
|
|
755
|
+
readonly node: string;
|
|
756
|
+
readonly isNodeUnderMaintenance: boolean;
|
|
757
|
+
readonly sftp: {
|
|
758
|
+
ip: string;
|
|
759
|
+
alias: Nullable<string>;
|
|
760
|
+
port: number;
|
|
761
|
+
};
|
|
762
|
+
private $description;
|
|
763
|
+
get description(): string;
|
|
764
|
+
readonly limits: ServerLimits;
|
|
765
|
+
readonly invocation: string;
|
|
766
|
+
private $dockerImage;
|
|
767
|
+
get dockerImage(): string;
|
|
768
|
+
readonly eggFeatures: Nullable<string[]>;
|
|
769
|
+
readonly featureLimits: FeatureLimits;
|
|
770
|
+
readonly status: unknown;
|
|
771
|
+
readonly isSuspended: boolean;
|
|
772
|
+
readonly isInstalling: boolean;
|
|
773
|
+
readonly isTransferring: boolean;
|
|
774
|
+
readonly allocations: ServerAllocation[];
|
|
775
|
+
readonly variables: EggVariable[];
|
|
776
|
+
readonly egg?: {
|
|
777
|
+
uuid: string;
|
|
778
|
+
name: string;
|
|
779
|
+
};
|
|
780
|
+
readonly subusers?: ServerUser[];
|
|
781
|
+
constructor(client: ServerClient, server: Server$1);
|
|
782
|
+
rename: (name: string) => Promise<void>;
|
|
783
|
+
updateDescription: (description: string) => Promise<void>;
|
|
784
|
+
reinstall: () => Promise<void>;
|
|
785
|
+
changeDockerImage: (image: string) => Promise<void>;
|
|
786
|
+
getActivityLogs: (opts?: {
|
|
787
|
+
page?: number;
|
|
788
|
+
per_page?: number;
|
|
789
|
+
}) => Promise<ServerActivityLog[]>;
|
|
790
|
+
websocket: (stripColors?: boolean) => ServerWebsocket;
|
|
791
|
+
getServerStats: () => Promise<ServerStats>;
|
|
792
|
+
runCommand: (command: string) => Promise<void>;
|
|
793
|
+
sendPowerSignal: (signal: "start" | "stop" | "restart" | "kill") => Promise<void>;
|
|
794
|
+
getDatabases: (opts?: {
|
|
795
|
+
include?: "password"[];
|
|
796
|
+
page?: number;
|
|
797
|
+
}) => Promise<ServerDatabase[]>;
|
|
798
|
+
createDatabase: (database: string, remote: string) => Promise<ServerDatabase>;
|
|
799
|
+
getSchedules: () => Promise<ServerSchedule[]>;
|
|
800
|
+
createSchedule: (...opts: Parameters<ServerSchedules["create"]>) => Promise<ServerSchedule>;
|
|
801
|
+
getBackups: (page?: number) => Promise<ServerBackup[]>;
|
|
802
|
+
createBackup: (...args: Parameters<ServerBackups["create"]>) => Promise<ServerBackup>;
|
|
803
|
+
getAllocations: () => Promise<ServerAllocation[]>;
|
|
804
|
+
createAllocation: () => Promise<ServerAllocation>;
|
|
805
|
+
getFiles: (path?: string) => Promise<ServerFile[]>;
|
|
806
|
+
createFolder: (...opts: Parameters<ServerFiles["createFolder"]>) => Promise<void>;
|
|
807
|
+
uploadFile: (...opts: Parameters<ServerFiles["upload"]>) => Promise<void>;
|
|
808
|
+
uploadFileGetUrl: (...opts: Parameters<ServerFiles["uploadGetUrl"]>) => Promise<string>;
|
|
809
|
+
pullFileFromRemote: (...opts: Parameters<ServerFiles["pullFromRemote"]>) => Promise<void>;
|
|
810
|
+
getUsers: () => Promise<ServerUser[]>;
|
|
811
|
+
createUser: (email: string, permissions: SubuserPermission[] | string[]) => Promise<ServerUser>;
|
|
812
|
+
getStartupInfo: () => Promise<CustomListResponse<StartupParams, StartupMeta>>;
|
|
813
|
+
setStartupVariable: (key: string, value: string) => Promise<StartupParams>;
|
|
1609
814
|
}
|
|
1610
|
-
declare const CreateMountSchema: z.ZodObject<{
|
|
1611
|
-
name: z.ZodString;
|
|
1612
|
-
description: z.ZodOptional<z.ZodString>;
|
|
1613
|
-
source: z.ZodString;
|
|
1614
|
-
target: z.ZodString;
|
|
1615
|
-
read_only: z.ZodOptional<z.ZodBoolean>;
|
|
1616
|
-
}, z.core.$strip>;
|
|
1617
815
|
|
|
1618
816
|
declare class Client {
|
|
1619
|
-
private readonly
|
|
1620
|
-
|
|
1621
|
-
|
|
1622
|
-
|
|
1623
|
-
|
|
1624
|
-
|
|
1625
|
-
|
|
1626
|
-
|
|
1627
|
-
|
|
1628
|
-
|
|
1629
|
-
|
|
1630
|
-
|
|
1631
|
-
servers: (server_id: number) => Servers;
|
|
817
|
+
private readonly client;
|
|
818
|
+
constructor(client: Client$1);
|
|
819
|
+
get $client(): Client$1;
|
|
820
|
+
getAccount: () => Promise<Account>;
|
|
821
|
+
listPermissions: () => Promise<Record<string, Permission>>;
|
|
822
|
+
listServers: (opts?: {
|
|
823
|
+
type?: "accessible" | "mine" | "admin" | "admin-all";
|
|
824
|
+
page?: number;
|
|
825
|
+
per_page?: number;
|
|
826
|
+
include?: ("egg" | "subusers")[];
|
|
827
|
+
}) => Promise<Server[]>;
|
|
828
|
+
getServer: (uuid: string, include?: ("egg" | "subusers")[]) => Promise<Server>;
|
|
1632
829
|
}
|
|
1633
830
|
|
|
1634
|
-
declare
|
|
1635
|
-
constructor(url: string, token: string, suffix?: string);
|
|
1636
|
-
}
|
|
1637
|
-
declare class PelicanApplication extends Client {
|
|
1638
|
-
constructor(url: string, token: string, suffix?: string);
|
|
1639
|
-
}
|
|
831
|
+
declare const createPelicanClient: (url: string, token: string, suffix?: string) => Client;
|
|
1640
832
|
|
|
1641
|
-
export {
|
|
833
|
+
export { Account, Client, Server, ServerAllocation, ServerBackup, ServerDatabase, ServerFile, ServerSchedule, ServerUser, createPelicanClient };
|