Credit Card CLI Tools

I just uploaded a set of tools for processing credit cards to GitHub. GitHub is pretty awesome BTW.

All you need is a PayPal Business or Premeir account.

Most will not want to do this kind of thing on the command line, and I understand. I wrote these scripts just to be able to interface with my legacy system that I wrote in 1999 for use with CyberCash (and later Verisign PayFlow Pro). But I figured maybe there’s a few others out there that might like this.

Here’s a couple neat things you can do:

1
2
3
4
5
6
7
8
9
10
Example $1.00 charge:

  $ ./charge.rb 1.00 4111111111111111 02/2012

Example $1.00 refund:

  $ ./refund.rb 1.00 2TL24251DY409204F

The second argument in the above example is the Auth ID of the original 
transaction.

You’ll get back a YAML formatted version of PayPal’s response to stdout.

I use ActiveMerchant to do all the heavy lifting. AM is wonderfully easy to use, those guys did a really good job.

For more info, see the repo and README here: http://github.com/up_the_irons/credit_card_tools/tree/master

Comments