We're excited to announce that we'll be partnering with Credly starting October 19th - see what this means and read the announcement blog here!

Dev Space

Customize & extend the power of Alteryx. SDKs, APIs, custom tools, and more!

Accessing React Front End Variables in Python Backend

paul_houghton
11 - Bolide

Im trying to use the platform SDK to create a python macro. I have initialised a new virtual environment to develop in but I don't know to access values entered in the react front end (eg a text box) in the python engine backend.

Any assistance in filling in the missing pebkac error would be fantastic.

1 REPLY 1
PetrT
Alteryx
Alteryx

Hey Paul,

you can simply use 

provider.tool_config.get("ValueName")

as you can see in AyxSdkInput tool example, or you could also refer the AyxSdkComplex example for more sophisticated solution. These sample tools are part of ayx_python_sdk package, so you can find them in your workspace's virtual environment eg.: ..\venv\Lib\site-packages\ayx_python_sdk\examples\