Skip to content

Commit

Permalink
Add list triggers
Browse files Browse the repository at this point in the history
  • Loading branch information
kaavee315 committed Mar 27, 2024
1 parent 923a479 commit 4efb487
Show file tree
Hide file tree
Showing 11 changed files with 26 additions and 9 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
try.ipynb
*pycache*
user_data.json
.venv
Expand Down
2 changes: 1 addition & 1 deletion autogen/pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[project]
dynamic = ["classifiers", "version", "readme", "authors", "requires-python", "description"]
dependencies = [
"composio_core===0.1.48",
"composio_core===0.1.49",
"pyautogen===0.2.19"
]
name = "composio_autogen"
Expand Down
2 changes: 1 addition & 1 deletion autogen/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ def resolve_paths(*paths):

setup(
name="composio_autogen",
version="0.1.48",
version="0.1.49",
author="Sawradip",
author_email="[email protected]",
description="Use Composio to get an array of tools with your Autogen agent.",
Expand Down
16 changes: 16 additions & 0 deletions core/composio/sdk/sdk.py
Original file line number Diff line number Diff line change
Expand Up @@ -211,6 +211,22 @@ def get_list_of_actions(
return actions_response["items"]

raise Exception("Failed to get actions")

def get_list_of_triggers(
self, apps: list[App] = None
) -> list:
if apps is None or len(apps) == 0:
resp = self.http_client.get(f"{self.base_url}/v1/triggers")
else:
app_unique_ids = [app.value for app in apps]
resp = self.http_client.get(
f"{self.base_url}/v1/triggers?appNames={','.join(app_unique_ids)}"
)
if resp.status_code == 200:
triggers_response = resp.json()
return triggers_response
print(resp.status_code)
raise Exception("Failed to get triggers")

def get_list_of_integrations(self) -> list[Integration]:
resp = self.http_client.get(f"{self.base_url}/v1/integrations")
Expand Down
2 changes: 1 addition & 1 deletion core/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ def run(self):

setup(
name="composio_core",
version="0.1.48",
version="0.1.49",
author="Utkarsh",
author_email="[email protected]",
description="Core package to act as a bridge between composio platform and other services.",
Expand Down
2 changes: 1 addition & 1 deletion crew_ai/pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[project]
dynamic = ["classifiers", "version", "readme", "authors", "requires-python", "description"]
dependencies = [
"composio_langchain===0.1.48",
"composio_langchain===0.1.49",
]
name = "composio_crewai"

Expand Down
2 changes: 1 addition & 1 deletion crew_ai/requirements.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
composio_langchain===0.1.48
composio_langchain===0.1.49
2 changes: 1 addition & 1 deletion crew_ai/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ def resolve_paths(*paths):

setup(
name="composio_crewai",
version="0.1.48",
version="0.1.49",
author="Himanshu",
author_email="[email protected]",
description="Use Composio to get an array of tools with your CrewAI agent.",
Expand Down
2 changes: 1 addition & 1 deletion langchain/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ dependencies = [
"langchain-openai===0.0.2.post1",
"langchainhub==0.1.15",
"pydantic===2.6.4",
"composio_core===0.1.48"
"composio_core===0.1.49"
]
name = "composio_langchain"

Expand Down
2 changes: 1 addition & 1 deletion langchain/requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@ langchain===0.1.0
langchain-openai===0.0.2.post1
pydantic===2.6.4
langchainhub==0.1.15
composio_core===0.1.48
composio_core===0.1.49
2 changes: 1 addition & 1 deletion langchain/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ def resolve_paths(*paths):

setup(
name="composio_langchain",
version="0.1.48",
version="0.1.49",
author="Karan",
author_email="[email protected]",
description="Use Composio to get an array of tools with your LangChain agent.",
Expand Down

0 comments on commit 4efb487

Please sign in to comment.