@discomedia/utils 1.0.63 → 1.0.64

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.
@@ -260,7 +260,7 @@ const safeJSON = (text) => {
260
260
  // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
261
261
  const sleep = (ms) => new Promise((resolve) => setTimeout(resolve, ms));
262
262
 
263
- const VERSION = '6.27.0'; // x-release-please-version
263
+ const VERSION = '6.31.0'; // x-release-please-version
264
264
 
265
265
  // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
266
266
  const isRunningInBrowser = () => {
@@ -3504,7 +3504,7 @@ class Speech extends APIResource {
3504
3504
  * const speech = await client.audio.speech.create({
3505
3505
  * input: 'input',
3506
3506
  * model: 'string',
3507
- * voice: 'ash',
3507
+ * voice: 'string',
3508
3508
  * });
3509
3509
  *
3510
3510
  * const content = await speech.blob();
@@ -6785,7 +6785,7 @@ class Videos extends APIResource {
6785
6785
  * Create a new video generation job from a prompt and optional reference assets.
6786
6786
  */
6787
6787
  create(body, options) {
6788
- return this._client.post('/videos', maybeMultipartFormRequestOptions({ body, ...options }, this._client));
6788
+ return this._client.post('/videos', multipartFormRequestOptions({ body, ...options }, this._client));
6789
6789
  }
6790
6790
  /**
6791
6791
  * Fetch the latest metadata for a generated video.
@@ -6805,6 +6805,12 @@ class Videos extends APIResource {
6805
6805
  delete(videoID, options) {
6806
6806
  return this._client.delete(path `/videos/${videoID}`, options);
6807
6807
  }
6808
+ /**
6809
+ * Create a character from an uploaded video.
6810
+ */
6811
+ createCharacter(body, options) {
6812
+ return this._client.post('/videos/characters', multipartFormRequestOptions({ body, ...options }, this._client));
6813
+ }
6808
6814
  /**
6809
6815
  * Download the generated video bytes or a derived preview asset.
6810
6816
  *
@@ -6818,6 +6824,25 @@ class Videos extends APIResource {
6818
6824
  __binaryResponse: true,
6819
6825
  });
6820
6826
  }
6827
+ /**
6828
+ * Create a new video generation job by editing a source video or existing
6829
+ * generated video.
6830
+ */
6831
+ edit(body, options) {
6832
+ return this._client.post('/videos/edits', multipartFormRequestOptions({ body, ...options }, this._client));
6833
+ }
6834
+ /**
6835
+ * Create an extension of a completed video.
6836
+ */
6837
+ extend(body, options) {
6838
+ return this._client.post('/videos/extensions', multipartFormRequestOptions({ body, ...options }, this._client));
6839
+ }
6840
+ /**
6841
+ * Fetch a character.
6842
+ */
6843
+ getCharacter(characterID, options) {
6844
+ return this._client.get(path `/videos/characters/${characterID}`, options);
6845
+ }
6821
6846
  /**
6822
6847
  * Create a remix of a completed video using a refreshed prompt.
6823
6848
  */
@@ -7099,8 +7124,9 @@ class OpenAI {
7099
7124
  new URL(path)
7100
7125
  : new URL(baseURL + (baseURL.endsWith('/') && path.startsWith('/') ? path.slice(1) : path));
7101
7126
  const defaultQuery = this.defaultQuery();
7102
- if (!isEmptyObj$1(defaultQuery)) {
7103
- query = { ...defaultQuery, ...query };
7127
+ const pathQuery = Object.fromEntries(url.searchParams);
7128
+ if (!isEmptyObj$1(defaultQuery) || !isEmptyObj$1(pathQuery)) {
7129
+ query = { ...pathQuery, ...defaultQuery, ...query };
7104
7130
  }
7105
7131
  if (typeof query === 'object' && query && !Array.isArray(query)) {
7106
7132
  url.search = this.stringifyQuery(query);