this is a REST API example using Nodejs to process orders using Paypal REST API
these are some environment variables needed
CLIENT=AeWjuXIc8YDlv3nK9usTjDy6VAAXFL8gPE4GAgH-5teMty9oGvwdUHYaUCPFH0IMqPpB2RbbYuFP2fUG
SECRET=EN17orbJxGjpvQvb_iGwVjsF1oorFFWkCq3h5YSoaf4QYKdth0YvmNyWUCz3KinFRgn2H_j7xX709HCO
PAYPAL_API=https://api-m.sandbox.paypal.com