Skip to content

Commit 08ffef9

Browse files
feat(api): api update
1 parent dadfa9f commit 08ffef9

File tree

3 files changed

+22
-22
lines changed

3 files changed

+22
-22
lines changed

.stats.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
configured_endpoints: 15
2-
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/supermemory--inc%2Fsupermemory-new-0e2874da641d72b5833ebef8cc792d86250d397b96eeedba7d4759ffabc076de.yml
3-
openapi_spec_hash: f13ea02b49134e11025cb18f3d45d313
2+
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/supermemory--inc%2Fsupermemory-new-cce7bb1b7a1050f38b133f61e37f61f47027d357c5cab4288964debeffbc8cb5.yml
3+
openapi_spec_hash: 04e56c24ba345f177419422d70a82f08
44
config_hash: 98555becb03f89d0fcf2e35a0fa6a41b

tests/api_resources/test_memories.py

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -40,12 +40,12 @@ def test_method_update_with_all_params(self, client: Supermemory) -> None:
4040
container_tags=["user_123", "project_123"],
4141
custom_id="mem_abc123",
4242
metadata={
43-
"source": "web",
4443
"category": "technology",
44+
"isPublic": True,
45+
"readingTime": 5,
46+
"source": "web",
4547
"tag_1": "ai",
4648
"tag_2": "machine-learning",
47-
"readingTime": 5,
48-
"isPublic": True,
4949
},
5050
)
5151
assert_matches_type(MemoryUpdateResponse, memory, path=["response"])
@@ -98,7 +98,7 @@ def test_method_list(self, client: Supermemory) -> None:
9898
def test_method_list_with_all_params(self, client: Supermemory) -> None:
9999
memory = client.memories.list(
100100
container_tags=["user_123", "project_123"],
101-
filters='{"AND":[{"key":"group","value":"jira_users","negate":false},{"filterType":"numeric","key":"timestamp","value":"1742745777","negate":false,"numericOperator":">"}]}',
101+
filters='{"AND":[{"key":"group","negate":false,"value":"jira_users"},{"filterType":"numeric","key":"timestamp","negate":false,"numericOperator":">","value":"1742745777"}]}',
102102
limit=10,
103103
order="desc",
104104
page=1,
@@ -186,12 +186,12 @@ def test_method_add_with_all_params(self, client: Supermemory) -> None:
186186
container_tags=["user_123", "project_123"],
187187
custom_id="mem_abc123",
188188
metadata={
189-
"source": "web",
190189
"category": "technology",
190+
"isPublic": True,
191+
"readingTime": 5,
192+
"source": "web",
191193
"tag_1": "ai",
192194
"tag_2": "machine-learning",
193-
"readingTime": 5,
194-
"isPublic": True,
195195
},
196196
)
197197
assert_matches_type(MemoryAddResponse, memory, path=["response"])
@@ -288,12 +288,12 @@ async def test_method_update_with_all_params(self, async_client: AsyncSupermemor
288288
container_tags=["user_123", "project_123"],
289289
custom_id="mem_abc123",
290290
metadata={
291-
"source": "web",
292291
"category": "technology",
292+
"isPublic": True,
293+
"readingTime": 5,
294+
"source": "web",
293295
"tag_1": "ai",
294296
"tag_2": "machine-learning",
295-
"readingTime": 5,
296-
"isPublic": True,
297297
},
298298
)
299299
assert_matches_type(MemoryUpdateResponse, memory, path=["response"])
@@ -346,7 +346,7 @@ async def test_method_list(self, async_client: AsyncSupermemory) -> None:
346346
async def test_method_list_with_all_params(self, async_client: AsyncSupermemory) -> None:
347347
memory = await async_client.memories.list(
348348
container_tags=["user_123", "project_123"],
349-
filters='{"AND":[{"key":"group","value":"jira_users","negate":false},{"filterType":"numeric","key":"timestamp","value":"1742745777","negate":false,"numericOperator":">"}]}',
349+
filters='{"AND":[{"key":"group","negate":false,"value":"jira_users"},{"filterType":"numeric","key":"timestamp","negate":false,"numericOperator":">","value":"1742745777"}]}',
350350
limit=10,
351351
order="desc",
352352
page=1,
@@ -434,12 +434,12 @@ async def test_method_add_with_all_params(self, async_client: AsyncSupermemory)
434434
container_tags=["user_123", "project_123"],
435435
custom_id="mem_abc123",
436436
metadata={
437-
"source": "web",
438437
"category": "technology",
438+
"isPublic": True,
439+
"readingTime": 5,
440+
"source": "web",
439441
"tag_1": "ai",
440442
"tag_2": "machine-learning",
441-
"readingTime": 5,
442-
"isPublic": True,
443443
},
444444
)
445445
assert_matches_type(MemoryAddResponse, memory, path=["response"])

tests/api_resources/test_search.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -39,15 +39,15 @@ def test_method_execute_with_all_params(self, client: Supermemory) -> None:
3939
"and_": [
4040
{
4141
"key": "group",
42-
"value": "jira_users",
4342
"negate": False,
43+
"value": "jira_users",
4444
},
4545
{
4646
"filterType": "numeric",
4747
"key": "timestamp",
48-
"value": "1742745777",
4948
"negate": False,
5049
"numericOperator": ">",
50+
"value": "1742745777",
5151
},
5252
],
5353
"or_": [{}],
@@ -57,7 +57,7 @@ def test_method_execute_with_all_params(self, client: Supermemory) -> None:
5757
limit=10,
5858
only_matching_chunks=False,
5959
rerank=False,
60-
rewrite_query=False,
60+
rewrite_query=True,
6161
)
6262
assert_matches_type(SearchExecuteResponse, search, path=["response"])
6363

@@ -115,15 +115,15 @@ async def test_method_execute_with_all_params(self, async_client: AsyncSupermemo
115115
"and_": [
116116
{
117117
"key": "group",
118-
"value": "jira_users",
119118
"negate": False,
119+
"value": "jira_users",
120120
},
121121
{
122122
"filterType": "numeric",
123123
"key": "timestamp",
124-
"value": "1742745777",
125124
"negate": False,
126125
"numericOperator": ">",
126+
"value": "1742745777",
127127
},
128128
],
129129
"or_": [{}],
@@ -133,7 +133,7 @@ async def test_method_execute_with_all_params(self, async_client: AsyncSupermemo
133133
limit=10,
134134
only_matching_chunks=False,
135135
rerank=False,
136-
rewrite_query=False,
136+
rewrite_query=True,
137137
)
138138
assert_matches_type(SearchExecuteResponse, search, path=["response"])
139139

0 commit comments

Comments
 (0)