@discomedia/utils 1.0.76 → 1.0.77
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/index-frontend.cjs +43 -2
- package/dist/index-frontend.cjs.map +1 -1
- package/dist/index-frontend.mjs +43 -2
- package/dist/index-frontend.mjs.map +1 -1
- package/dist/index.cjs +43 -2
- package/dist/index.cjs.map +1 -1
- package/dist/index.mjs +43 -2
- package/dist/index.mjs.map +1 -1
- package/dist/package.json +3 -3
- package/dist/test.js +43 -2
- package/dist/test.js.map +1 -1
- package/package.json +3 -3
package/dist/index.cjs
CHANGED
|
@@ -1703,7 +1703,7 @@ const safeJSON = (text) => {
|
|
|
1703
1703
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
1704
1704
|
const sleep = (ms) => new Promise((resolve) => setTimeout(resolve, ms));
|
|
1705
1705
|
|
|
1706
|
-
const VERSION = '6.
|
|
1706
|
+
const VERSION = '6.44.0'; // x-release-please-version
|
|
1707
1707
|
|
|
1708
1708
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
1709
1709
|
const isRunningInBrowser = () => {
|
|
@@ -4089,7 +4089,12 @@ _AbstractChatCompletionRunner_instances = new WeakSet(), _AbstractChatCompletion
|
|
|
4089
4089
|
for (let i = this.messages.length - 1; i >= 0; i--) {
|
|
4090
4090
|
const message = this.messages[i];
|
|
4091
4091
|
if (isAssistantMessage(message) && message?.tool_calls?.length) {
|
|
4092
|
-
|
|
4092
|
+
for (let j = message.tool_calls.length - 1; j >= 0; j--) {
|
|
4093
|
+
const toolCall = message.tool_calls[j];
|
|
4094
|
+
if (toolCall?.type === 'function') {
|
|
4095
|
+
return toolCall.function;
|
|
4096
|
+
}
|
|
4097
|
+
}
|
|
4093
4098
|
}
|
|
4094
4099
|
}
|
|
4095
4100
|
return;
|
|
@@ -5467,6 +5472,23 @@ let SpendAlerts$1 = class SpendAlerts extends APIResource {
|
|
|
5467
5472
|
__security: { adminAPIKeyAuth: true },
|
|
5468
5473
|
});
|
|
5469
5474
|
}
|
|
5475
|
+
/**
|
|
5476
|
+
* Retrieves an organization spend alert.
|
|
5477
|
+
*
|
|
5478
|
+
* @example
|
|
5479
|
+
* ```ts
|
|
5480
|
+
* const organizationSpendAlert =
|
|
5481
|
+
* await client.admin.organization.spendAlerts.retrieve(
|
|
5482
|
+
* 'alert_id',
|
|
5483
|
+
* );
|
|
5484
|
+
* ```
|
|
5485
|
+
*/
|
|
5486
|
+
retrieve(alertID, options) {
|
|
5487
|
+
return this._client.get(path `/organization/spend_alerts/${alertID}`, {
|
|
5488
|
+
...options,
|
|
5489
|
+
__security: { adminAPIKeyAuth: true },
|
|
5490
|
+
});
|
|
5491
|
+
}
|
|
5470
5492
|
/**
|
|
5471
5493
|
* Updates an organization spend alert.
|
|
5472
5494
|
*
|
|
@@ -6498,6 +6520,25 @@ class SpendAlerts extends APIResource {
|
|
|
6498
6520
|
__security: { adminAPIKeyAuth: true },
|
|
6499
6521
|
});
|
|
6500
6522
|
}
|
|
6523
|
+
/**
|
|
6524
|
+
* Retrieves a project spend alert.
|
|
6525
|
+
*
|
|
6526
|
+
* @example
|
|
6527
|
+
* ```ts
|
|
6528
|
+
* const projectSpendAlert =
|
|
6529
|
+
* await client.admin.organization.projects.spendAlerts.retrieve(
|
|
6530
|
+
* 'alert_id',
|
|
6531
|
+
* { project_id: 'project_id' },
|
|
6532
|
+
* );
|
|
6533
|
+
* ```
|
|
6534
|
+
*/
|
|
6535
|
+
retrieve(alertID, params, options) {
|
|
6536
|
+
const { project_id } = params;
|
|
6537
|
+
return this._client.get(path `/organization/projects/${project_id}/spend_alerts/${alertID}`, {
|
|
6538
|
+
...options,
|
|
6539
|
+
__security: { adminAPIKeyAuth: true },
|
|
6540
|
+
});
|
|
6541
|
+
}
|
|
6501
6542
|
/**
|
|
6502
6543
|
* Updates a project spend alert.
|
|
6503
6544
|
*
|