Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
23 commits
Select commit Hold shift + click to select a range
9e862ec
codegen metadata
stainless-app[bot] Oct 10, 2025
6085dd3
chore(internal): detect missing future annotations with ruff
stainless-app[bot] Oct 11, 2025
4d594a5
codegen metadata
stainless-app[bot] Oct 18, 2025
6ad4b61
chore: bump `httpx-aiohttp` version to 0.1.9
stainless-app[bot] Oct 18, 2025
d255ce6
codegen metadata
stainless-app[bot] Oct 28, 2025
4033279
codegen metadata
stainless-app[bot] Oct 28, 2025
4e6c8e6
feat(api): api update
stainless-app[bot] Oct 29, 2025
1155c43
fix(client): close streams without requiring full consumption
stainless-app[bot] Oct 30, 2025
a776c2c
feat(api): api update
stainless-app[bot] Oct 30, 2025
7bad0fc
chore(internal/tests): avoid race condition with implicit client cleanup
stainless-app[bot] Oct 31, 2025
329768e
chore(internal): grammar fix (it's -> its)
stainless-app[bot] Nov 4, 2025
3c39638
codegen metadata
stainless-app[bot] Nov 6, 2025
9feb588
chore(package): drop Python 3.8 support
stainless-app[bot] Nov 11, 2025
d42dd9c
fix: compat with Python 3.14
stainless-app[bot] Nov 11, 2025
447f54f
fix(compat): update signatures of `model_dump` and `model_dump_json` …
stainless-app[bot] Nov 12, 2025
e29337c
feat(api): api update
stainless-app[bot] Nov 18, 2025
0972c10
feat(api): api update
stainless-app[bot] Nov 19, 2025
8802bdd
chore: add Python 3.14 classifier and testing
stainless-app[bot] Nov 22, 2025
a7749c9
feat(api): api update
stainless-app[bot] Nov 25, 2025
1c5e2f9
codegen metadata
stainless-app[bot] Nov 26, 2025
5acbfb9
codegen metadata
stainless-app[bot] Nov 26, 2025
c780b0f
feat(api): manual updates
stainless-app[bot] Nov 26, 2025
76ead3d
release: 3.5.0
stainless-app[bot] Nov 26, 2025
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 @@
{
".": "3.4.0"
".": "3.5.0"
}
8 changes: 4 additions & 4 deletions .stats.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
configured_endpoints: 18
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/supermemory--inc%2Fsupermemory-new-ff2201f4ff8f062673cb93068f6d3efeb46d6ac7ce66632418ec1825b03f6332.yml
openapi_spec_hash: 11b52dea5fc829a46baea91d0c7e3c4e
config_hash: a478b24249ee4f53abfb5787ca4daf8b
configured_endpoints: 19
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/supermemory--inc%2Fsupermemory-new-ebd5e757d0e76cb83013e01a1e0bb3dba62beb83b2a2ffa28d148ea032e96fd0.yml
openapi_spec_hash: f930474a6ad230545154244045cc602e
config_hash: 5761a0b4f8c53c72efab21d41c00012b
30 changes: 30 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,35 @@
# Changelog

## 3.5.0 (2025-11-26)

Full Changelog: [v3.4.0...v3.5.0](https://github.com/supermemoryai/python-sdk/compare/v3.4.0...v3.5.0)

### Features

* **api:** api update ([a7749c9](https://github.com/supermemoryai/python-sdk/commit/a7749c97703d995ed97ba1a5c09fef9e5804bea7))
* **api:** api update ([0972c10](https://github.com/supermemoryai/python-sdk/commit/0972c10cebf6bab936371dfa4c5ad87dad1f5496))
* **api:** api update ([e29337c](https://github.com/supermemoryai/python-sdk/commit/e29337c11f26831d69e6f830542e5db708760b62))
* **api:** api update ([a776c2c](https://github.com/supermemoryai/python-sdk/commit/a776c2cfcf82ee239c707b9065bd3313755388fa))
* **api:** api update ([4e6c8e6](https://github.com/supermemoryai/python-sdk/commit/4e6c8e61653c99c733f862cbb5e08478159d082b))
* **api:** manual updates ([c780b0f](https://github.com/supermemoryai/python-sdk/commit/c780b0fc9afb857dd55613d5b67cd7849b68973c))


### Bug Fixes

* **client:** close streams without requiring full consumption ([1155c43](https://github.com/supermemoryai/python-sdk/commit/1155c4396baa8681dcb72f6b53f90c42052fac6f))
* compat with Python 3.14 ([d42dd9c](https://github.com/supermemoryai/python-sdk/commit/d42dd9c177546142c2d87484e1bb435401cfaac8))
* **compat:** update signatures of `model_dump` and `model_dump_json` for Pydantic v1 ([447f54f](https://github.com/supermemoryai/python-sdk/commit/447f54f0f7846283b4033275fe2042f6dff66a2c))


### Chores

* add Python 3.14 classifier and testing ([8802bdd](https://github.com/supermemoryai/python-sdk/commit/8802bdd0529ef3759bf1b8547ce2405c8164d0e9))
* bump `httpx-aiohttp` version to 0.1.9 ([6ad4b61](https://github.com/supermemoryai/python-sdk/commit/6ad4b613df1d4177fabeaf0b67d984e195af8594))
* **internal/tests:** avoid race condition with implicit client cleanup ([7bad0fc](https://github.com/supermemoryai/python-sdk/commit/7bad0fc387de50f25bec0e3a7ecca2b732294460))
* **internal:** detect missing future annotations with ruff ([6085dd3](https://github.com/supermemoryai/python-sdk/commit/6085dd39d67398eec25d5b9bcc5371f4810622c8))
* **internal:** grammar fix (it's -> its) ([329768e](https://github.com/supermemoryai/python-sdk/commit/329768ed8cec31b2ef510409b9f67a3f800a286b))
* **package:** drop Python 3.8 support ([9feb588](https://github.com/supermemoryai/python-sdk/commit/9feb588a112036bd5de9041f775232f7c1384e3f))

## 3.4.0 (2025-10-07)

Full Changelog: [v3.3.0...v3.4.0](https://github.com/supermemoryai/python-sdk/compare/v3.3.0...v3.4.0)
Expand Down
14 changes: 7 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<!-- prettier-ignore -->
[![PyPI version](https://img.shields.io/pypi/v/supermemory.svg?label=pypi%20(stable))](https://pypi.org/project/supermemory/)

The Supermemory Python library provides convenient access to the Supermemory REST API from any Python 3.8+
The Supermemory Python library provides convenient access to the Supermemory REST API from any Python 3.9+
application. The library includes type definitions for all request params and response fields,
and offers both synchronous and asynchronous clients powered by [httpx](https://github.com/encode/httpx).

Expand Down Expand Up @@ -161,7 +161,7 @@ client = Supermemory()

try:
client.memories.add(
content="This is a detailed article about machine learning concepts...",
content="content",
)
except supermemory.APIConnectionError as e:
print("The server could not be reached")
Expand Down Expand Up @@ -206,7 +206,7 @@ client = Supermemory(

# Or, configure per-request:
client.with_options(max_retries=5).memories.add(
content="This is a detailed article about machine learning concepts...",
content="content",
)
```

Expand All @@ -231,7 +231,7 @@ client = Supermemory(

# Override per-request:
client.with_options(timeout=5.0).memories.add(
content="This is a detailed article about machine learning concepts...",
content="content",
)
```

Expand Down Expand Up @@ -274,7 +274,7 @@ from supermemory import Supermemory

client = Supermemory()
response = client.memories.with_raw_response.add(
content="This is a detailed article about machine learning concepts...",
content="content",
)
print(response.headers.get('X-My-Header'))

Expand All @@ -294,7 +294,7 @@ To stream the response body, use `.with_streaming_response` instead, which requi

```python
with client.memories.with_streaming_response.add(
content="This is a detailed article about machine learning concepts...",
content="content",
) as response:
print(response.headers.get("X-My-Header"))

Expand Down Expand Up @@ -405,7 +405,7 @@ print(supermemory.__version__)

## Requirements

Python 3.8 or higher.
Python 3.9 or higher.

## Contributing

Expand Down
12 changes: 12 additions & 0 deletions api.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,18 @@ Methods:
- <code title="get /v3/documents/{id}">client.documents.<a href="./src/supermemory/resources/documents.py">get</a>(id) -> <a href="./src/supermemory/types/document_get_response.py">DocumentGetResponse</a></code>
- <code title="post /v3/documents/file">client.documents.<a href="./src/supermemory/resources/documents.py">upload_file</a>(\*\*<a href="src/supermemory/types/document_upload_file_params.py">params</a>) -> <a href="./src/supermemory/types/document_upload_file_response.py">DocumentUploadFileResponse</a></code>

# Profile

Types:

```python
from supermemory.types import ProfilePropertyResponse
```

Methods:

- <code title="post /v4/profile">client.profile.<a href="./src/supermemory/resources/profile.py">property</a>(\*\*<a href="src/supermemory/types/profile_property_params.py">params</a>) -> <a href="./src/supermemory/types/profile_property_response.py">ProfilePropertyResponse</a></code>

# Search

Types:
Expand Down
14 changes: 9 additions & 5 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "supermemory"
version = "3.4.0"
version = "3.5.0"
description = "The official Python library for the supermemory API"
dynamic = ["readme"]
license = "Apache-2.0"
Expand All @@ -15,16 +15,16 @@ dependencies = [
"distro>=1.7.0, <2",
"sniffio",
]
requires-python = ">= 3.8"
requires-python = ">= 3.9"
classifiers = [
"Typing :: Typed",
"Intended Audience :: Developers",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Programming Language :: Python :: 3.14",
"Operating System :: OS Independent",
"Operating System :: POSIX",
"Operating System :: MacOS",
Expand All @@ -39,7 +39,7 @@ Homepage = "https://github.com/supermemoryai/python-sdk"
Repository = "https://github.com/supermemoryai/python-sdk"

[project.optional-dependencies]
aiohttp = ["aiohttp", "httpx_aiohttp>=0.1.8"]
aiohttp = ["aiohttp", "httpx_aiohttp>=0.1.9"]

[tool.rye]
managed = true
Expand Down Expand Up @@ -141,7 +141,7 @@ filterwarnings = [
# there are a couple of flags that are still disabled by
# default in strict mode as they are experimental and niche.
typeCheckingMode = "strict"
pythonVersion = "3.8"
pythonVersion = "3.9"

exclude = [
"_dev",
Expand Down Expand Up @@ -224,6 +224,8 @@ select = [
"B",
# remove unused imports
"F401",
# check for missing future annotations
"FA102",
# bare except statements
"E722",
# unused arguments
Expand All @@ -246,6 +248,8 @@ unfixable = [
"T203",
]

extend-safe-fixes = ["FA102"]

[tool.ruff.lint.flake8-tidy-imports.banned-api]
"functools.lru_cache".msg = "This function does not retain type information for the wrapped function's arguments; The `lru_cache` function from `_utils` should be used instead"

Expand Down
2 changes: 1 addition & 1 deletion requirements-dev.lock
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ httpx==0.28.1
# via httpx-aiohttp
# via respx
# via supermemory
httpx-aiohttp==0.1.8
httpx-aiohttp==0.1.9
# via supermemory
idna==3.4
# via anyio
Expand Down
2 changes: 1 addition & 1 deletion requirements.lock
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ httpcore==1.0.9
httpx==0.28.1
# via httpx-aiohttp
# via supermemory
httpx-aiohttp==0.1.8
httpx-aiohttp==0.1.9
# via supermemory
idna==3.4
# via anyio
Expand Down
10 changes: 9 additions & 1 deletion src/supermemory/_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
)
from ._utils import is_given, get_async_library
from ._version import __version__
from .resources import search, memories, settings, documents, connections
from .resources import search, profile, memories, settings, documents, connections
from ._streaming import Stream as Stream, AsyncStream as AsyncStream
from ._exceptions import APIStatusError, SupermemoryError
from ._base_client import (
Expand All @@ -45,6 +45,7 @@
class Supermemory(SyncAPIClient):
memories: memories.MemoriesResource
documents: documents.DocumentsResource
profile: profile.ProfileResource
search: search.SearchResource
settings: settings.SettingsResource
connections: connections.ConnectionsResource
Expand Down Expand Up @@ -107,6 +108,7 @@ def __init__(

self.memories = memories.MemoriesResource(self)
self.documents = documents.DocumentsResource(self)
self.profile = profile.ProfileResource(self)
self.search = search.SearchResource(self)
self.settings = settings.SettingsResource(self)
self.connections = connections.ConnectionsResource(self)
Expand Down Expand Up @@ -221,6 +223,7 @@ def _make_status_error(
class AsyncSupermemory(AsyncAPIClient):
memories: memories.AsyncMemoriesResource
documents: documents.AsyncDocumentsResource
profile: profile.AsyncProfileResource
search: search.AsyncSearchResource
settings: settings.AsyncSettingsResource
connections: connections.AsyncConnectionsResource
Expand Down Expand Up @@ -283,6 +286,7 @@ def __init__(

self.memories = memories.AsyncMemoriesResource(self)
self.documents = documents.AsyncDocumentsResource(self)
self.profile = profile.AsyncProfileResource(self)
self.search = search.AsyncSearchResource(self)
self.settings = settings.AsyncSettingsResource(self)
self.connections = connections.AsyncConnectionsResource(self)
Expand Down Expand Up @@ -398,6 +402,7 @@ class SupermemoryWithRawResponse:
def __init__(self, client: Supermemory) -> None:
self.memories = memories.MemoriesResourceWithRawResponse(client.memories)
self.documents = documents.DocumentsResourceWithRawResponse(client.documents)
self.profile = profile.ProfileResourceWithRawResponse(client.profile)
self.search = search.SearchResourceWithRawResponse(client.search)
self.settings = settings.SettingsResourceWithRawResponse(client.settings)
self.connections = connections.ConnectionsResourceWithRawResponse(client.connections)
Expand All @@ -407,6 +412,7 @@ class AsyncSupermemoryWithRawResponse:
def __init__(self, client: AsyncSupermemory) -> None:
self.memories = memories.AsyncMemoriesResourceWithRawResponse(client.memories)
self.documents = documents.AsyncDocumentsResourceWithRawResponse(client.documents)
self.profile = profile.AsyncProfileResourceWithRawResponse(client.profile)
self.search = search.AsyncSearchResourceWithRawResponse(client.search)
self.settings = settings.AsyncSettingsResourceWithRawResponse(client.settings)
self.connections = connections.AsyncConnectionsResourceWithRawResponse(client.connections)
Expand All @@ -416,6 +422,7 @@ class SupermemoryWithStreamedResponse:
def __init__(self, client: Supermemory) -> None:
self.memories = memories.MemoriesResourceWithStreamingResponse(client.memories)
self.documents = documents.DocumentsResourceWithStreamingResponse(client.documents)
self.profile = profile.ProfileResourceWithStreamingResponse(client.profile)
self.search = search.SearchResourceWithStreamingResponse(client.search)
self.settings = settings.SettingsResourceWithStreamingResponse(client.settings)
self.connections = connections.ConnectionsResourceWithStreamingResponse(client.connections)
Expand All @@ -425,6 +432,7 @@ class AsyncSupermemoryWithStreamedResponse:
def __init__(self, client: AsyncSupermemory) -> None:
self.memories = memories.AsyncMemoriesResourceWithStreamingResponse(client.memories)
self.documents = documents.AsyncDocumentsResourceWithStreamingResponse(client.documents)
self.profile = profile.AsyncProfileResourceWithStreamingResponse(client.profile)
self.search = search.AsyncSearchResourceWithStreamingResponse(client.search)
self.settings = settings.AsyncSettingsResourceWithStreamingResponse(client.settings)
self.connections = connections.AsyncConnectionsResourceWithStreamingResponse(client.connections)
Expand Down
Loading
Loading