Got settlements working by adding an order_number method for submitting the transacti...
authorthalakan <thalakan>
Sat, 16 Feb 2002 06:54:36 +0000 (06:54 +0000)
committerthalakan <thalakan>
Sat, 16 Feb 2002 06:54:36 +0000 (06:54 +0000)
AuthorizeNet.pm

index 2c2c85c..43fc382 100644 (file)
@@ -1,6 +1,6 @@
 package Business::OnlinePayment::AuthorizeNet;
 
-# $Id: AuthorizeNet.pm,v 1.4 2002-02-12 23:29:43 ivan Exp $
+# $Id: AuthorizeNet.pm,v 1.5 2002-02-16 06:54:36 thalakan Exp $
 
 use strict;
 use Business::OnlinePayment;
@@ -98,6 +98,7 @@ sub submit {
         fax            => 'x_Fax',
         email          => 'x_Email',
         company        => 'x_Company',
+       order_number   => 'x_Trans_ID',
     );
 
     if($self->transaction_type() eq "ECHECK") {
@@ -120,7 +121,7 @@ sub submit {
                                          x_Last_Name x_First_Name x_Address
                                          x_City x_State x_Zip x_Country x_Phone
                                          x_Fax x_Email x_Email_Customer
-                                         x_Company x_Country/); 
+                                         x_Company x_Country x_Trans_ID/); 
     $post_data{'x_Test_Request'} = $self->test_transaction()?"TRUE":"FALSE";
     $post_data{'x_ADC_Delim_Data'} = 'TRUE';
     $post_data{'x_ADC_URL'} = 'FALSE';
@@ -141,6 +142,7 @@ sub submit {
         $self->is_success(1);
         $self->result_code($col[0]);
         $self->authorization($col[4]);
+       $self->order_number($col[6]);
     } else {
         $self->is_success(0);
         $self->result_code($col[2]);
@@ -176,7 +178,7 @@ Business::OnlinePayment::AuthorizeNet - AuthorizeNet backend for Business::Onlin
       state          => 'UT',
       zip            => '84058',
       card_number    => '4007000000027',
-      expiration     => '09/99',
+      expiration     => '09/02',
   );
   $tx->submit();
 
@@ -206,9 +208,26 @@ Unlike Business::OnlinePayment or previous verisons of
 Business::OnlinePayment::AuthorizeNet, 3.0 requires separate first_name and
 last_name fields.
 
+To settle an authorization-only transaction (where you set action to
+'Authorization Only'), submit the nine-digit transaction id code in
+the field "order_number" with the action set to "Post Authorization".
+You can get the transaction id from the authorization by calling the
+order_number method on the object returned from the authorization.
+You must also submit the amount field with a value less than or equal
+to the amount specified in the original authorization.
+
+Recently (February 2002), Authorize.Net has turned address
+verification on by default for all merchants.  If you do not have
+valid address information for your customer (such as in an IVR
+application), you must disable address verification in the Merchant
+Menu page at https://secure.authorize.net/ so that the transactions
+aren't denied due to a lack of addres information.
+
 =head1 COMPATIBILITY
 
-This module implements Authorize.Net's API verison 3.0.
+This module implements Authorize.Net's API verison 3.0 using the ADC
+Direct Response method.  See
+https://secure.authorize.net/docs/developersguide.pml for details.
 
 =head1 AUTHOR
 
@@ -217,6 +236,9 @@ Jason Kohles, jason@mediabang.com
 Ivan Kohler <ivan-authorizenet@420.am> updated it for Authorize.Net protocol
 3.0 and is the current maintainer.
 
+Jason Spence <jspence@lightconsulting.com> got settlements working and
+wrote some docs.  OST <services@ostel.com> paid for it.
+
 =head1 SEE ALSO
 
 perl(1). L<Business::OnlinePayment>.