@phpsandbox/sdk 0.1.11 → 0.1.12
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/README.md +1 -0
- package/dist/browser/phpsandbox-sdk.esm.js +7 -0
- package/dist/browser/phpsandbox-sdk.esm.min.js +2 -2
- package/dist/browser/phpsandbox-sdk.iife.js +7 -0
- package/dist/browser/phpsandbox-sdk.iife.min.js +2 -2
- package/dist/ports.d.ts +1 -0
- package/dist/ports.js +3 -0
- package/dist/runtime/rest.js +1 -0
- package/dist/runtime.d.ts +4 -0
- package/dist/runtime.js +3 -0
- package/docs/api-summary.md +1 -0
- package/package.json +1 -1
package/dist/runtime/rest.js
CHANGED
|
@@ -9,6 +9,7 @@ const restActionRoutes = {
|
|
|
9
9
|
'container.stop': { method: 'POST', path: '/runtime/container/stop' },
|
|
10
10
|
'container.set-php': { method: 'PUT', path: '/runtime/container/php' },
|
|
11
11
|
'container.opened-ports': { method: 'GET', path: '/runtime/container/ports' },
|
|
12
|
+
'container.resolve-port': { method: 'POST', path: '/runtime/container/ports/resolve' },
|
|
12
13
|
'container.stats': { method: 'GET', path: '/runtime/container/stats' },
|
|
13
14
|
'terminal.list': { method: 'GET', path: '/runtime/terminals' },
|
|
14
15
|
'shell.exec': { method: 'POST', path: '/runtime/executions' },
|
package/dist/runtime.d.ts
CHANGED
|
@@ -28,6 +28,9 @@ export interface RuntimeActions {
|
|
|
28
28
|
'container.restart': Action<{}, void>;
|
|
29
29
|
'container.stop': Action<{}, void>;
|
|
30
30
|
'container.opened-ports': Action<{}, PortInfo[]>;
|
|
31
|
+
'container.resolve-port': Action<{
|
|
32
|
+
port: number;
|
|
33
|
+
}, PortInfo>;
|
|
31
34
|
'container.stats': Action<{}, RuntimeStats | null>;
|
|
32
35
|
'container.set-php': Action<{
|
|
33
36
|
version: string;
|
|
@@ -54,6 +57,7 @@ export declare class RuntimePorts {
|
|
|
54
57
|
private readonly ports;
|
|
55
58
|
constructor(ports: Ports);
|
|
56
59
|
list(): Promise<PortInfo[]>;
|
|
60
|
+
resolve(port: number): Promise<PortInfo>;
|
|
57
61
|
watch(options?: RuntimeWatchOptions): ReadableStream<PortInfo[]>;
|
|
58
62
|
}
|
|
59
63
|
export default class Runtime {
|
package/dist/runtime.js
CHANGED
package/docs/api-summary.md
CHANGED
|
@@ -62,6 +62,7 @@ Connection lifecycle methods, streaming actions, and event subscriptions require
|
|
|
62
62
|
|
|
63
63
|
- `notebook.runtime.logs.follow({ signal? })` returns `ReadableStream<RuntimeLogEntry>`
|
|
64
64
|
- `notebook.runtime.ports.list()` returns the current preview ports
|
|
65
|
+
- `notebook.runtime.ports.resolve(port)` returns preview routing information even when the port is not open
|
|
65
66
|
- `notebook.runtime.ports.watch({ signal? })` returns `ReadableStream<PortInfo[]>`
|
|
66
67
|
- `notebook.runtime.metrics.current()` returns the current CPU, memory, and disk sample
|
|
67
68
|
- `notebook.runtime.metrics.watch({ signal? })` returns `ReadableStream<RuntimeStats>`
|
package/package.json
CHANGED