'Connection of Vue and Python script - creation of interactive map

I have a frontend based on Vue.js, where users input the coordinates (lat and lang). This Vue js front end is connected with Django with REST API. Now, I know how to add or remove these lat and lang data sets from DB.

Separately I have a Python script, which is generating the route (using HereAPI). How can I pass the data from Vue js exactly to the Python variable,

coord = [[..., ...],[..., ...]]

launch the Python script and then show the output of the script, the map itself back to the frontend?

I expect, it could be done with a kind of POST/GET env. variables.

Any advice is appreciated.



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source