Coder Social home page Coder Social logo

vikrant1717 / credit_card_tools Goto Github PK

View Code? Open in Web Editor NEW

This project forked from up_the_irons/credit_card_tools

0.0 1.0 0.0 92 KB

Tools for processing credit cards on the command line

Home Page: http://scie.nti.st

License: GNU General Public License v2.0

Ruby 100.00%

credit_card_tools's Introduction

Credit Card Tools
=================

These are a set of ruby scripts for processing credit cards on the command
line.

Supported processors:

  * PayPal (Business or Premier account required)

Requirements
------------

  * RubyGems
  * ActiveMerchant

Setup
-----

Copy gateway.yml.example to gateway.yml and fill in the fields in that file.

There is one block for the "live" environment, where real credit cards are
charged, and one block for the "test" environment, which mocks everything
through PayPal's Sandbox and no real money is exchanged.

Install ActiveMerchant::

  gem install activemerchant

If the following files are not set executable, you should do::

  chmod 755 charge.rb refund.rb

Usage
-----

Commands:

  * charge.rb
  * refund.rb

Run the commands without arguments to see the options.

Example $1.00 charge::

  ./charge.rb 1.00 4111111111111111 02/2012

Example $1.00 refund::

  ./refund.rb 1.00 2TL24258DY409104G

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

The output will be a nicely formatted response from PayPal.  The response is
in YAML format, so you could do further processing with your own scripts 
relatively easily.

Other Processors
----------------

ActiveMerchant supports a large list of credit card processors / gateways.
To use these tools with a gateway besides PayPal, modify gateway.rb to suit
your needs.  It should be relatively straight forward.

See: http://www.activemerchant.org

Author
------

Garry C. Dolley

gdolley [at] NOSPAM- ucla.edu

AIM: garry97531

IRC: I am up_the_irons in #ram, #git and #caboose on Freenode.

Copyright
---------

Copyright (c) 2008 Garry C. Dolley

This is free software; you can redistribute it and/or modify it under the
terms of the GNU General Public License as published by the Free Software
Foundation; either version 2 of the License, or (at your option) any later 
version.

This is distributed in the hope that it will be useful, but WITHOUT ANY
WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
FOR A PARTICULAR PURPOSE.  See the GNU General Public License for more
details.

You should have received a copy of the GNU General Public License along with
this software; if not, write to the Free Software Foundation, Inc., 51 Franklin
Street, Fifth Floor, Boston, MA  02110-1301, USA

credit_card_tools's People

Contributors

up_the_irons avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.