connect Python API