Page 1 of 1

Sending Itemized order information to Authorize.net

Posted: Thu Jun 24, 2010 11:23 pm
by MMIKAL
Hi

I was wondering if any of you guys have tried to send Itemized order information to Authorize.net.
In our existing site, the admin panel in Authorize.net shows itemized orther information which is sent along the transaction,
so for each transction, besides the order number, it also shows the SKU, Qty and product name.

Any tip is on how to tackle it is highly appriciated.

Re: Sending Itemized order information to Authorize.net

Posted: Fri Jun 25, 2010 11:56 am
by Kalamazoo
Hi MMIKAL,

We have used this spec from authorize.net to work from: (I don't know if this will help at all)

Code: Select all

SKU <|>  Name <|>  Option (additional info) <|> Quantity <|> Price <|> Taxable (0 or 1) for each line item. Authorize.net accepts lengths up to 30...cannot go over...SKU - 30 chars, Name - 30 chars
All the best,

Phil

Re: Sending Itemized order information to Authorize.net

Posted: Fri Jun 25, 2010 12:42 pm
by MMIKAL
Hi Phil

Thanks for your reply.
That is exactly what I want, but honestly I do not know where to put it. I can not find it on the Authorize.net panel in AC.

Thank you in advance.

Re: Sending Itemized order information to Authorize.net

Posted: Sat Jun 26, 2010 7:05 am
by jmestep
You would have to modify the Authorize.net source code.
Here is a link to the wiki about it, with a link at the bottom to download the source code:
http://wiki.ablecommerce.com/index.php/ ... nt_Gateway

Basically, what you would need to do would be to add a section called something like

Code: Select all

 private string BuildGatewayRequestPart_OrderItemData(Order order)
{
...
}
Then you would need to add your method to
BuildGatewayRequest_Authorize section

Then compile it and replace the default dll in the Bin folder with your version.


Or you might be able to add it to this section which sends some of the orderitem data

Code: Select all

private string BuildGatewayRequestPart_Level2Data(Order order)
        {
            if (order != null)
            {
                decimal taxAmount = (decimal)order.Items.TotalPrice(OrderItemType.Tax);
                decimal shippingAmount = (decimal)order.Items.TotalPrice(OrderItemType.Shipping, OrderItemType.Handling);
                return "&x_tax=" + taxAmount.ToString("F2") + "&x_freight=" + shippingAmount.ToString("F2");
            }
            return string.Empty;
        }

Re: Sending Itemized order information to Authorize.net

Posted: Sat Jun 26, 2010 11:55 am
by MMIKAL
Thanks Judy, Phil, I will give it a try.

Re: Sending Itemized order information to Authorize.net

Posted: Tue Jul 06, 2010 2:38 pm
by Kalamazoo
MMikal,

Let me know how it works out for you.

Phil Chrisman

Re: Sending Itemized order information to Authorize.net

Posted: Wed Jul 07, 2010 5:54 pm
by MMIKAL
Hi Phil, Not yet, Busy with other stuff, will look at it soon. Thanks