diff --git a/.release-please-manifest.json b/.release-please-manifest.json index dbe5ddf..da59f99 100644 --- a/.release-please-manifest.json +++ b/.release-please-manifest.json @@ -1,3 +1,3 @@ { - ".": "0.3.2" + ".": "0.4.0" } \ No newline at end of file diff --git a/.stats.yml b/.stats.yml index 809a80b..5e0af23 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ configured_endpoints: 35 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/replicate%2Freplicate-client-88cf5fe1f5accb56ae9fbb31c0df00d1552762d4c558d16d8547894ae95e8ccb.yml -openapi_spec_hash: 43283d20f335a04241cce165452ff50e +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/replicate%2Freplicate-client-8f6c27fe1521273cd9d08f1250da89c9b60b7bd231fa07f9e18ccba353488930.yml +openapi_spec_hash: 12e010a9fe6bed4b9c00e95a85f28b91 config_hash: 8e356248f15e5e54d2aecab141f45228 diff --git a/CHANGELOG.md b/CHANGELOG.md index ecd8ad9..68d3341 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,13 @@ # Changelog +## 0.4.0 (2025-05-13) + +Full Changelog: [v0.3.2...v0.4.0](https://github.com/replicate/replicate-python-stainless/compare/v0.3.2...v0.4.0) + +### Features + +* **api:** api update ([d36589e](https://github.com/replicate/replicate-python-stainless/commit/d36589ef3ec1718ff01948f56bfeb3dd5854d6de)) + ## 0.3.2 (2025-05-13) Full Changelog: [v0.3.1...v0.3.2](https://github.com/replicate/replicate-python-stainless/compare/v0.3.1...v0.3.2) diff --git a/README.md b/README.md index 7242a48..df59580 100644 --- a/README.md +++ b/README.md @@ -152,7 +152,6 @@ client = Replicate() client.files.create( content=Path("/path/to/file"), - filename="filename", ) ``` diff --git a/pyproject.toml b/pyproject.toml index cfd0231..d91825d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [project] name = "replicate-stainless" -version = "0.3.2" +version = "0.4.0" description = "The official Python library for the replicate API" dynamic = ["readme"] license = "Apache-2.0" diff --git a/src/replicate/_version.py b/src/replicate/_version.py index 38842d0..e36db58 100644 --- a/src/replicate/_version.py +++ b/src/replicate/_version.py @@ -1,4 +1,4 @@ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. __title__ = "replicate" -__version__ = "0.3.2" # x-release-please-version +__version__ = "0.4.0" # x-release-please-version diff --git a/src/replicate/resources/files.py b/src/replicate/resources/files.py index fdb90c0..a9f5034 100644 --- a/src/replicate/resources/files.py +++ b/src/replicate/resources/files.py @@ -58,7 +58,7 @@ def create( self, *, content: FileTypes, - filename: str, + filename: str | NotGiven = NOT_GIVEN, metadata: object | NotGiven = NOT_GIVEN, type: str | NotGiven = NOT_GIVEN, # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs. @@ -336,7 +336,7 @@ async def create( self, *, content: FileTypes, - filename: str, + filename: str | NotGiven = NOT_GIVEN, metadata: object | NotGiven = NOT_GIVEN, type: str | NotGiven = NOT_GIVEN, # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs. diff --git a/src/replicate/types/file_create_params.py b/src/replicate/types/file_create_params.py index e7c2186..c004004 100644 --- a/src/replicate/types/file_create_params.py +++ b/src/replicate/types/file_create_params.py @@ -13,7 +13,7 @@ class FileCreateParams(TypedDict, total=False): content: Required[FileTypes] """The file content""" - filename: Required[str] + filename: str """The filename""" metadata: object diff --git a/tests/api_resources/test_files.py b/tests/api_resources/test_files.py index 2a773fe..02b6d59 100644 --- a/tests/api_resources/test_files.py +++ b/tests/api_resources/test_files.py @@ -35,7 +35,6 @@ class TestFiles: def test_method_create(self, client: Replicate) -> None: file = client.files.create( content=b"raw file contents", - filename="filename", ) assert_matches_type(FileCreateResponse, file, path=["response"]) @@ -55,7 +54,6 @@ def test_method_create_with_all_params(self, client: Replicate) -> None: def test_raw_response_create(self, client: Replicate) -> None: response = client.files.with_raw_response.create( content=b"raw file contents", - filename="filename", ) assert response.is_closed is True @@ -68,7 +66,6 @@ def test_raw_response_create(self, client: Replicate) -> None: def test_streaming_response_create(self, client: Replicate) -> None: with client.files.with_streaming_response.create( content=b"raw file contents", - filename="filename", ) as response: assert not response.is_closed assert response.http_request.headers.get("X-Stainless-Lang") == "python" @@ -265,7 +262,6 @@ class TestAsyncFiles: async def test_method_create(self, async_client: AsyncReplicate) -> None: file = await async_client.files.create( content=b"raw file contents", - filename="filename", ) assert_matches_type(FileCreateResponse, file, path=["response"]) @@ -285,7 +281,6 @@ async def test_method_create_with_all_params(self, async_client: AsyncReplicate) async def test_raw_response_create(self, async_client: AsyncReplicate) -> None: response = await async_client.files.with_raw_response.create( content=b"raw file contents", - filename="filename", ) assert response.is_closed is True @@ -298,7 +293,6 @@ async def test_raw_response_create(self, async_client: AsyncReplicate) -> None: async def test_streaming_response_create(self, async_client: AsyncReplicate) -> None: async with async_client.files.with_streaming_response.create( content=b"raw file contents", - filename="filename", ) as response: assert not response.is_closed assert response.http_request.headers.get("X-Stainless-Lang") == "python"