title: Node Quickpay authentication
body: <p>I am attempting to use <a href="https://www.npmjs.com/package/quick-pay" rel="nofollow noreferrer">Node quickpay</a></p>
  
  <p>However their documentation is not that "easy" to understand and i am kind of stuck with autentication.</p>
  
  <p>I have my <code>API token</code> and i have followed the following SO question: </p>
  
  <p><a href="https://stackoverflow.com/questions/37428834/quickpay-node-js-rest-api">QuickPay node.js REST api</a></p>
  
  <p>To make the following:</p>
  
  <pre><code>    var quickPay = require("quick-pay");
  module.exports = function (router, mongoose) {
      var token = "myToken";
      var version = {
          "Accept-Version": "v10",
          "Authorization": "your basic authentication"};
  
      var transaction_id = {};
  
      router.route('/api/payment')
          .put(function (req, res) {
              processCreatePayment(req, res);
          });
  
      function processCreatePayment(req, res) {
          var random_order_id = Math.floor((Math.random() * 1000) + 1);
  
          var parameters = {
              "currency": "INR",
              "order_id": random_order_id
          };
          quickPay.post("payments/", version, parameters)
              .then(function (result) {
                  console.log(result);
                  res.send(result);
                  transaction_id = result.id;
                  console.log(transaction_id);
              })
              .catch(function (err) {
  
                  console.log(err.response);
                  res.send(err.response);
  
              });
      }
  
  
      return router;
  };
  </code></pre>
  
  <p>However im not quite sure what the: <code>"Authorization": "your basic authentication"</code> should be.</p>
  
  <p>i hope someone can help me out.</p>
  
  <p>Please note i have already attempted:</p>
  
  <pre><code>    var version = {
      "Accept-Version": "v10",
      "Authorization": "Basic "+token
  };
  </code></pre>
  
  <p>But with out luck</p>
  
  <p>All i get is <code>invalid Basic Auth</code></p>