@webdock/sdk 1.0.59690 → 1.0.59692
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/dist/account.d.ts +0 -1
- package/dist/account.d.ts.map +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +0 -2
- package/dist/index.d.ts.map +1 -1
- package/dist/index.mjs +58 -66
- package/dist/index.mjs.map +1 -1
- package/dist/servers.d.ts +102 -0
- package/dist/servers.d.ts.map +1 -1
- package/package.json +1 -1
- package/dist/scripts.d.ts +0 -112
- package/dist/scripts.d.ts.map +0 -1
- package/dist/scripts.test.d.ts +0 -2
- package/dist/scripts.test.d.ts.map +0 -1
package/dist/index.d.ts
CHANGED
|
@@ -4,7 +4,6 @@ import { HooksClass } from './hooks.js';
|
|
|
4
4
|
import { ImagesClass } from './images.js';
|
|
5
5
|
import { LocationClass } from './locations.js';
|
|
6
6
|
import { ProfilesClass } from './profiles.js';
|
|
7
|
-
import { ScriptsClass } from './scripts.js';
|
|
8
7
|
import { ServersClass } from './servers.js';
|
|
9
8
|
import { ShellUsersClass } from './shellusers.js';
|
|
10
9
|
import { SshKeysClass } from './sshkeys.js';
|
|
@@ -36,7 +35,6 @@ export declare class Webdock {
|
|
|
36
35
|
events: EventsClass;
|
|
37
36
|
hooks: HooksClass;
|
|
38
37
|
location: LocationClass;
|
|
39
|
-
scripts: ScriptsClass;
|
|
40
38
|
servers: ServersClass;
|
|
41
39
|
shellUsers: ShellUsersClass;
|
|
42
40
|
sshkeys: SshKeysClass;
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,YAAY,EAAE,MAAM,cAAc,CAAC;AAC5C,OAAO,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAC1C,OAAO,EAAE,UAAU,EAAE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3B,QAAQ,EAAE,MAAM,CAAC;IACjB,MAAM,EAAE,MAAM,CAAC;IACf,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,OAAO,CAAC,EAAE,MAAM,EAAE,GAAG,SAAS,CAAC;IAC/B,GAAG,CAAC,EAAE,OAAO,GAAG,SAAS,CAAC;CAC3B;AAKD,qBAAa,OAAO;IAClB,OAAO,EAAE,YAAY,CAAC;IACtB,MAAM,EAAE,WAAW,CAAC;IACpB,QAAQ,EAAE,aAAa,CAAC;IACxB,MAAM,EAAE,WAAW,CAAC;IACpB,KAAK,EAAE,UAAU,CAAC;IAClB,QAAQ,EAAE,aAAa,CAAC;IACxB,OAAO,EAAE,YAAY,CAAC;IACtB,UAAU,EAAE,eAAe,CAAC;IAC5B,OAAO,EAAE,YAAY,CAAC;IACtB,SAAS,EAAE,cAAc,CAAC;IAC1B,SAAS,EAAE,cAAc,CAAC;IAE1B,YAAY,EAAE,MAAM,CAAC;gBACT,KAAK,EAAE,MAAM;CAc1B"}
|
package/dist/index.mjs
CHANGED
|
@@ -1827,7 +1827,7 @@ const {
|
|
|
1827
1827
|
formToJSON: uo,
|
|
1828
1828
|
getAdapter: lo,
|
|
1829
1829
|
mergeConfig: fo
|
|
1830
|
-
} = D, ss = "1.0.
|
|
1830
|
+
} = D, ss = "1.0.59692";
|
|
1831
1831
|
async function P(r) {
|
|
1832
1832
|
var e, t, n;
|
|
1833
1833
|
try {
|
|
@@ -2073,70 +2073,7 @@ class ds {
|
|
|
2073
2073
|
}
|
|
2074
2074
|
class fs {
|
|
2075
2075
|
constructor(e) {
|
|
2076
|
-
this.parent = e;
|
|
2077
|
-
}
|
|
2078
|
-
createOnServer({
|
|
2079
|
-
scriptId: e,
|
|
2080
|
-
path: t,
|
|
2081
|
-
makeScriptExecutable: n,
|
|
2082
|
-
executeImmediately: s,
|
|
2083
|
-
serverSlug: o
|
|
2084
|
-
}) {
|
|
2085
|
-
return P(
|
|
2086
|
-
{
|
|
2087
|
-
token: this.parent.string_token,
|
|
2088
|
-
endpoint: `/servers/${o}/scripts`,
|
|
2089
|
-
method: "POST",
|
|
2090
|
-
body: {
|
|
2091
|
-
scriptId: e,
|
|
2092
|
-
path: t,
|
|
2093
|
-
makeScriptExecutable: n,
|
|
2094
|
-
executeImmediately: s
|
|
2095
|
-
},
|
|
2096
|
-
headers: ["x-callback-id"]
|
|
2097
|
-
}
|
|
2098
|
-
);
|
|
2099
|
-
}
|
|
2100
|
-
deleteScriptFromServer({ serverSlug: e, scriptId: t }) {
|
|
2101
|
-
return P(
|
|
2102
|
-
{
|
|
2103
|
-
token: this.parent.string_token,
|
|
2104
|
-
endpoint: `/servers/${e}/scripts/${t}`,
|
|
2105
|
-
method: "DELETE"
|
|
2106
|
-
}
|
|
2107
|
-
);
|
|
2108
|
-
}
|
|
2109
|
-
executeOnServer({ serverSlug: e, scriptID: t }) {
|
|
2110
|
-
return P(
|
|
2111
|
-
{
|
|
2112
|
-
token: this.parent.string_token,
|
|
2113
|
-
endpoint: `/servers/${e}/scripts/${t}/execute`,
|
|
2114
|
-
method: "POST",
|
|
2115
|
-
headers: ["x-callback-id"]
|
|
2116
|
-
}
|
|
2117
|
-
);
|
|
2118
|
-
}
|
|
2119
|
-
listOnServer({ serverSlug: e }) {
|
|
2120
|
-
return P(
|
|
2121
|
-
{
|
|
2122
|
-
token: this.parent.string_token,
|
|
2123
|
-
endpoint: `/servers/${e}/scripts`,
|
|
2124
|
-
method: "GET"
|
|
2125
|
-
}
|
|
2126
|
-
);
|
|
2127
|
-
}
|
|
2128
|
-
async list() {
|
|
2129
|
-
return await P({
|
|
2130
|
-
token: this.parent.string_token,
|
|
2131
|
-
endpoint: "/scripts",
|
|
2132
|
-
headers: [],
|
|
2133
|
-
method: "GET"
|
|
2134
|
-
});
|
|
2135
|
-
}
|
|
2136
|
-
}
|
|
2137
|
-
class ps {
|
|
2138
|
-
constructor(e) {
|
|
2139
|
-
this.parent = e;
|
|
2076
|
+
this.parent = e, this.scripts = new ps(e);
|
|
2140
2077
|
}
|
|
2141
2078
|
create({
|
|
2142
2079
|
name: e,
|
|
@@ -2337,6 +2274,61 @@ class ps {
|
|
|
2337
2274
|
});
|
|
2338
2275
|
}
|
|
2339
2276
|
}
|
|
2277
|
+
class ps {
|
|
2278
|
+
constructor(e) {
|
|
2279
|
+
this.parent = e;
|
|
2280
|
+
}
|
|
2281
|
+
create({
|
|
2282
|
+
scriptId: e,
|
|
2283
|
+
path: t,
|
|
2284
|
+
makeScriptExecutable: n,
|
|
2285
|
+
executeImmediately: s,
|
|
2286
|
+
serverSlug: o
|
|
2287
|
+
}) {
|
|
2288
|
+
return P(
|
|
2289
|
+
{
|
|
2290
|
+
token: this.parent.string_token,
|
|
2291
|
+
endpoint: `/servers/${o}/scripts`,
|
|
2292
|
+
method: "POST",
|
|
2293
|
+
body: {
|
|
2294
|
+
scriptId: e,
|
|
2295
|
+
path: t,
|
|
2296
|
+
makeScriptExecutable: n,
|
|
2297
|
+
executeImmediately: s
|
|
2298
|
+
},
|
|
2299
|
+
headers: ["x-callback-id"]
|
|
2300
|
+
}
|
|
2301
|
+
);
|
|
2302
|
+
}
|
|
2303
|
+
delete({ serverSlug: e, scriptId: t }) {
|
|
2304
|
+
return P(
|
|
2305
|
+
{
|
|
2306
|
+
token: this.parent.string_token,
|
|
2307
|
+
endpoint: `/servers/${e}/scripts/${t}`,
|
|
2308
|
+
method: "DELETE"
|
|
2309
|
+
}
|
|
2310
|
+
);
|
|
2311
|
+
}
|
|
2312
|
+
execute({ serverSlug: e, scriptID: t }) {
|
|
2313
|
+
return P(
|
|
2314
|
+
{
|
|
2315
|
+
token: this.parent.string_token,
|
|
2316
|
+
endpoint: `/servers/${e}/scripts/${t}/execute`,
|
|
2317
|
+
method: "POST",
|
|
2318
|
+
headers: ["x-callback-id"]
|
|
2319
|
+
}
|
|
2320
|
+
);
|
|
2321
|
+
}
|
|
2322
|
+
listOnServer({ serverSlug: e }) {
|
|
2323
|
+
return P(
|
|
2324
|
+
{
|
|
2325
|
+
token: this.parent.string_token,
|
|
2326
|
+
endpoint: `/servers/${e}/scripts`,
|
|
2327
|
+
method: "GET"
|
|
2328
|
+
}
|
|
2329
|
+
);
|
|
2330
|
+
}
|
|
2331
|
+
}
|
|
2340
2332
|
class hs {
|
|
2341
2333
|
constructor(e) {
|
|
2342
2334
|
this.parent = e;
|
|
@@ -3943,7 +3935,7 @@ class zs {
|
|
|
3943
3935
|
const po = Ks;
|
|
3944
3936
|
class ho {
|
|
3945
3937
|
constructor(e) {
|
|
3946
|
-
this.string_token = e, this.account = new os(this), this.images = new us(this), this.profiles = new ds(this), this.events = new as(this), this.hooks = new cs(this), this.location = new ls(this), this.
|
|
3938
|
+
this.string_token = e, this.account = new os(this), this.images = new us(this), this.profiles = new ds(this), this.events = new as(this), this.hooks = new cs(this), this.location = new ls(this), this.servers = new fs(this), this.shellUsers = new hs(this), this.sshkeys = new vs(this), this.snapshots = new Ss(this), this.operation = new zs(this);
|
|
3947
3939
|
}
|
|
3948
3940
|
}
|
|
3949
3941
|
export {
|