title: PHP Laravel moltin cart paypal issue
body: <p>I'm using laravel moltin shopping cart package. And I have been following this tutorial so far : <a href="http://jslim.net/blog/2014/09/19/integrate-paypal-sdk-into-laravel-4/" rel="nofollow">http://jslim.net/blog/2014/09/19/integrate-paypal-sdk-into-laravel-4/</a></p>
  
  <p>when I use the same code the code works perfectly but whenever I keep my own items on the cart, it shows an error : " Got Http response code 400 when accessing api.paypal.com/v1/payments/payment. "</p>
  
  <p>Here is my code, currently I have commented out the static items, instead I'm using moltin package. Link : <a href="https://github.com/moltin/laravel-cart" rel="nofollow">https://github.com/moltin/laravel-cart</a></p>
  
  <pre><code>public function postPayment()
      {
  
          $cart = new Cart(new Session, new Cookie);
  
          $payer = new Payer();
          $payer-&gt;setPaymentMethod('paypal');
  
  //        $item_1 = new Item();
  //        $item_1-&gt;setName('Item 1') // item name
  //        -&gt;setCurrency('USD')
  //            -&gt;setQuantity(2)
  //            -&gt;setPrice('15'); // unit price
  //
  //        $item_2 = new Item();
  //        $item_2-&gt;setName('Item 2')
  //            -&gt;setCurrency('USD')
  //            -&gt;setQuantity(4)
  //            -&gt;setPrice('7');
  //
  //        $item_3 = new Item();
  //        $item_3-&gt;setName('Item 3')
  //            -&gt;setCurrency('USD')
  //            -&gt;setQuantity(1)
  //            -&gt;setPrice('21');
  
          // add item to list
          $item_list = new ItemList();
          $item_list-&gt;setItems($cart-&gt;contents(true));
  
          $amount = new Amount();
          $amount-&gt;setCurrency('USD')
              -&gt;setTotal($cart-&gt;total(false));
  
          $transaction = new Transaction();
          $transaction-&gt;setAmount($amount)
              -&gt;setItemList($item_list)
              -&gt;setDescription('Your transaction description');
  
          $redirect_urls = new RedirectUrls();
          $redirect_urls-&gt;setReturnUrl(URL::route('payment.status'))
              -&gt;setCancelUrl(URL::route('payment.status'));
  
          $payment = new Payment();
          $payment-&gt;setIntent('Sale')
              -&gt;setPayer($payer)
              -&gt;setRedirectUrls($redirect_urls)
              -&gt;setTransactions(array($transaction));
  
          $payment-&gt;create($this-&gt;_api_context);
  
  
          foreach($payment-&gt;getLinks() as $link) {
              if($link-&gt;getRel() == 'approval_url') {
                  $redirect_url = $link-&gt;getHref();
                  break;
              }
          }
  
          // add payment ID to session
          Session::put('paypal_payment_id', $payment-&gt;getId());
  
          if(isset($redirect_url)) {
              // redirect to paypal
              return Redirect::away($redirect_url);
          }
  
          return Redirect::route('original.route')
              -&gt;with('error', 'Unknown error occurred');
      }
  </code></pre>
  
  <p>I'm getting this error :</p>
  
  <pre><code>stdClass Object
  (
      [name] =&gt; MALFORMED_REQUEST
      [message] =&gt; Incoming JSON request does not map to API request
      [information_link] =&gt; https://developer.paypal.com/webapps/developer/docs/api/#MALFORMED_REQUEST
      [debug_id] =&gt; 8df76ef7377bc
  )
  </code></pre>
  
  <p>While using static items it works but for this it doesn't work. Any help ?</p>
  
  <p>Thanks in advance!! :-)</p>