Skip to content

Commit

Permalink
Add update_conversation_message
Browse files Browse the repository at this point in the history
  • Loading branch information
Josh-XT committed Feb 1, 2024
1 parent 1ef1ad6 commit a20c034
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 1 deletion.
18 changes: 18 additions & 0 deletions agixtsdk/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -236,6 +236,24 @@ def delete_conversation_message(
except Exception as e:
return self.handle_error(e)

def update_conversation_message(
self, agent_name: str, conversation_name: str, message: str, new_message: str
) -> str:
try:
response = requests.put(
headers=self.headers,
url=f"{self.base_uri}/api/conversation/message",
json={
"message": message,
"new_message": new_message,
"agent_name": agent_name,
"conversation_name": conversation_name,
},
)
return response.json()["message"]
except Exception as e:
return self.handle_error(e)

def prompt_agent(
self,
agent_name: str,
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@

setup(
name="agixtsdk",
version="0.0.30",
version="0.0.31",
description="The AGiXT SDK for Python.",
long_description=long_description,
long_description_content_type="text/markdown",
Expand Down

0 comments on commit a20c034

Please sign in to comment.