Skip to content

Commit

Permalink
Add missing RT error types
Browse files Browse the repository at this point in the history
  • Loading branch information
mnemitz committed Oct 29, 2024
1 parent 0e782df commit 9e618b8
Show file tree
Hide file tree
Showing 4 changed files with 22 additions and 0 deletions.
2 changes: 2 additions & 0 deletions packages/real-time-client/models/model-error.ts
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,8 @@ export const ModelErrorTypeEnum = {
DataError: 'data_error',
BufferError: 'buffer_error',
ProtocolError: 'protocol_error',
TimelimitExceeded: 'timelimit_exceeded',
QuotaExceeded: 'quota_exceeded',
UnknownError: 'unknown_error',
} as const;

Expand Down
2 changes: 2 additions & 0 deletions packages/real-time-client/schema/realtime.yml
Original file line number Diff line number Diff line change
Expand Up @@ -343,6 +343,8 @@ components:
- data_error
- buffer_error
- protocol_error
- timelimit_exceeded
- quota_exceeded
- unknown_error
reason:
type: string
Expand Down
2 changes: 2 additions & 0 deletions packages/real-time-client/scripts/openapi-transformed.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -250,6 +250,8 @@ components:
- data_error
- buffer_error
- protocol_error
- timelimit_exceeded
- quota_exceeded
- unknown_error
reason:
type: string
Expand Down
16 changes: 16 additions & 0 deletions packages/real-time-client/src/client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -260,3 +260,19 @@ function rejectAfter<T = unknown>(timeoutMs: number, key: string): Promise<T> {
);
});
}

export type { StartRecognition };
export type { SetRecognitionConfig };
export type { EndOfStream };
export type { RecognitionStarted };
export type { AudioAdded };
export type { AddPartialTranscript };
export type { AddTranscript };
export type { AddPartialTranslation };
export type { AddTranslation };
export type { EndOfTranscript };
export type { AudioEventStarted };
export type { AudioEventEnded };
export type { Info };
export type { Warning };
export type { ModelError };

0 comments on commit 9e618b8

Please sign in to comment.