MCPcopy Create free account
hub / github.com/AQ-MedAI/MedMemoryBench / get_block

Method get_block

methods/letta/client/client.py:1105–1111  ·  view source on GitHub ↗
(self, block_id: str)

Source from the content-addressed store, hash-verified

1103 return Block(**response.json())
1104
1105 def get_block(self, block_id: str) -> Optional[Block]:
1106 response = requests.get(f"{self.base_url}/{self.api_prefix}/blocks/{block_id}", headers=self.headers)
1107 if response.status_code == 404:
1108 return None
1109 elif response.status_code != 200:
1110 raise ValueError(f"Failed to get block: {response.text}")
1111 return Block(**response.json())
1112
1113 def get_block_id(self, name: str, label: str) -> str:
1114 params = {"name": name, "label": label}

Callers 4

update_blockMethod · 0.95
get_personaMethod · 0.95
get_humanMethod · 0.95
listFunction · 0.45

Calls 3

BlockClass · 0.90
getMethod · 0.45
jsonMethod · 0.45

Tested by

no test coverage detected