mgraph-ai-service-cache-client 0.1.3__py3-none-any.whl → 0.2.0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of mgraph-ai-service-cache-client might be problematic. Click here for more details.

Files changed (51) hide show
  1. mgraph_ai_service_cache_client/client/Cache__Client.py +6 -0
  2. mgraph_ai_service_cache_client/client/Cache__Client__Config.py +7 -0
  3. mgraph_ai_service_cache_client/client/Cache__Client__Health_Checks.py +38 -0
  4. mgraph_ai_service_cache_client/client/Cache__Client__Requests.py +50 -0
  5. mgraph_ai_service_cache_client/client_builder/Fast_API__Client__Builder.py +49 -0
  6. mgraph_ai_service_cache_client/client_contract/Service__Fast_API__Client.py +77 -0
  7. mgraph_ai_service_cache_client/client_contract/Service__Fast_API__Client__Config.py +14 -0
  8. mgraph_ai_service_cache_client/client_contract/Service__Fast_API__Client__Requests.py +146 -0
  9. mgraph_ai_service_cache_client/client_contract/__init__.py +1 -0
  10. mgraph_ai_service_cache_client/client_contract/admin_storage/Service__Fast_API__Client__Admin__Storage.py +113 -0
  11. mgraph_ai_service_cache_client/client_contract/auth/Service__Fast_API__Client__Set_Cookie.py +35 -0
  12. mgraph_ai_service_cache_client/client_contract/data/Service__Fast_API__Client__Data.py +17 -0
  13. mgraph_ai_service_cache_client/client_contract/data/Service__Fast_API__Client__Data__Delete.py +63 -0
  14. mgraph_ai_service_cache_client/client_contract/data/Service__Fast_API__Client__Data__Retrieve.py +87 -0
  15. mgraph_ai_service_cache_client/client_contract/data_store/Service__Fast_API__Client__Data__Store.py +148 -0
  16. mgraph_ai_service_cache_client/client_contract/delete/Service__Fast_API__Client__File__Delete.py +22 -0
  17. mgraph_ai_service_cache_client/client_contract/exists/Service__Fast_API__Client__File__Exists.py +22 -0
  18. mgraph_ai_service_cache_client/client_contract/info/Service__Fast_API__Client__Info.py +64 -0
  19. mgraph_ai_service_cache_client/client_contract/namespace/Service__Fast_API__Client__Namespace.py +48 -0
  20. mgraph_ai_service_cache_client/client_contract/retrieve/Service__Fast_API__Client__File__Retrieve.py +169 -0
  21. mgraph_ai_service_cache_client/client_contract/server/Service__Fast_API__Client__Server.py +35 -0
  22. mgraph_ai_service_cache_client/client_contract/store/Service__Fast_API__Client__File__Store.py +104 -0
  23. mgraph_ai_service_cache_client/client_contract/zip/Service__Fast_API__Client__Zip.py +129 -0
  24. mgraph_ai_service_cache_client/schemas/cache/Schema__Cache__Exists__Response.py +1 -1
  25. mgraph_ai_service_cache_client/schemas/cache/enums/Enum__Cache__Store__Strategy.py +3 -0
  26. mgraph_ai_service_cache_client/schemas/client/Cache__Client__Requests__Result.py +26 -0
  27. mgraph_ai_service_cache_client/schemas/client/health_checks/Client__Check__Target_Server__Auth.py +7 -0
  28. mgraph_ai_service_cache_client/schemas/client/health_checks/Client__Check__Target_Server__Status.py +11 -0
  29. mgraph_ai_service_cache_client/schemas/client_builder/Schema__Fast_API__Client__Server__Details.py +9 -0
  30. mgraph_ai_service_cache_client/schemas/client_builder/__init__.py +0 -0
  31. mgraph_ai_service_cache_client/schemas/consts/consts__Cache_Client.py +3 -0
  32. mgraph_ai_service_cache_client/schemas/errors/Schema__Cache__Error__Gone.py +2 -2
  33. mgraph_ai_service_cache_client/schemas/errors/Schema__Cache__Error__Not_Found.py +4 -4
  34. mgraph_ai_service_cache_client/version +1 -1
  35. {mgraph_ai_service_cache_client-0.1.3.dist-info → mgraph_ai_service_cache_client-0.2.0.dist-info}/METADATA +3 -2
  36. {mgraph_ai_service_cache_client-0.1.3.dist-info → mgraph_ai_service_cache_client-0.2.0.dist-info}/RECORD +41 -22
  37. mgraph_ai_service_cache_client/config.py +0 -6
  38. mgraph_ai_service_cache_client/fast_api/Cache_Client__Fast_API.py +0 -15
  39. mgraph_ai_service_cache_client/fast_api/lambda_handler.py +0 -26
  40. mgraph_ai_service_cache_client/fast_api/routes/Routes__Info.py +0 -32
  41. mgraph_ai_service_cache_client/service/info/Service_Info.py +0 -23
  42. mgraph_ai_service_cache_client/service/info/schemas/Enum__Service_Environment.py +0 -6
  43. mgraph_ai_service_cache_client/service/info/schemas/Enum__Service_Status.py +0 -5
  44. mgraph_ai_service_cache_client/service/info/schemas/Schema__Server__Versions.py +0 -15
  45. mgraph_ai_service_cache_client/service/info/schemas/Schema__Service__Status.py +0 -14
  46. mgraph_ai_service_cache_client/utils/deploy/Deploy__Service.py +0 -20
  47. /mgraph_ai_service_cache_client/{fast_api → client}/__init__.py +0 -0
  48. /mgraph_ai_service_cache_client/{fast_api/routes → client_builder}/__init__.py +0 -0
  49. /mgraph_ai_service_cache_client/{service → schemas/client}/__init__.py +0 -0
  50. {mgraph_ai_service_cache_client-0.1.3.dist-info → mgraph_ai_service_cache_client-0.2.0.dist-info}/LICENSE +0 -0
  51. {mgraph_ai_service_cache_client-0.1.3.dist-info → mgraph_ai_service_cache_client-0.2.0.dist-info}/WHEEL +0 -0
@@ -0,0 +1,87 @@
1
+ from typing import Any, Dict
2
+ from osbot_utils.type_safe.Type_Safe import Type_Safe
3
+
4
+ class Service__Fast_API__Client__Data__Retrieve(Type_Safe):
5
+ _client: Any # Reference to main client
6
+
7
+ @property
8
+ def requests(self): # Access the unified request handler
9
+ return self._client.requests()
10
+
11
+ def data__json__with__id(self, cache_id: str, namespace: str, data_file_id: str) -> Dict: # Auto-generated from endpoint get__data__json__with__id
12
+ # Build path
13
+ path = f"/{namespace}/cache/{cache_id}/data/json/{data_file_id}"
14
+ body = None
15
+ # Execute request
16
+ result = self.requests.execute(
17
+ method = "GET",
18
+ path = path,
19
+ body = body
20
+ )
21
+ # Return response data
22
+ return result.json if result.json else result.text
23
+
24
+ def data__json__with__id_and_key(self, cache_id: str, namespace: str, data_key: str, data_file_id: str) -> Dict: # Auto-generated from endpoint get__data__json__with__id_and_key
25
+ # Build path
26
+ path = f"/{namespace}/cache/{cache_id}/data/json/{data_key}/{data_file_id}"
27
+ body = None
28
+ # Execute request
29
+ result = self.requests.execute(
30
+ method = "GET",
31
+ path = path,
32
+ body = body
33
+ )
34
+ # Return response data
35
+ return result.json if result.json else result.text
36
+
37
+ def data__string__with__id(self, cache_id: str, namespace: str, data_file_id: str) -> Dict: # Auto-generated from endpoint get__data__string__with__id
38
+ # Build path
39
+ path = f"/{namespace}/cache/{cache_id}/data/string/{data_file_id}"
40
+ body = None
41
+ # Execute request
42
+ result = self.requests.execute(
43
+ method = "GET",
44
+ path = path,
45
+ body = body
46
+ )
47
+ # Return response data
48
+ return result.json if result.json else result.text
49
+
50
+ def data__string__with__id_and_key(self, cache_id: str, namespace: str, data_key: str, data_file_id: str) -> Dict: # Auto-generated from endpoint get__data__string__with__id_and_key
51
+ # Build path
52
+ path = f"/{namespace}/cache/{cache_id}/data/string/{data_key}/{data_file_id}"
53
+ body = None
54
+ # Execute request
55
+ result = self.requests.execute(
56
+ method = "GET",
57
+ path = path,
58
+ body = body
59
+ )
60
+ # Return response data
61
+ return result.json if result.json else result.text
62
+
63
+ def data__binary__with__id(self, cache_id: str, namespace: str, data_file_id: str) -> Dict: # Auto-generated from endpoint get__data__binary__with__id
64
+ # Build path
65
+ path = f"/{namespace}/cache/{cache_id}/data/binary/{data_file_id}"
66
+ body = None
67
+ # Execute request
68
+ result = self.requests.execute(
69
+ method = "GET",
70
+ path = path,
71
+ body = body
72
+ )
73
+ return result.content
74
+ #return result.json if result.json else result.text # Return response data
75
+
76
+ def data__binary__with__id_and_key(self, cache_id: str, namespace: str, data_key: str, data_file_id: str) -> Dict: # Auto-generated from endpoint get__data__binary__with__id_and_key
77
+ # Build path
78
+ path = f"/{namespace}/cache/{cache_id}/data/binary/{data_key}/{data_file_id}"
79
+ body = None
80
+ # Execute request
81
+ result = self.requests.execute(
82
+ method = "GET",
83
+ path = path,
84
+ body = body
85
+ )
86
+ return result.content
87
+ return result.json if result.json else result.text # Return response data
@@ -0,0 +1,148 @@
1
+ from typing import Any, Dict
2
+ from osbot_utils.type_safe.Type_Safe import Type_Safe
3
+ from osbot_utils.type_safe.primitives.domains.files.safe_str.Safe_Str__File__Path import Safe_Str__File__Path
4
+ from osbot_utils.type_safe.primitives.domains.identifiers.safe_str.Safe_Str__Id import Safe_Str__Id
5
+
6
+
7
+ class Service__Fast_API__Client__Data__Store(Type_Safe):
8
+ _client: Any # Reference to main client
9
+
10
+ @property
11
+ def requests(self): # Access the unified request handler
12
+ return self._client.requests()
13
+
14
+ def data__store_binary(self, cache_id: str, namespace: str, body:bytes) -> Dict: # Auto-generated from endpoint post__data__store_binary
15
+ # Build path
16
+ path = f"/{namespace}/cache/{cache_id}/data/store/binary"
17
+ #body = None
18
+ # Execute request
19
+ result = self.requests.execute(
20
+ method = "POST",
21
+ path = path,
22
+ body = body
23
+ )
24
+ # Return response data
25
+ return result.json if result.json else result.text
26
+
27
+ def data__store_binary__with__id(self, cache_id: str, namespace: str, data_file_id: str, body:bytes) -> Dict: # Auto-generated from endpoint post__data__store_binary__with__id
28
+ # Build path
29
+ path = f"/{namespace}/cache/{cache_id}/data/store/binary/{data_file_id}"
30
+ #body = None
31
+ # Execute request
32
+ result = self.requests.execute(
33
+ method = "POST",
34
+ path = path,
35
+ body = body
36
+ )
37
+ # Return response data
38
+ return result.json if result.json else result.text
39
+
40
+ def data__store_binary__with__id_and_key(self, cache_id: str, namespace: str, data_key: str, data_file_id: str, body:bytes) -> Dict: # Auto-generated from endpoint post__data__store_binary__with__id_and_key
41
+ # Build path
42
+ path = f"/{namespace}/cache/{cache_id}/data/store/binary/{data_key}/{data_file_id}"
43
+ #body = None
44
+ # Execute request
45
+ result = self.requests.execute(
46
+ method = "POST",
47
+ path = path,
48
+ body = body
49
+ )
50
+ # Return response data
51
+ return result.json if result.json else result.text
52
+
53
+ def data__store_json(self, cache_id: str, namespace: str, body:dict) -> Dict: # Auto-generated from endpoint post__data__store_json
54
+ # Build path
55
+ #path = f"/{{namespace}}/cache/{{cache_id}}/data/store/json"
56
+ path = f"/{namespace}/cache/{cache_id}/data/store/json"
57
+ #body = None
58
+ # Execute request
59
+ result = self.requests.execute(
60
+ method = "POST",
61
+ path = path,
62
+ body = body
63
+ )
64
+ # Return response data
65
+ return result.json if result.json else result.text
66
+
67
+ def data__store_json__with__id(self, cache_id: str, namespace: str, data_file_id: str, body:dict) -> Dict: # Auto-generated from endpoint post__data__store_json__with__id
68
+ # Build path
69
+ path = f"/{namespace}/cache/{cache_id}/data/store/json/{data_file_id}"
70
+ #body = None
71
+ # Execute request
72
+ result = self.requests.execute(
73
+ method = "POST",
74
+ path = path,
75
+ body = body
76
+ )
77
+ # Return response data
78
+ return result.json if result.json else result.text
79
+
80
+ def data__store_json__with__id_and_key(self, cache_id: str,
81
+ namespace: str, data_key: str,
82
+ data_file_id: str,
83
+ body: dict) -> Dict: # Auto-generated from endpoint post__data__store_json__with__id_and_key
84
+ # Build path
85
+ path = f"/{namespace}/cache/{cache_id}/data/store/json/{data_key}/{data_file_id}"
86
+ #body = None
87
+ # Execute request
88
+ result = self.requests.execute(
89
+ method = "POST",
90
+ path = path,
91
+ body = body
92
+ )
93
+ # Return response data
94
+ return result.json if result.json else result.text
95
+
96
+ #def data__store_string(self, cache_id: str, namespace: str) -> Dict: # todo: BUG same as the others
97
+ def data__store_string(self, cache_id: str, namespace: Safe_Str__Id, body:str) -> Dict:
98
+ # Build path
99
+ #path = f"/{{namespace}}/cache/{{cache_id}}/data/store/string" # BUG
100
+ #body = None
101
+ path = f"/{namespace}/cache/{cache_id}/data/store/string"
102
+ # Execute request
103
+ result = self.requests.execute(
104
+ method = "POST",
105
+ path = path,
106
+ body = body
107
+ )
108
+ # Return response data
109
+ return result.json if result.json else result.text
110
+
111
+ #def data__store_string__with__id(self, cache_id: str, namespace: str, data_file_id: str) -> Dict: # Auto-generated from endpoint post__data__store_string__with__id
112
+ def data__store_string__with__id(self, cache_id : str,
113
+ namespace : Safe_Str__Id,
114
+ data_file_id : Safe_Str__Id,
115
+ body : str
116
+ ) -> Dict: # Auto-generated from endpoint post__data__store_string__with__id
117
+
118
+ #path = f"/{{namespace}}/cache/{{cache_id}}/data/store/string/{{data_file_id}}" # Build path
119
+ path = f"/{namespace}/cache/{cache_id}/data/store/string/{data_file_id}" # Build path
120
+ #body = None
121
+ # Execute request
122
+ result = self.requests.execute(
123
+ method = "POST",
124
+ path = path,
125
+ body = body
126
+ )
127
+ # Return response data
128
+ return result.json if result.json else result.text
129
+
130
+ #def data__store_string__with__id_and_key(self, cache_id: str, namespace: str, data_key: str, data_file_id: str) -> Dict: # Auto-generated from endpoint post__data__store_string__with__id_and_key
131
+ def data__store_string__with__id_and_key(self, cache_id : str ,
132
+ namespace : Safe_Str__Id ,
133
+ data_key : Safe_Str__File__Path ,
134
+ data_file_id : Safe_Str__Id ,
135
+ body: str
136
+ ) -> Dict: # Auto-generated from endpoint post__data__store_string__with__id_and_key
137
+
138
+ #path = f"/{{namespace}}/cache/{{cache_id}}/data/store/string/{data_key:path}/{{data_file_id}}" # Build path
139
+ path = f"/{namespace}/cache/{cache_id}/data/store/string/{data_key}/{data_file_id}" # Build path
140
+ #body = None
141
+ # Execute request
142
+ result = self.requests.execute(
143
+ method = "POST",
144
+ path = path,
145
+ body = body
146
+ )
147
+ # Return response data
148
+ return result.json if result.json else result.text
@@ -0,0 +1,22 @@
1
+ from typing import Any, Optional, Dict
2
+ from osbot_utils.type_safe.Type_Safe import Type_Safe
3
+
4
+ class Service__Fast_API__Client__File__Delete(Type_Safe):
5
+ _client: Any # Reference to main client
6
+
7
+ @property
8
+ def requests(self): # Access the unified request handler
9
+ return self._client.requests()
10
+
11
+ def delete__cache_id(self, cache_id: str, namespace: str) -> Dict: # Auto-generated from endpoint delete__delete__cache_id
12
+ # Build path
13
+ path = f"/{{namespace}}/delete/{{cache_id}}"
14
+ body = None
15
+ # Execute request
16
+ result = self.requests.execute(
17
+ method = "DELETE",
18
+ path = path,
19
+ body = body
20
+ )
21
+ # Return response data
22
+ return result.json if result.json else result.text
@@ -0,0 +1,22 @@
1
+ from typing import Any, Optional, Dict
2
+ from osbot_utils.type_safe.Type_Safe import Type_Safe
3
+
4
+ class Service__Fast_API__Client__File__Exists(Type_Safe):
5
+ _client: Any # Reference to main client
6
+
7
+ @property
8
+ def requests(self): # Access the unified request handler
9
+ return self._client.requests()
10
+
11
+ def exists__hash__cache_hash(self, cache_hash: str, namespace: str) -> Dict: # Auto-generated from endpoint get__exists__hash__cache_hash
12
+ # Build path
13
+ path = f"/{{namespace}}/exists/hash/{{cache_hash}}"
14
+ body = None
15
+ # Execute request
16
+ result = self.requests.execute(
17
+ method = "GET",
18
+ path = path,
19
+ body = body
20
+ )
21
+ # Return response data
22
+ return result.json if result.json else result.text
@@ -0,0 +1,64 @@
1
+ from typing import Any, Optional, Dict
2
+ from osbot_utils.type_safe.Type_Safe import Type_Safe
3
+
4
+
5
+ class Service__Fast_API__Client__Info(Type_Safe):
6
+ _client: Any # todo: BUG: was Any and started with _
7
+ #client : Service__Fast_API__Client # todo: BUG: fix circular dependency on Service__Fast_API__Client
8
+
9
+ @property
10
+ def requests(self): # Access the unified request handler
11
+ #return self._client.requests() # todo: BUG: used _client
12
+ return self._client.requests()
13
+
14
+ def health(self) -> Dict: # Auto-generated from endpoint get__health
15
+ # Build path
16
+ path = "/info/health"
17
+ body = None
18
+ # Execute request
19
+ result = self.requests.execute(
20
+ method = "GET",
21
+ path = path,
22
+ body = body
23
+ )
24
+ # Return response data
25
+ return result.json if result.json else result.text
26
+
27
+ def server(self) -> Dict: # Auto-generated from endpoint get__server
28
+ # Build path
29
+ path = "/info/server"
30
+ body = None
31
+ # Execute request
32
+ result = self.requests.execute(
33
+ method = "GET",
34
+ path = path,
35
+ body = body
36
+ )
37
+ # Return response data
38
+ return result.json if result.json else result.text
39
+
40
+ def status(self) -> Dict: # Auto-generated from endpoint get__status
41
+ # Build path
42
+ path = "/info/status"
43
+ body = None
44
+ # Execute request
45
+ result = self.requests.execute(
46
+ method = "GET",
47
+ path = path,
48
+ body = body
49
+ )
50
+ # Return response data
51
+ return result.json if result.json else result.text
52
+
53
+ def versions(self) -> Dict: # Auto-generated from endpoint get__versions
54
+ # Build path
55
+ path = "/info/versions"
56
+ body = None
57
+ # Execute request
58
+ result = self.requests.execute(
59
+ method = "GET",
60
+ path = path,
61
+ body = body
62
+ )
63
+ # Return response data
64
+ return result.json if result.json else result.text
@@ -0,0 +1,48 @@
1
+ from typing import Any, Optional, Dict
2
+ from osbot_utils.type_safe.Type_Safe import Type_Safe
3
+
4
+ class Service__Fast_API__Client__Namespace(Type_Safe):
5
+ _client: Any # Reference to main client
6
+
7
+ @property
8
+ def requests(self): # Access the unified request handler
9
+ return self._client.requests()
10
+
11
+ def file_hashes(self, namespace: str) -> Dict: # Auto-generated from endpoint get__file_hashes
12
+ # Build path
13
+ path = f"/{{namespace}}/file-hashes"
14
+ body = None
15
+ # Execute request
16
+ result = self.requests.execute(
17
+ method = "GET",
18
+ path = path,
19
+ body = body
20
+ )
21
+ # Return response data
22
+ return result.json if result.json else result.text
23
+
24
+ def file_ids(self, namespace: str) -> Dict: # Auto-generated from endpoint get__file_ids
25
+ # Build path
26
+ path = f"/{{namespace}}/file-ids"
27
+ body = None
28
+ # Execute request
29
+ result = self.requests.execute(
30
+ method = "GET",
31
+ path = path,
32
+ body = body
33
+ )
34
+ # Return response data
35
+ return result.json if result.json else result.text
36
+
37
+ def stats(self, namespace: str) -> Dict: # Auto-generated from endpoint get__stats
38
+ # Build path
39
+ path = f"/{{namespace}}/stats"
40
+ body = None
41
+ # Execute request
42
+ result = self.requests.execute(
43
+ method = "GET",
44
+ path = path,
45
+ body = body
46
+ )
47
+ # Return response data
48
+ return result.json if result.json else result.text
@@ -0,0 +1,169 @@
1
+ from typing import Any, Optional, Dict
2
+ from osbot_utils.type_safe.Type_Safe import Type_Safe
3
+
4
+ class Service__Fast_API__Client__File__Retrieve(Type_Safe):
5
+ _client: Any # Reference to main client
6
+
7
+ @property
8
+ def requests(self): # Access the unified request handler
9
+ return self._client.requests()
10
+
11
+ def retrieve__cache_id(self, cache_id: str, namespace: str) -> Dict: # Auto-generated from endpoint get__retrieve__cache_id
12
+ # Build path
13
+ path = f"/{{namespace}}/retrieve/{{cache_id}}"
14
+ body = None
15
+ # Execute request
16
+ result = self.requests.execute(
17
+ method = "GET",
18
+ path = path,
19
+ body = body
20
+ )
21
+ # Return response data
22
+ return result.json if result.json else result.text
23
+
24
+ def retrieve__cache_id__config(self, cache_id: str, namespace: str) -> Dict: # Auto-generated from endpoint get__retrieve__cache_id__config
25
+ # Build path
26
+ path = f"/{{namespace}}/retrieve/{{cache_id}}/config"
27
+ body = None
28
+ # Execute request
29
+ result = self.requests.execute(
30
+ method = "GET",
31
+ path = path,
32
+ body = body
33
+ )
34
+ # Return response data
35
+ return result.json if result.json else result.text
36
+
37
+ def retrieve__cache_id__metadata(self, cache_id: str, namespace: str) -> Dict: # Auto-generated from endpoint get__retrieve__cache_id__metadata
38
+ # Build path
39
+ path = f"/{{namespace}}/retrieve/{{cache_id}}/metadata"
40
+ body = None
41
+ # Execute request
42
+ result = self.requests.execute(
43
+ method = "GET",
44
+ path = path,
45
+ body = body
46
+ )
47
+ # Return response data
48
+ return result.json if result.json else result.text
49
+
50
+ def retrieve__cache_id__refs(self, cache_id: str, namespace: str) -> Dict: # Auto-generated from endpoint get__retrieve__cache_id__refs
51
+ # Build path
52
+ path = f"/{{namespace}}/retrieve/{{cache_id}}/refs"
53
+ body = None
54
+ # Execute request
55
+ result = self.requests.execute(
56
+ method = "GET",
57
+ path = path,
58
+ body = body
59
+ )
60
+ # Return response data
61
+ return result.json if result.json else result.text
62
+
63
+ def retrieve__cache_id__refs__all(self, cache_id: str, namespace: str) -> Dict: # Auto-generated from endpoint get__retrieve__cache_id__refs__all
64
+ # Build path
65
+ path = f"/{{namespace}}/retrieve/{{cache_id}}/refs/all"
66
+ body = None
67
+ # Execute request
68
+ result = self.requests.execute(
69
+ method = "GET",
70
+ path = path,
71
+ body = body
72
+ )
73
+ # Return response data
74
+ return result.json if result.json else result.text
75
+
76
+ def retrieve__hash__cache_hash(self, cache_hash: str, namespace: str) -> Dict: # Auto-generated from endpoint get__retrieve__hash__cache_hash
77
+ # Build path
78
+ path = f"/{{namespace}}/retrieve/hash/{{cache_hash}}"
79
+ body = None
80
+ # Execute request
81
+ result = self.requests.execute(
82
+ method = "GET",
83
+ path = path,
84
+ body = body
85
+ )
86
+ # Return response data
87
+ return result.json if result.json else result.text
88
+
89
+ def retrieve__cache_id__string(self, cache_id: str, namespace: str) -> Dict: # Auto-generated from endpoint get__retrieve__cache_id__string
90
+ # Build path
91
+ #path = f"/{{namespace}}/retrieve/{{cache_id}}/string" # todo: BUG: used {{
92
+ path = f"/{namespace}/retrieve/{cache_id}/string"
93
+ body = None
94
+ # Execute request
95
+ result = self.requests.execute(
96
+ method = "GET",
97
+ path = path,
98
+ body = body
99
+ )
100
+ # Return response data
101
+ return result.json if result.json else result.text
102
+
103
+ def retrieve__cache_id__json(self, cache_id: str, namespace: str) -> Dict: # Auto-generated from endpoint get__retrieve__cache_id__json
104
+ # Build path
105
+ #path = f"/{{namespace}}/retrieve/{{cache_id}}/json" # used {{
106
+ path = f"/{namespace}/retrieve/{cache_id}/json"
107
+ body = None
108
+ # Execute request
109
+ result = self.requests.execute(
110
+ method = "GET",
111
+ path = path,
112
+ body = body
113
+ )
114
+ # Return response data
115
+ return result.json if result.json else result.text
116
+
117
+ def retrieve__cache_id__binary(self, cache_id: str, namespace: str) -> Dict: # Auto-generated from endpoint get__retrieve__cache_id__binary
118
+ # Build path
119
+ #path = f"/{{namespace}}/retrieve/{{cache_id}}/binary" # todo: BUG: used {{
120
+ path = f"/{namespace}/retrieve/{cache_id}/binary"
121
+ body = None
122
+ # Execute request
123
+ result = self.requests.execute(
124
+ method = "GET",
125
+ path = path,
126
+ body = body
127
+ )
128
+ # Return response data
129
+ #return result.json if result.json else result.text # todo: BUG returned this
130
+ return result.content # and since this is binary we need to return the result.content
131
+
132
+ def retrieve__hash__cache_hash__string(self, cache_hash: str, namespace: str) -> Dict: # Auto-generated from endpoint get__retrieve__hash__cache_hash__string
133
+ # Build path
134
+ path = f"/{{namespace}}/retrieve/hash/{{cache_hash}}/string"
135
+ body = None
136
+ # Execute request
137
+ result = self.requests.execute(
138
+ method = "GET",
139
+ path = path,
140
+ body = body
141
+ )
142
+ # Return response data
143
+ return result.json if result.json else result.text
144
+
145
+ def retrieve__hash__cache_hash__json(self, cache_hash: str, namespace: str) -> Dict: # Auto-generated from endpoint get__retrieve__hash__cache_hash__json
146
+ # Build path
147
+ path = f"/{{namespace}}/retrieve/hash/{{cache_hash}}/json"
148
+ body = None
149
+ # Execute request
150
+ result = self.requests.execute(
151
+ method = "GET",
152
+ path = path,
153
+ body = body
154
+ )
155
+ # Return response data
156
+ return result.json if result.json else result.text
157
+
158
+ def retrieve__hash__cache_hash__binary(self, cache_hash: str, namespace: str) -> Dict: # Auto-generated from endpoint get__retrieve__hash__cache_hash__binary
159
+ # Build path
160
+ path = f"/{{namespace}}/retrieve/hash/{{cache_hash}}/binary"
161
+ body = None
162
+ # Execute request
163
+ result = self.requests.execute(
164
+ method = "GET",
165
+ path = path,
166
+ body = body
167
+ )
168
+ # Return response data
169
+ return result.json if result.json else result.text
@@ -0,0 +1,35 @@
1
+ from typing import Any, Optional, Dict
2
+ from osbot_utils.type_safe.Type_Safe import Type_Safe
3
+
4
+ class Service__Fast_API__Client__Server(Type_Safe):
5
+ _client: Any # Reference to main client
6
+
7
+ @property
8
+ def requests(self): # Access the unified request handler
9
+ return self._client.requests()
10
+
11
+ def storage__info(self) -> Dict: # Auto-generated from endpoint get__storage__info
12
+ # Build path
13
+ path = "/server/storage/info"
14
+ body = None
15
+ # Execute request
16
+ result = self.requests.execute(
17
+ method = "GET",
18
+ path = path,
19
+ body = body
20
+ )
21
+ # Return response data
22
+ return result.json if result.json else result.text
23
+
24
+ def create__test_fixtures(self) -> Dict: # Auto-generated from endpoint get__create__test_fixtures
25
+ # Build path
26
+ path = "/server/create/test-fixtures"
27
+ body = None
28
+ # Execute request
29
+ result = self.requests.execute(
30
+ method = "GET",
31
+ path = path,
32
+ body = body
33
+ )
34
+ # Return response data
35
+ return result.json if result.json else result.text