'marketplace delivery by uber fleet

I would like to know if we can use uber api (postmates) in order to use their delivery fleet to pickup and delivery of orders for our marketplace

in other words, once the merchant marks the order “ready for delivery” thr marketplace communicates with uber/postmates api, get the nearest driver to pickup the order and deliver it to customer’s address

if that is possible, I wonder how we can calculate the delivery cost, and push it to the customers when paying for their shopping cart (before the driver is booked via uber/postmates api by the marketplace) in order to pass on the delivery charges to customers

very much appreciate all insights and helps

thanks



Sources

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

Source: Stack Overflow

Solution Source