Skip to content

Commit de25ac3

Browse files
committed
add undefined
1 parent d5896b3 commit de25ac3

File tree

2 files changed

+7
-4
lines changed

2 files changed

+7
-4
lines changed

src/resources/audio/transcriptions.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ export class Transcriptions extends APIResource {
1010
* Transcribes audio into the input language.
1111
*/
1212
create(
13-
body: TranscriptionCreateParams<'json'>,
13+
body: TranscriptionCreateParams<'json' | undefined>,
1414
options?: Core.RequestOptions,
1515
): Core.APIPromise<Transcription>;
1616
create(
@@ -150,7 +150,7 @@ export interface TranscriptionWord {
150150
export type TranscriptionCreateResponse = Transcription | TranscriptionVerbose;
151151

152152
export interface TranscriptionCreateParams<
153-
ResponseFormat extends AudioAPI.AudioResponseFormat = AudioAPI.AudioResponseFormat,
153+
ResponseFormat extends AudioAPI.AudioResponseFormat | undefined = AudioAPI.AudioResponseFormat | undefined,
154154
> {
155155
/**
156156
* The audio file object (not file name) to transcribe, in one of these formats:

src/resources/audio/translations.ts

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,10 @@ export class Translations extends APIResource {
1010
/**
1111
* Translates audio into English.
1212
*/
13-
create(body: TranslationCreateParams<'json'>, options?: Core.RequestOptions): Core.APIPromise<Translation>;
13+
create(
14+
body: TranslationCreateParams<'json' | undefined>,
15+
options?: Core.RequestOptions,
16+
): Core.APIPromise<Translation>;
1417
create(
1518
body: TranslationCreateParams<'verbose_json'>,
1619
options?: Core.RequestOptions,
@@ -56,7 +59,7 @@ export interface TranslationVerbose {
5659
export type TranslationCreateResponse = Translation | TranslationVerbose;
5760

5861
export interface TranslationCreateParams<
59-
ResponseFormat extends AudioAPI.AudioResponseFormat = AudioAPI.AudioResponseFormat,
62+
ResponseFormat extends AudioAPI.AudioResponseFormat | undefined = AudioAPI.AudioResponseFormat | undefined,
6063
> {
6164
/**
6265
* The audio file object (not file name) translate, in one of these formats: flac,

0 commit comments

Comments
 (0)