title: Possible to run Python Script in terminal to process PayNow payment?
body: <p>PayNow is a service (available in Singapore) that allows you to send to and receive money using a mobile number or Singapore NRIC without having to know the recipient's account number.</p>
  
  <p>Some reference: </p>
  
  <ol>
  <li><a href="https://www.ocbc.com/personal-banking/help-and-support/paynow.html" rel="nofollow noreferrer">https://www.ocbc.com/personal-banking/help-and-support/paynow.html</a></li>
  <li><a href="https://www.dbs.com/developers/" rel="nofollow noreferrer">https://www.dbs.com/developers/</a></li>
  </ol>
  
  <p>Below is how I imagine PayNow payment (<strong>transfer using recipient's registered mobile number</strong>) could be process using a python script - i took reference from Paypal and modified inputs according to what I saw on DBS Developer's document.</p>
  
  <p><strong>What i am trying to achieve:</strong> With a list of mobile numbers, I am able to process PayNow payments to the recipients in batches/ bulk. But for now, I'm just wondering how to process a PayNow payment by running a python script.</p>
  
  <p><strong>My questions are:</strong></p>
  
  <ol>
  <li>is the below script right?</li>
  <li>is there a library i can import and documentations i can read?</li>
  <li>I understand that there's some API calling and redirect URI, how does it fit into this?</li>
  <li>I am hoping to just run a python script from the terminal to process the payment. It is not an app. So how do i get the ClientID, ClientSecret and token?</li>
  </ol>
  
  <p>Any help would be greatly appreciated :)</p>
  
  <hr>
  
  <pre><code>import paynow
  
  paynowrestsdk.configure({
    "mode": "sandbox", # sandbox or live
    "client_id": "EBWKjlELKMYqRNQ6sYvFo64FtaRLRR5BdHEESmha49TM",
    "client_secret": "EO422dn3gQLgDbuwqTjzrFgFtaRLRR5BdHEESmha49TM" })
  
  payment = paynowrestsdk.Payment({
              "fundTransferDetl”:{
              “partyId":"11845277752388953651",
              "debitAccountId":"21841900319944140151001",
              "payeeReference":{
                  "referenceType":"MSISDN",
                  "referenceDesc":"Mobile no.",
                  "reference":"65998899758"
              },
              "amount":5,
              "transferCurrency":"SGD",
              "comments":"Transfer",
              "purpose":"Transfer",
              "referenceId":"4P3EDAB1C853A004117A330"
              }
              })
  
  if payment.create():
    print(referenceId)
    print(status)
  else:
    print(payment.error)
  </code></pre>