Help with exporting maps to shapefiles

Good afternoon, I’m from Brazil and I need some help.
My problem is the following,
I have on my site map and get the OSM data trackers ranging scratching route on the map, just that I need to export this route and the map piece in which she is to a shape file and do not know how to do this, it will be is possible, could someone help?

So if yI understand right:

You have a website,

with OSM based tile graphics als Map background,

and you have something like a track on that map in an extra layer,

and you want to export that track to a shapefile.

Tell us first what frame work you are using to display the OSM based map together with your track or what you mean.

Or give us the link to your website unless it is not private.

There are some webservices where you can draw tracks by hand and then export them to GPX or similar. Maybe there is a way to convert GPX to Shapefile then.

So we need more information to help you.

I am a newbie on Open Street Maps, do not know if some are one or two layers, but it works as follows:
I’ve got a DIV on my website that shows then a part of the map, this map OSM via a JSON file is scratched according to data submitted by vehicle trackers. This map should be exported to. SHP with all the lines that were made with data from the tracker.

First of all, it seems that your map display is done via the framework OpenLayers … see for documentation and EXAMPLES!

And the data from vehicle tracker is delivered and displayed via a JSON file? … Then your question should be:

How can I convert JSON to shapefile … or am I still wrong in my assumptions?

The data are received and registered in the db and has a JS file. Has the API Open Layers and Open Street Maps to display maps and these APIs have functions to assemble the track formed by the GPS data in a given time period and what I have to do is to export this trail for SHAPEFILE.