Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

release: 4.78.1 #1258

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .release-please-manifest.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
".": "4.78.0"
".": "4.78.1"
}
8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
# Changelog

## 4.78.1 (2025-01-10)

Full Changelog: [v4.78.0...v4.78.1](https://github.com/openai/openai-node/compare/v4.78.0...v4.78.1)

### Bug Fixes

* send correct Accept header for certain endpoints ([#1257](https://github.com/openai/openai-node/issues/1257)) ([8756693](https://github.com/openai/openai-node/commit/8756693c5690b16045cdd8d33636fe7643d45f3a))

## 4.78.0 (2025-01-09)

Full Changelog: [v4.77.4...v4.78.0](https://github.com/openai/openai-node/compare/v4.77.4...v4.78.0)
Expand Down
2 changes: 1 addition & 1 deletion jsr.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@openai/openai",
"version": "4.78.0",
"version": "4.78.1",
"exports": "./index.ts",
"publish": {
"exclude": [
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "openai",
"version": "4.78.0",
"version": "4.78.1",
"description": "The official TypeScript library for the OpenAI API",
"author": "OpenAI <support@openai.com>",
"types": "dist/index.d.ts",
Expand Down
7 changes: 6 additions & 1 deletion src/resources/audio/speech.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,12 @@ export class Speech extends APIResource {
* Generates audio from the input text.
*/
create(body: SpeechCreateParams, options?: Core.RequestOptions): Core.APIPromise<Response> {
return this._client.post('/audio/speech', { body, ...options, __binaryResponse: true });
return this._client.post('/audio/speech', {
body,
...options,
headers: { Accept: 'application/octet-stream', ...options?.headers },
__binaryResponse: true,
});
}
}

Expand Down
11 changes: 6 additions & 5 deletions src/resources/files.ts
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,11 @@ export class Files extends APIResource {
* Returns the contents of the specified file.
*/
content(fileId: string, options?: Core.RequestOptions): Core.APIPromise<Response> {
return this._client.get(`/files/${fileId}/content`, { ...options, __binaryResponse: true });
return this._client.get(`/files/${fileId}/content`, {
...options,
headers: { Accept: 'application/binary', ...options?.headers },
__binaryResponse: true,
});
}

/**
Expand All @@ -78,10 +82,7 @@ export class Files extends APIResource {
* @deprecated The `.content()` method should be used instead
*/
retrieveContent(fileId: string, options?: Core.RequestOptions): Core.APIPromise<string> {
return this._client.get(`/files/${fileId}/content`, {
...options,
headers: { Accept: 'application/json', ...options?.headers },
});
return this._client.get(`/files/${fileId}/content`, options);
}

/**
Expand Down
2 changes: 1 addition & 1 deletion src/version.ts
Original file line number Diff line number Diff line change
@@ -1 +1 @@
export const VERSION = '4.78.0'; // x-release-please-version
export const VERSION = '4.78.1'; // x-release-please-version
Loading