test-wuying-agentbay-sdk 0.13.1-beta.20251224113236 → 0.13.1-beta.20251224115652

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.
@@ -25,6 +25,7 @@ Represents a session in the AgentBay cloud environment.
25
25
  - [getLabels](#getlabels)
26
26
  - [getLink](#getlink)
27
27
  - [getLinkAsync](#getlinkasync)
28
+ - [getMetrics](#getmetrics)
28
29
  - [info](#info)
29
30
  - [listMcpTools](#listmcptools)
30
31
  - [pauseAsync](#pauseasync)
@@ -315,6 +316,35 @@ if (result.success) {
315
316
  }
316
317
  ```
317
318
 
319
+ ___
320
+
321
+ ### getMetrics
322
+
323
+ ▸ **getMetrics**(): `Promise`\<``SessionMetricsResult``\>
324
+
325
+ Get runtime metrics for this session.
326
+
327
+ The underlying service returns a JSON string. This method parses it and
328
+ returns a structured result.
329
+
330
+ #### Returns
331
+
332
+ `Promise`\<``SessionMetricsResult``\>
333
+
334
+ **`Example`**
335
+
336
+ ```typescript
337
+ const agentBay = new AgentBay({ apiKey: "your_api_key" });
338
+ const create = await agentBay.create({ imageId: "linux_latest" });
339
+ if (create.success && create.session) {
340
+ const metrics = await create.session.getMetrics();
341
+ console.log(metrics.data);
342
+ await create.session.delete();
343
+ }
344
+ ```
345
+
346
+ ___
347
+
318
348
  ### info
319
349
 
320
350
  ▸ **info**(): `Promise`\<`OperationResult`\>
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "test-wuying-agentbay-sdk",
3
- "version": "0.13.1-beta.20251224113236",
3
+ "version": "0.13.1-beta.20251224115652",
4
4
  "description": "TypeScript SDK for interacting with the Wuying AgentBay cloud runtime environment",
5
5
  "main": "./dist/index.cjs",
6
6
  "module": "./dist/index.mjs",