@ -1,4 +1,6 @@
""" ## Zapier Natural Language Actions API
""" [DEPRECATED]
## Zapier Natural Language Actions API
\
Full docs here : https : / / nla . zapier . com / start /
@ -79,6 +81,7 @@ agent.run(("Summarize the last email I received regarding Silicon Valley Bank. "
"""
from typing import Any , Dict , Optional
from langchain . _api import warn_deprecated
from langchain . callbacks . manager import (
AsyncCallbackManagerForToolRun ,
CallbackManagerForToolRun ,
@ -137,6 +140,13 @@ class ZapierNLARunAction(BaseTool):
self , instructions : str , run_manager : Optional [ CallbackManagerForToolRun ] = None
) - > str :
""" Use the Zapier NLA tool to return a list of all exposed user actions. """
warn_deprecated (
since = " 0.0.319 " ,
message = (
" This tool will be deprecated on 2023-11-17. See "
" https://nla.zapier.com/sunset/ for details "
) ,
)
return self . api_wrapper . run_as_str ( self . action_id , instructions , self . params )
async def _arun (
@ -145,6 +155,13 @@ class ZapierNLARunAction(BaseTool):
run_manager : Optional [ AsyncCallbackManagerForToolRun ] = None ,
) - > str :
""" Use the Zapier NLA tool to return a list of all exposed user actions. """
warn_deprecated (
since = " 0.0.319 " ,
message = (
" This tool will be deprecated on 2023-11-17. See "
" https://nla.zapier.com/sunset/ for details "
) ,
)
return await self . api_wrapper . arun_as_str (
self . action_id ,
instructions ,
@ -179,6 +196,13 @@ class ZapierNLAListActions(BaseTool):
run_manager : Optional [ CallbackManagerForToolRun ] = None ,
) - > str :
""" Use the Zapier NLA tool to return a list of all exposed user actions. """
warn_deprecated (
since = " 0.0.319 " ,
message = (
" This tool will be deprecated on 2023-11-17. See "
" https://nla.zapier.com/sunset/ for details "
) ,
)
return self . api_wrapper . list_as_str ( )
async def _arun (
@ -187,6 +211,13 @@ class ZapierNLAListActions(BaseTool):
run_manager : Optional [ AsyncCallbackManagerForToolRun ] = None ,
) - > str :
""" Use the Zapier NLA tool to return a list of all exposed user actions. """
warn_deprecated (
since = " 0.0.319 " ,
message = (
" This tool will be deprecated on 2023-11-17. See "
" https://nla.zapier.com/sunset/ for details "
) ,
)
return await self . api_wrapper . alist_as_str ( )