title: Paymill subscription in PHP
body: <p>I am trying to create a subscription i Paymill. Ive read through their examples but i do not seem to get it.</p>
  
  <p>All i really want to do is to setup a subscription, here is my current code:</p>
  
  <pre><code>$token = $_POST['paymillToken'];
  
  if ($token) {
      require "Services/Paymill/Payments.php";
      require "Services/Paymill/Transactions.php";
      require "Services/Paymill/Subscriptions.php";
      require "Services/Paymill/Offers.php";
  
  
    $params = array(
      'amount'      =&gt; '49900',  // Cent!
      'currency'    =&gt; 'SEK',   // ISO 4217
      'token'       =&gt; $token,
      'description' =&gt; 'User ID# ' . $userIdMain . ' Email: ' . $userEmail
    );
  
  $transactionsObject = new Services_Paymill_Transactions(
      PAYMILL_API_KEY, PAYMILL_API_HOST
  );
  $transaction        = $transactionsObject-&gt;create($params);
  
  echo "&lt;br /&gt;&lt;br /&gt;";    
  print_r($transaction);
  
  echo $transaction['client']['id'];
  echo $transaction['payment']['id'];
  
  
  $params = array(
      'client'   =&gt; $transaction['client']['id'],
      'offer'    =&gt; 'offer_9cdffb501f565bf827a8',
      'payment'  =&gt; $transaction['payment']['id']
  );
  $subscriptionsObject = new Services_Paymill_Subscriptions(PAYMILL_API_KEY, PAYMILL_API_HOST);
  $subscription        = $subscriptionsObject-&gt;create($params);
  
  echo "&lt;br /&gt;&lt;br /&gt;";    
  print_r($subscription);
  
  } 
  </code></pre>
  
  <p>The problem is that the above create two payments at once. But it seems like the subscription object requires me to first have a payment_id (see $transaction['payment']['id'] above).</p>
  
  <p>What am i doing wrong here? </p>