Update Hubspot toolkit to use Hubspot auth class (#375)
This commit is contained in:
parent
9346498edb
commit
3e35c70f85
3 changed files with 7 additions and 10 deletions
|
|
@ -1,15 +1,14 @@
|
|||
from typing import Annotated, Any, Optional
|
||||
|
||||
from arcade.sdk import ToolContext, tool
|
||||
from arcade.sdk.auth import OAuth2
|
||||
from arcade.sdk.auth import Hubspot
|
||||
|
||||
from arcade_hubspot.enums import HubspotObject
|
||||
from arcade_hubspot.models import HubspotCrmClient
|
||||
|
||||
|
||||
@tool(
|
||||
requires_auth=OAuth2(
|
||||
id="hubspot",
|
||||
requires_auth=Hubspot(
|
||||
scopes=[
|
||||
"oauth",
|
||||
"crm.objects.companies.read",
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
from typing import Annotated, Any, Optional
|
||||
|
||||
from arcade.sdk import ToolContext, tool
|
||||
from arcade.sdk.auth import OAuth2
|
||||
from arcade.sdk.auth import Hubspot
|
||||
|
||||
from arcade_hubspot.enums import HubspotObject
|
||||
from arcade_hubspot.models import HubspotCrmClient
|
||||
|
|
@ -9,8 +9,7 @@ from arcade_hubspot.utils import clean_data
|
|||
|
||||
|
||||
@tool(
|
||||
requires_auth=OAuth2(
|
||||
id="hubspot",
|
||||
requires_auth=Hubspot(
|
||||
scopes=[
|
||||
"oauth",
|
||||
"crm.objects.contacts.read",
|
||||
|
|
@ -61,8 +60,7 @@ async def get_contact_data_by_keywords(
|
|||
|
||||
|
||||
@tool(
|
||||
requires_auth=OAuth2(
|
||||
id="hubspot",
|
||||
requires_auth=Hubspot(
|
||||
scopes=["oauth", "crm.objects.contacts.write"],
|
||||
),
|
||||
)
|
||||
|
|
|
|||
|
|
@ -1,12 +1,12 @@
|
|||
[tool.poetry]
|
||||
name = "arcade_hubspot"
|
||||
version = "0.1.0"
|
||||
version = "0.2.0"
|
||||
description = "Arcade tools designed for LLMs to interact with Hubspot"
|
||||
authors = ["Arcade <dev@arcade.dev>"]
|
||||
|
||||
[tool.poetry.dependencies]
|
||||
python = "^3.10"
|
||||
arcade-ai = ">=1.0.5,<2.0"
|
||||
arcade-ai = ">=1.3.2,<2.0"
|
||||
httpx = "^0.27.2"
|
||||
|
||||
[tool.poetry.dev-dependencies]
|
||||
|
|
|
|||
Loading…
Reference in a new issue