I had the same problem, it can only take one object but you can configure it to purchase multiple items. I found this https://stackoverflow.com/questions/56414640/paypal-checkout-javascript-with-smart-payment-buttons-create-order-problem. Should help clear things up
... View more