https://github.com/gmag11/painlessMesh
Then you configure one (or more) ESP units as the WiFi transmitter up to your end point, and the rest as mesh units. You would more than likely need to disconnect from the mesh to connect to a normal IP wireless AP so having more than one transmitter in your mesh would provide some fault tolerance.
You would also need to implement some sort of elementary PubSub mechanism - at least some sort of ack on your final end point that would tell the mesh that a message had been received so the mesh can remove any messages that have reached the end point.
You haven't really mentioned what latency requirements you have - can you store and forward your data as a chunk? What's the time between transmission?