@lightningai/sdk 2026.4.25 → 2026.4.26
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 +4 -5
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -12,6 +12,9 @@ TypeScript SDK for [Lightning AI](https://lightning.ai) sandboxes: create and ma
|
|
|
12
12
|
npm install @lightningai/sdk
|
|
13
13
|
```
|
|
14
14
|
|
|
15
|
+
> **Note**
|
|
16
|
+
> This package is published as an ES Module (ESM) only. For applications using CommonJS, use `await import("@lightningai/sdk")` to import and use this package.
|
|
17
|
+
|
|
15
18
|
## Quick start
|
|
16
19
|
|
|
17
20
|
Set an API key (or pass `apiKey` to `Sandbox.configure()`):
|
|
@@ -32,11 +35,7 @@ async function main() {
|
|
|
32
35
|
instanceType: "cpu-1",
|
|
33
36
|
});
|
|
34
37
|
|
|
35
|
-
const result = await sandbox.runCommand(
|
|
36
|
-
cmd: "sh",
|
|
37
|
-
args: ["-c", 'echo "Hello, World!"'],
|
|
38
|
-
env: { NODE_ENV: "development" },
|
|
39
|
-
});
|
|
38
|
+
const result = await sandbox.runCommand("echo", ["Hello, World!"]);
|
|
40
39
|
console.log(result.output);
|
|
41
40
|
|
|
42
41
|
await sandbox.delete();
|
package/package.json
CHANGED