I have the same problem and make the request from the server. Here is my \PayPalCheckoutSdk\Orders\OrdersCreateRequest Object: PayPalCheckoutSdk\Orders\OrdersCreateRequest::__set_state(array(
'path' => '/v2/checkout/orders?',
'body' =>
array (
'intent' => 'CAPTURE',
'application_context' =>
array (
'brand_name' => 'foo',
'locale' => 'de-DE',
'landing_page' => 'BILLING',
'shipping_preferences' => 'foo',
'user_action' => 'PAY_NOW',
'return_url' => 'http://foo.lan/paypalcheckout-requestreturn',
'cancel_url' => 'http://foo.lan/paypalcheckout-requestcancel',
),
'purchase_units' =>
array (
0 =>
array (
'reference_id' =[Removed. Phone #s not permitted]db83e9619fb',
'description' => 'foo',
'amount' =>
array (
'currency_code' => 'EUR',
'value' => 34.71740740740741,
'breakdown' =>
array (
'item_total' =>
array (
'currency_code' => 'EUR',
'value' => 23.55740740740741,
),
'shipping' =>
array (
'currency_code' => 'EUR',
'value' => 11.16,
),
'tax_total' =>
array (
'currency_code' => 'EUR',
'value' => 3,
),
),
),
'items' =>
array (
0 =>
array (
'name' => 'foo 1000 Ø18,0mm',
'sku' => 'CP00083',
'unit_amount' =>
array (
'currency_code' => 'EUR',
'value' => '20.466667',
),
'tax' =>
array (
'currency_code' => 'EUR',
'value' => '3',
),
'quantity' => 0.16666666666666666,
),
),
'shipping' =>
array (
'method' => 'UPS',
'address' =>
array (
'address_line_1' => 'Somestreet',
'address_line_2' => 'Thename',
'admin_area_2' => 'City',
'postal_code' => '12345',
'country_code' => 'DE',
),
),
),
),
),
'verb' => 'POST',
'headers' =>
array (
'Content-Type' => 'application/json',
'Prefer' => 'return=representation',
),
))
... View more