NEW Authorize.net Customer Information Manager

Posts: 60
Joined: 09/07/2007
Bug Finder

Hello All,

I just heard about a new service from Authorize.net that sounds very interesting, particularly for those of us working with recurring payments. In summary, this new service allow you to store all customer credit card info with Authorize.net, and then process a new transaction for that customer just by referencing an ID # - there's no need for the customer to re-enter their credit card.

This would provide great flexibility for recurring payments (i.e., the ability to charge a different amount each month, while still not storing any sensitive info in the database). It also would enable customers to make repeat purchases without having to reenter their CC info.

In Authorize.net's words...


The Customer Information Manager (CIM) service allows you to store your customers’ sensitive payment information on our secure servers for use in future transactions. Your Web site integrates to CIM via an Application Programming Interface (API). Through the API, you can create, view, update and delete customer profiles that include billing, payment and shipping information. When a transaction is processed using the API, a customer profile is created and stored on our secure servers. You receive a Customer Reference ID for that particular customer profile. From then on, you need only submit the Customer Reference ID in place of all customer information, including billing, payment and shipping information.

Posts: 1013
Joined: 08/14/2007
Bug FinderEarly adopter... addicted to alphas.Getting busy with the Ubercode.

This is awesome news. I would gladly be among the first to test this new functionality out. Is there any word on when it's going to be made available publicly, or is it already? (I'm a bit out of the loop).

Would be interesting to see how to get started with it, especially with our existing customer base.

--

"Pain don't hurt." - Dalton

Mike Nelson's RiffTrax! www.rifftrax.com

Posts: 60
Joined: 09/07/2007
Bug Finder

It's been in Beta since the summer. I think they just made it publicly available yesterday.

There is an implementation guide available here:

http://developer.authorize.net/guides/

(towards the bottom..."Customer Information Manager (CIM) – API Guide")

It looks like it requires a couple XML calls to setup a customer profile, then a very simple XML call whenever you want to charge them. Looks great to me.

Unfortunately no PHP source code examples yet, as far as I can tell...

Posts: 68
Joined: 12/28/2007
Bug FinderGetting busy with the Ubercode.

Hi Uberfolks,

I just wanted to let anyone interested in this know that I'm currently working on a new Authorize.net payment gateway module to integrate this CIM functionality. I will post more details when the module is ready for testing (early January) but here's the basic idea:

  • Provides normal payment gateway functionality
  • Automatically saves user credit card information to Authorize.net's servers for future use
  • Provides a new payment pane so that users can select previously entered credit card info rather than re-entering it on subsequent purchases
  • Allows admins to charge previously entered credit cards from the view order screen (could be useful if you want to charge customers when the product ships but not store their CC info in your database at all)
  • Provides an API for charging a customer using their previously entered CC info. This could be used for recurring payments, pre-orders, or follow-up sales.
  • May include other advanced features such as processing refunds / voids directly from Ubercart

I also wanted to thank everyone here for creating a great shopping cart. I've been working on developing my first drupal ecommerce site for the past couple of weeks and have found it to be a great combination. Every time I've had a question, it seems to already be answered somewhere, so I haven't had a chance to introduce myself and say thanks...so, thanks!

Hope everyone has a great New Year. See you in 2008....

Chad

Posts: 3959
Joined: 08/07/2007
AdministratorHead Code Monkey - I eat bugs.

Chad, welcome aboard. Glad things are working out for you, and I'll be excited to see what you come up with in the module. Smiling

Posts: 1
Joined: 12/31/2007
Posts: 68
Joined: 12/28/2007
Bug FinderGetting busy with the Ubercode.

Ray - thanks for posting the class. It looks like a very complete implementation of the CIM API. I had already implemented my own version, which is less complete, but perhaps a bit lighter weight. I think it gets the job done for the purpose of integrating CIM with Ubercart, but I welcome any suggestions for improvement.

All - the first version of the Authorize.net CIM is now available in contributions:

http://www.ubercart.org/contrib/2537

Thanks in advance for helping to test and providing feedback. Ubercart rocks. Smiling

Best,
Chad

Posts: 1013
Joined: 08/14/2007
Bug FinderEarly adopter... addicted to alphas.Getting busy with the Ubercode.

Excellent news! Looking forward to testing. Kudos!

--

"Pain don't hurt." - Dalton

Mike Nelson's RiffTrax! www.rifftrax.com

Posts: 13
Joined: 02/10/2008

Hey--
Great module, thanks for making it. I just installed it in our server, but whenever I go to process payments-- after the "virtual terminal" screen -- all I get is a blank page. This error message is logged in the Apache logs:

[Mon Feb 11 15:21:18 2008] [error] [client 68.184.42.198] PHP Fatal error:  Uncaught exception 'Exception' with message 'String could not be parsed as XML' in /home/webadmin/cart.hungarianstamps.com/html/sites/all/
modules/uc_cim.module:1422\nStack trace:\n#0 /home/webadmin/cart.hungarianstamps.com/html/sites/all/modules/uc_cim.module(1422): SimpleXMLElement->__construct('')\n#1 /home/webadmin/cart.hungarianstamps.com/html/si
tes/all/modules/uc_cim.module(1416): uc_cim_parse_return(false)\n#2 /home/webadmin/cart.hungarianstamps.com/html/sites/all/modules/uc_cim.module(1037): uc_cim_curl_send('<?xml version="...')\n#3 /home/webadmin/cart
.hungarianstamps.com/html/sites/all/modules/uc_cim.module(273): create_customer_profile_request('3')\n#4 /home/webadmin/cart.hungarianstamps.com/html/sites/all/modules/ubercart/payment/uc_payment/uc_payment.module(
859): uc_cim_charge('10', '23.00', NULL)\n#5 /home/webadmin/cart.hungarianstamps.com/html/sites/all/modules/ubercart/payment/uc_credit/uc_credit.module(911): uc_payment_process('credit', '10', '23.00')\n#6 /home/we
badmin/cart.hungarianstamps.com/html/i in /home/webadmin/cart.hungarianstamps.com/html/sites/all/modules/uc_cim.module on line 1422, referer: http://cart.hungarianstamps.com/admin/store/orders/10/credit

Posts: 68
Joined: 12/28/2007
Bug FinderGetting busy with the Ubercode.

Thanks, glad you like it.

Let's see, it looks like curl_exec is returning FALSE here, which means it failed. Otherwise it would return XML data to parse. We should implement some error handling to support that, so you don't get the blank screen, but that doesn't solve why your curl_exec is failing. I've never had it return false on me...

Does it happen every time? Does the rest of the module work (checkout, editing cards, etc)?

To debug this further, I think we'd have to see more of what curl is doing. In function uc_cim_curl_send($content), if you change curl_setopt($ch, CURLOPT_HEADER, 0) to curl_setopt($ch, CURLOPT_HEADER, 1) and tell me what the raw output of curl_exec($ch) is, we should be able to see why it's failing. Let me know if you need help with this.

Best
Chad

Posts: 13
Joined: 02/10/2008

Thanks for the quick response. Yeah, happens on all of the modules pages-- all the ones that send XML requests, at least. I changed what you said, but how do I get you the raw output?

Posts: 68
Joined: 12/28/2007
Bug FinderGetting busy with the Ubercode.

Try temporarily replacing the whole function with this one. It will just print the raw output to your screen whenever this function is called.

function uc_cim_curl_send($content) {
  //Build the path to post to, depending on whether we're in test mode or not
  if (variable_get('cim_transaction_mode', 'test') == 'test') {
    $posturl = 'https://apitest.authorize.net/xml/v1/request.api';
  }
  else {
    $posturl = 'https://api.authorize.net/xml/v1/request.api';
  }

  $ch = curl_init();
  curl_setopt($ch, CURLOPT_URL, $posturl);
  curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
  curl_setopt($ch, CURLOPT_HTTPHEADER, Array("Content-Type: text/xml"));
  curl_setopt($ch, CURLOPT_HEADER, 1);  //Set to true to return the header in the output - good for debugging, but messes with xml parsing
  curl_setopt($ch, CURLOPT_POSTFIELDS, $content);
  curl_setopt($ch, CURLOPT_POST, 1);
  curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, 0);
  $curl_output = curl_exec($ch);
  print_r('<pre>'. $curl_output. '</pre>');
  exit;
  //$response = uc_cim_parse_return(curl_exec($ch));
  //return $response;
}

Posts: 68
Joined: 12/28/2007
Bug FinderGetting busy with the Ubercode.

Better yet, here is a function with better error handling. This one should write any curl errors to your Drupal "recent log entries" watchdog.

function uc_cim_curl_send($content) {
  //Build the path to post to, depending on whether we're in test mode or not
  if (variable_get('cim_transaction_mode', 'test') == 'test') {
    $posturl = 'https://apitest.authorize.net/xml/v1/request.api';
  }
  else {
    $posturl = 'https://api.authorize.net/xml/v1/request.api';
  }

  $ch = curl_init();
  curl_setopt($ch, CURLOPT_URL, $posturl);
  curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
  curl_setopt($ch, CURLOPT_HTTPHEADER, Array("Content-Type: text/xml"));
  curl_setopt($ch, CURLOPT_HEADER, 0);  //Set to true to return the header in the output - good for debugging, but messes with xml parsing
  curl_setopt($ch, CURLOPT_POSTFIELDS, $content);
  curl_setopt($ch, CURLOPT_POST, 1);
  curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, 0);
 
  $authorize = curl_exec($ch);
  if ($error = curl_error($ch)) {
    watchdog('uc_cim', $error, WATCHDOG_ERROR);
  }
  else {
    $response = uc_cim_parse_return($authorize);
  }
 
  curl_close($ch); 
  return $response;
}

Posts: 13
Joined: 02/10/2008

Huh, interesting.... This is the error it was giving:

SSL: certificate subject name '*.authorize.net' does not match target host name 'apitest.authorize.net'

Looks like its a problem with the wildcard certificate... (?)

Posts: 68
Joined: 12/28/2007
Bug FinderGetting busy with the Ubercode.

Try adding:

curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, 0);

to the list of options. (anywhere in that list should be fine).

Posts: 13
Joined: 02/10/2008

Yup, worked great. Thanks!

Posts: 13
Joined: 02/10/2008

Ahhh.... It was working earlier today, but now I'm getting this:

Credit card payment failed: The 'AnetApi/xml/v1/schema/AnetApiSchema.xsd:customerProfileId' element is invalid - The value '' is invalid according to its datatype 'AnetApi/xml/v1/schema/AnetApiSchema.xsd:numericString' - The Pattern constraint failed.

Posts: 68
Joined: 12/28/2007
Bug FinderGetting busy with the Ubercode.

It's possible that your previous trouble with curl caused some data to be missing from the database. Can you try checking out with a new user (who hasn't checked out before). Do you see this error message during checkout? If you then go to process this new user's credit card from the admin screen, do you see this error?

Posts: 13
Joined: 02/10/2008

It gave the same error for a new customer. I added the CVV though, and it worked fine. Do you have the CVV set as a required field?

[EDIT:] It was

The 'AnetApi/xml/v1/schema/AnetApiSchema.xsd:cardCode' element is invalid - The value '' is invalid according to its datatype 'String' - The Pattern constraint failed.

for the new customer. Makes sense.

Along the lines of the CVV handling in the module code (specifically, in the merchant "create order" feature in the backend -- a fantastic feature, might I add)... The reason Authorize.net won't store the CVV number is because it's illegal to keep the CVV.(1) It's supposed to be passed on to the payment gateway on the submission of the transaction, then discarded. Keeping going with this idea that the CVV numbers cant be stored anywhere, and the module having CVV field set as required, merchants processing orders thru the back-end would need to contact their customers for the CVV number every time they created an invoice for the customer. It'd be a better, more practical idea to have the the CVV field defaulted as an optional field, and have the merchant be able to make it a required field, if they desire.

(1) https://www.pcisecuritystandards.org/pdfs/pci_dss_v1-1.pdf (page 2)

Smiling

Posts: 68
Joined: 12/28/2007
Bug FinderGetting busy with the Ubercode.

Ahh, good point. Okay, here's how I think it should work:

If you have the CVV field enabled, it will be sent during the initial payment, but it won't be saved and it won't be sent on any subsequent charges using that same credit card. You can set up the gateway to reject the transaction if the CVV does not match the correct value, but not to require the CVV. That way it will be verified on the first transaction, but not required later.

If you don't have the CVV field enabled, it's obviously never sent and never stored. You just have to make sure to set up the gateway to not require it.

What do you think?

Posts: 3959
Joined: 08/07/2007
AdministratorHead Code Monkey - I eat bugs.

djandrew wrote:
The reason Authorize.net won't store the CVV number is because it's illegal to keep the CVV.(1)

Out of curiosity, do you say this is illegal b/c of some contract or b/c of the PCI security standards? It's my understanding you may be penalized if you say you're PCI compliant but not, but I'm not sure you can be prosecuted for this unless you have a link to a clearer explanation of how the rules apply. Puzzled

Posts: 13
Joined: 02/10/2008

Yeah, chad-- sounds good. Ryan, I'm pretty sure Visa/MC now requires that all merchants be PCI compliant, and pass a quarterly PCI compliance test. I'll double-check that though.

Posts: 13
Joined: 02/10/2008

Yup.

"CISP compliance is required of all merchants and service providers that store, process, or transmit Visa cardholder data and applies to all payment channels, including retail (brick-and-mortar), mail/telephone order, and e-commerce. Compliance with CISP means compliance with the PCI Data Security Standard with the required program validation."

http://usa.visa.com/merchants/risk_management/cisp_overview.html
http://usa.visa.com/merchants/risk_management/cisp_merchants.html

[EDIT:] Ah, just looks like breaking CISP will just get you fines. No jail. But still not a great idea. Smiling

Posts: 3959
Joined: 08/07/2007
AdministratorHead Code Monkey - I eat bugs.

djandrew wrote:
[EDIT:] No jail. But still not a great idea. Smiling

Agreed. Just wanted to make sure we don't get pegged for aiding and abetting. Eye-wink

Posts: 13
Joined: 02/10/2008

chad,
I was looking around at the back-end order create tool in Ubercard, and it'd be great if we could get CIM better integrated on the Create Order page. Something like the Payment Information pane that's available in the front-end checkout.

Posts: 68
Joined: 12/28/2007
Bug FinderGetting busy with the Ubercode.

Hey, sorry for the slow response, i've been out of town. In any case, yes, you're right, the order tool could use some love. I guess we should follow the same workflow as the normal Ubercart payment pane follows - enter credit card info in the "Edit" tab and then charge the credit card in the "View" tab. This may take me a couple days to get to, but i'm hoping to roll out a new release next week and will try to integrate this into it. If you have any more thoughts about how the user interface should work, feel free to post them here and i'll take a look.

Chad

Posts: 13
Joined: 02/10/2008

Sweet, can't wait!

Posts: 68
Joined: 12/28/2007
Bug FinderGetting busy with the Ubercode.

Hi djandrew,

I just sent you a PM, but since I know you might not get notified about it automatically, I thought I'd let you know here. When you have a chance, check your Ubercart inbox.

Best,
Chad

Posts: 68
Joined: 12/28/2007
Bug FinderGetting busy with the Ubercode.

I just posted an update to the uc_cim module. Check it out... i think it's getting fairly feature complete at this point and is ready for some serious bug testing. Let me know if you find anything.

Thanks
Chad

Posts: 1013
Joined: 08/14/2007
Bug FinderEarly adopter... addicted to alphas.Getting busy with the Ubercode.

Chad,

I'd like to start testing this on our production server. Do you think it's production ready? Also what kind of overlap are we talking about, going from using authorize.net (and uc_credit)? (Along with PayPal). I haven't installed your module yet on the dev box but I just wanted to get some idea before I dove into it. Thanks! Really looking forward to giving it a go.

--

"Pain don't hurt." - Dalton

Mike Nelson's RiffTrax! www.rifftrax.com

Posts: 13
Joined: 02/10/2008

Great work! Some conflicts, though.... We're working mostly with the admin order entry system, so all my comments are on that:

1) Not sure how you have the "Billing address for new credit card" section setup, but if I leave it blank (even without selecting the "enter a new credit card" radio button), the "Bill to:" section clears. Now, at first, I thought this was an ubercart bug, but I continued testing the CIM mod.... I entered a new customer/new order in, with an address in the "ship to" box. I left the "bill to" boxes blank. I selected the "enter a new credit card" radio button in the CIM module panel, and entered a different address in the "Billing address for new credit card" fields than I did in the shipping address panel. after I submitted the form, the address from the "Billing address for new credit card" fields moved to the standard "bill to" fields. the "Billing address for new credit card" fields were blank.

2) The "Payment" panel is throwing me off a little. Is there any way to hide/remove it from the admin order entry screen? Changing settings on the /admin/store/settings/checkout/edit/panes page didn't do anything. Also, the information from the "New credit card" fields in the CIM module panel seems to jump to the "payment" panel fields (the last 4 digits of the card number, exp date & card type). Wouldn't it make more sense to have these setup as unique fields (separate from the regular fields)?

Thanks for all the work you've done!

Posts: 68
Joined: 12/28/2007
Bug FinderGetting busy with the Ubercode.

Andrew,

I think all the problems your having are because of your order pane setup. I'm going to try improving documentation on this. You definitely need to remove the Payment panel and the Bill to panel for your order entry screen. Try double-checking this (from the updated documentation):

5) Order panes (admin/store/settings/order/edit/panes):
-Disable the Payment pane and enable the Credit Card Payment pane for all screens.
-Disable the Bill To pane for the Edit Screen. (You may leave it enabled for
view, invoice, and customer, but it will only contain address data when a
new credit card has been entered)

I'm going to update v0.4 with the doc change and a small improvement to new credit card validation on the order screen, so you also might want to grab that.

Posts: 68
Joined: 12/28/2007
Bug FinderGetting busy with the Ubercode.

torgosPizza -

Sounds good, I'm looking forward to getting your input.

The module is working well for me, but you should definitely plan on testing this on your dev box first. There's a decent number of Ubercart settings this module interacts with and I certainly haven't tested all combinations. I tried to document as much as I could in the README, but I'm sure I missed something (as Andrew just found out for the order screen).

If you're going to keep Paypal working, you're also going to need to choose "option B" (from the README) for your checkout process. This means you'll use the standard Payment pane, letting you keep your Paypal option but lose the ability for customers to easily choose credit cards they've already used in the past, which is of course one of the biggest advantages of CIM. Also, I haven't tested this option nearly as much, so it could be more buggy.

Let me know how it goes...

Chad

Posts: 13
Joined: 02/10/2008

Ah, yes! THAT's the screen I've been looking for. Smiling

Small typo, though.. It's not
admin/store/settings/order/edit/panes
it's
admin/store/settings/orders/edit/panes

Posts: 1013
Joined: 08/14/2007
Bug FinderEarly adopter... addicted to alphas.Getting busy with the Ubercode.

Small issue. In the .install file there is a comma between uc_payment and uc_credit. It needs to be removed before the module can be enabled.

--

"Pain don't hurt." - Dalton

Mike Nelson's RiffTrax! www.rifftrax.com

Posts: 68
Joined: 12/28/2007
Bug FinderGetting busy with the Ubercode.

Yep...thanks for catching that...I just posted a small bug fix update including that .info file bug and a couple of others.

Posts: 1013
Joined: 08/14/2007
Bug FinderEarly adopter... addicted to alphas.Getting busy with the Ubercode.

Chad,

I don't have a README file in my archive. I looked at the first release and the last release, and neither had them. Any luck in posting it? Smiling (Right now I need to figure out how to get the panes to play nice, since I want to checkout using Gift Certificates but it won't let me Review the order since the CIM pane is always visible..)

Thanks!

--

"Pain don't hurt." - Dalton

Mike Nelson's RiffTrax! www.rifftrax.com

Posts: 68
Joined: 12/28/2007
Bug FinderGetting busy with the Ubercode.

Hmm, that's strange. I just downloaded the latest release I posted in contribs and there's a README.txt in there...

Anyway, I've attached it again here.

Regarding gift certificates, I'm using a custom module for that right now and it works okay. You still have to always enter your credit card, even if the order total will be 0 and you won't be charged. That's certainly not the most friendly solution, but I wasn't sure how to handle the fact that taxes aren't calculated until the review screen so you don't actually know the total until then. Any ideas, let me know...

Chad

AttachmentSize
README.txt6.08 KB
Posts: 23
Joined: 04/04/2008

I'm trying out this module and it worked (meaning it does create the profile and process the payment at Authorize) but back at ubercart I keep getting this error...
"Your order cannot be completed, because we could not process your recurring payment. Please review your payment details and contact us to complete your order if the problem persists."
Any ideas?

A couple of other things to report...

This is pretty minor but there is no directory in the tar/gz file so when I unzipped it, all the files were placed directly in my modules folder. Was this meant to be unzipped in a folder other than modules?

Also, I have a multi-site setup where my database has prefixed tables. I received an error that a uc_cim table could not be found. It's because you're using "{$table}" in some of your database calls. PHP interprets the braces when you put them around variables in a double-quoted string. I fixed it by pulling the variable out of the quoted string like this...
" beginning-of-string {" . $table . "} end-of-string "

This may be just how ubercart works but when I disabled the Payment Information checkout pane, it didn't actually do it until I set it's displayed weight to 0. Very odd to me.

Thanks for the module!

--

Chisholm Technologies, Inc.
Custom software development since 1999!
www.chisholmtech.com

Posts: 68
Joined: 12/28/2007
Bug FinderGetting busy with the Ubercode.

The error message you're getting actually comes from the uc_recurring module. It's not saving your recurring fee - I think the only reason this will happen is because it's using the wrong recurring fee handler for your payment method. Have you selected uc_cim as your recurring fee handler (admin/store/settings/products/edit/features). Are there any watchdog errors? This should give us a clue...

Sorry about the tar file...the files are meant to unzip into a folder called uc_cim. You can put that wherever you like...I think most people put it in the ubercart/contribs folder.

Thanks for the multi-site feedback - I hadn't tested that yet.

Not sure what's going on with your Payment Information checkout pan - that doesn't happen to me I don't think...

Best,
Chad

Posts: 23
Joined: 04/04/2008

chadcrew wrote:
The error message you're getting actually comes from the uc_recurring module. It's not saving your recurring fee - I think the only reason this will happen is because it's using the wrong recurring fee handler for your payment method. Have you selected uc_cim as your recurring fee handler (admin/store/settings/products/edit/features)...

That did it. Thanks!

If I leave the Number of billing periods blank do you know if it keep taking the payment indefinitely.

--

Chisholm Technologies, Inc.
Custom software development since 1999!
www.chisholmtech.com

Posts: 68
Joined: 12/28/2007
Bug FinderGetting busy with the Ubercode.

I don't think so, but you'd have to try it or ask Ryan, who wrote the uc_recurring module to be sure...

Posts: 10
Joined: 03/04/2008

That has worked for me so far. If the number of billing periods is blank it goes indefinitely.

Posts: 23
Joined: 04/04/2008

I have a problem that I'm having a hard time resolving here. I'm getting the message...
"We were unable to process your credit card payment. Please verify your card details and try again. If the problem persists, contact us to complete your order."

If I look at the order in ubercart the transaction message is "Credit Card Declined: $0.00".

Yet I get a confirmation/receipt email from Authorize.net saying the transaction was successful. And if I login to Authorize I can see the transaction.

I am in Developer Test mode.

Does anyone know why this would be happening?

--

Chisholm Technologies, Inc.
Custom software development since 1999!
www.chisholmtech.com

Posts: 3959
Joined: 08/07/2007
AdministratorHead Code Monkey - I eat bugs.

Are you trying to run the card for $0.00? If so, that could be the cause of the problem... Puzzled

Posts: 23
Joined: 04/04/2008

No. Actually, I don't understand why the amount is 0$ on that message when everyplace else (in the cart, review screen, emails from ubercart and Authorize.net) has the amount at $15.98

--

Chisholm Technologies, Inc.
Custom software development since 1999!
www.chisholmtech.com

Posts: 23
Joined: 04/04/2008

Ok, I had to debug uc_cim to find out what was happening...

1. In the uc_cim_charge function, in the response processing, it's checking for $response->messages->code as opposed to $response->messages->message->code which is what's returned from Authorize.net

2. Also in the same section of code, this statement...
$directResponse = split('\,', $response->directResponse);
Does not work for me. I had to change it to...
$directResponse = explode('|', $response->directResponse);
Which correctly parses the return from Authorize.net

This is version v0.6

Not sure why things are different now. Perhaps a change in the results from Authorize?

--

Chisholm Technologies, Inc.
Custom software development since 1999!
www.chisholmtech.com

Posts: 68
Joined: 12/28/2007
Bug FinderGetting busy with the Ubercode.

I'll have to look into 1. That seems odd to me...

As for 2, the default delimiter for Authorize.net accounts used to be comma, Maybe they've changed that to | now. I'll make that an option in the next release of uc_cim so you can adjust this as necessary, without hacking the module.

Posts: 68
Joined: 12/28/2007
Bug FinderGetting busy with the Ubercode.

You're right about issue 1 - I missed one "message" when looking for a specific error response. Thanks for catching that.

I'm working on making uc_cim compatible with RC5 now, and I'll include these bug fixes when I release that.

Best,
Chad

Posts: 68
Joined: 12/28/2007
Bug FinderGetting busy with the Ubercode.

I just posted an update to the uc_cim module that includes these bug fixes and an Ubercart RC5 compatibility upgrade. Note that I'm not sure this release will be compatible with prior versions of Ubercart. Let me know if you have any problems with it.

Posts: 15
Joined: 04/03/2008

Fatal error: Call to undefined function uc_credit_cache() in XXXXXXXX/modules/uc_cim/uc_cim.module on line 687

Any ideas?

Posts: 23
Joined: 04/04/2008

I'm using the new version as I have Ubercart RC5 installed and for some reason it does not recognize that I already have a CIM profile. In the checkout screen it does not ask me to use the current details so I enter new customer information. But when it goes to process the payment, I'm getting this error...
Customer profile could not be created. User: 1, Error: A duplicate record already exists.

Do you know what could be happening?

--

Chisholm Technologies, Inc.
Custom software development since 1999!
www.chisholmtech.com

Posts: 23
Joined: 04/04/2008

When I checkout, I'm getting these messages:

warning: split() [function.split]: REG_EMPTY in xxxxxx/ubercart/contrib/uc_cim/uc_cim.module on line 444.

We were unable to process your credit card payment. Please verify your card details and try again. If the problem persists, contact us to complete your order.

A quick look at line 444 tells me that it does not compare the correct delimiter ('|') when the results are returned.

I changed the split to explode and it works. The split function delimits on regular expressions whereas explode delimits on plain strings. Suggest that you change the splits to explodes since you're not using a regular expression as a delimiter, and explode is faster.

--

Chisholm Technologies, Inc.
Custom software development since 1999!
www.chisholmtech.com

Posts: 68
Joined: 12/28/2007
Bug FinderGetting busy with the Ubercode.

@paulcouture - it sounds like you're using the latest uc_cim release with an old version of Ubercart. I think that function was added in RC5.

@amaria - for your first problem, it sounds like your database is missing information in the uc_cim or uc_cim_TEST (if you're using the developer test mode) table. I'm not sure how this would have happened... did you uninstall the module ever? Or are you using the same Authorize.net account for more than one site/database? For your second issue, thanks for suggestion. I haven't had problems with split, but I'll make the change.

Best,
Chad

Posts: 23
Joined: 04/04/2008

I get this error message when the gateway itself is in Test mode while the payment gateway settings of uc_cim is in Production mode:
Payment failed: Credit card payment failed: The payment gateway account is in Test Mode. The request cannot be processed.
Shouldn't that work?

--

Chisholm Technologies, Inc.
Custom software development since 1999!
www.chisholmtech.com

Posts: 23
Joined: 04/04/2008

Whenever a recurring payment is collected I am getting this error:

You can only use the Authorize.net CIM payment method with the uc_cim_recurring_fee handler.

A quick look at the code where this message is located, around line 221, you have

<?php
  
if ($order->payment_method !== 'uc_cim') {
?>

This should be:

<?php
  
if (variable_get('uc_recurring_handler', 'uc_recurring') !== 'uc_cim') {
?>

...since payment method is going to be 'credit' not 'uc_cim'.

--

Chisholm Technologies, Inc.
Custom software development since 1999!
www.chisholmtech.com