cancel
Showing results for 
Search instead for 
Did you mean: 

partial authorization transaction

Hello , 

How can i make test for partial transaction ?

 

Thanks .

mahmood00
Member
1 ACCEPTED SOLUTION

Accepted Solutions

The response show it using 46227 and not 46225, can you log your request xml?

 

my xml

<?xml version=\"1.0\" encoding=\"utf-8\"?><createCustomerProfileTransactionRequest xmlns=\"AnetApi/xml/v1/schema/AnetApiSchema.xsd\"><merchantAuthentication><name>xxxxx</name><transactionKey>xxxxxx</transactionKey></merchantAuthentication><transaction><profileTransAuthCapture><amount>462.25</amount><customerProfileId>xxxxx</customerProfileId><customerPaymentProfileId>xxxxx</customerPaymentProfileId></profileTransAuthCapture></transaction><extraOptions><![CDATA[x_allow_partial_auth=TRUE&x_zip=46225]]></extraOptions></createCustomerProfileTransactionRequest>

 response

<?xml version="1.0" encoding="utf-8"?><createCustomerProfileTransactionResponse xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="AnetApi/xml/v1/schema/AnetApiSchema.xsd"><messages><resultCode>Ok</resultCode><message><code>I00001</code><text>Successful.</text></message></messages><directResponse>4,1,295,The amount of this request was only partially approved on the given prepaid card. An additional payment is required to fulfill the balance of this transaction.,NR1AIF,Y,2219104636,,,1.23,CC,auth_capture,,,,,,,,46225,,,,fake@example.com,,,,,,,,,,,,,,22D3CA9DFB1CCA874F91E8F0D4DCFE2C,,2,,,,,,,,,,,XXXX1111,Visa,113348,462.25,,,,,,,,,,,,,,</directResponse></createCustomerProfileTransactionResponse>

 

View solution in original post

6 REPLIES 6

Use the http://developer.authorize.net/tools/errorgenerationguide/

If you are using CIM, set the x_zip on the extraOptions

RaynorC1emen7
Expert

Thank you , 

 

well , i sent the x_zip in 

<extraOptions><![CDATA[x_allow_partial_auth="TRUE"&x_zip=46225&x_test_request="TRUE"]]></extraOptions>

 

but i got the same response  "This transaction has been approved." without Split Tender ID , that mean there is no partial transaction , right ??

 

Are you using production live account? You can't test with it.

Get a sandbox account https://developer.authorize.net/sandbox/

 

don't send x_test_request=TRUE, test_request will always return transaction id 0.

and you don't need double quote, it like a url param.

 

it still not working , im using sandbox account .

 

look , im sending this requeste to  url  = 'https://apitest.authorize.net/xml/v1/request.api';

 

$this->xml = '<?xml version="1.0" encoding="utf-8"?>
                          <createCustomerProfileTransactionRequest xmlns="AnetApi/xml/v1/schema/AnetApiSchema.xsd">
                              <merchantAuthentication>
                                  <name>' . $this->login . '</name>
                                  <transactionKey>' . $this->transkey . '</transactionKey>
                              </merchantAuthentication>
                              <transaction>
                                  <' . $type . '>
                                      <amount>' . $info['amount'] . '</amount>';
            if (isset($info['taxAmount'])) {
                $this->xml .= '
                                      <tax>
                                           <amount>' . $info['taxAmount'] . '</amount>
                                           <name>' . $info['taxName'] . '</name>
                                           <description>' . $info['taxDescription'] . '</description>
                                      </tax>';
                                      
            }
            if (isset($info['shipAmount'])) {
                $this->xml .= '
                                      <shipping>
                                           <amount>' . $info['shipAmount'] . '</amount>
                                           <name>' . $info['shipName'] . '</name>
                                           <description>' . $info['shipDescription'] . '</description>
                                      </shipping>';
                                      
            }
            if (isset($info['dutyAmount'])) {
                $this->xml .= '
                                      <duty>
                                           <amount>' . $info['dutyAmount'] . '</amount>
                                           <name>' . $info['dutyName'] . '</name>
                                           <description>' . $info['dutyDescription'] . '</description>
                                      </duty>';
                                      
            }
            $this->xml .= '
                                      <customerProfileId>' . $info['customerProfileId'] . '</customerProfileId>
                                      <customerPaymentProfileId>' . $info['customerPaymentProfileId'] . '</customerPaymentProfileId>';
            if (isset($info['invoiceNumber'])) {
                        $this->xml .='<order>
                                           <invoiceNumber>' . $info['invoiceNumber'] . '</invoiceNumber>
                                           <description>' . $info['description'] . '</description>
                                           <purchaseOrderNumber>' . $info['purchaseOrderNumber'] . '</purchaseOrderNumber>
                                      </order>';
                                      
            }
                        $this->xml .= '<taxExempt>' . $info['taxExempt'] . '</taxExempt>
                                      <recurringBilling>' . Configure::read('RECURRING_BILLING') . '</recurringBilling>';
            if (isset($info['cardCode'])) {
                        $this->xml .= '<cardCode>' . $info['cardCode'] . '</cardCode>';
                                      
            }
            if (isset($info['approvalCode'])) {
                         $this->xml .= '<approvalCode>' . $info['approvalCode'] . '</approvalCode>';
                                      
            }
                     $this->xml .= ' </' . $type . '>
                              </transaction>
                              <extraOptions><![CDATA[x_duplicate_window=0&x_allow_partial_auth=TRUE&x_zip=46225]]></extraOptions>
                          </createCustomerProfileTransactionRequest>';

 

 

and this response :

'<?xml version="1.0" encoding="utf-8"?><createCustomerProfileTransactionResponse xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="AnetApi/xml/v1/schema/AnetApiSchema.xsd"><messages><resultCode>Ok</resultCode><message><code>I00001</code><text>Successful.</text></message></messages><directResponse>1,1,1,This transaction has been approved.,FH9M1R,Y,2219103735,INV000002,desc..,462.25,CC,auth_only,26,,,,,,,46227,,,,wah@gmail.com,,,,,,,,,2.00,,2.00,FALSE,PONUM000002,4DB78792EBC773241BFFF7E4CDE3CAA6,,2,,,,,,,,,,,XXXX0002,American Express,,,,,,,,,,,,,,,,</directResponse></createCustomerProfileTransactionResponse>

is there any reason to not make partial transaction ..!?

The response show it using 46227 and not 46225, can you log your request xml?

 

my xml

<?xml version=\"1.0\" encoding=\"utf-8\"?><createCustomerProfileTransactionRequest xmlns=\"AnetApi/xml/v1/schema/AnetApiSchema.xsd\"><merchantAuthentication><name>xxxxx</name><transactionKey>xxxxxx</transactionKey></merchantAuthentication><transaction><profileTransAuthCapture><amount>462.25</amount><customerProfileId>xxxxx</customerProfileId><customerPaymentProfileId>xxxxx</customerPaymentProfileId></profileTransAuthCapture></transaction><extraOptions><![CDATA[x_allow_partial_auth=TRUE&x_zip=46225]]></extraOptions></createCustomerProfileTransactionRequest>

 response

<?xml version="1.0" encoding="utf-8"?><createCustomerProfileTransactionResponse xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="AnetApi/xml/v1/schema/AnetApiSchema.xsd"><messages><resultCode>Ok</resultCode><message><code>I00001</code><text>Successful.</text></message></messages><directResponse>4,1,295,The amount of this request was only partially approved on the given prepaid card. An additional payment is required to fulfill the balance of this transaction.,NR1AIF,Y,2219104636,,,1.23,CC,auth_capture,,,,,,,,46225,,,,fake@example.com,,,,,,,,,,,,,,22D3CA9DFB1CCA874F91E8F0D4DCFE2C,,2,,,,,,,,,,,XXXX1111,Visa,113348,462.25,,,,,,,,,,,,,,</directResponse></createCustomerProfileTransactionResponse>

 

Thaaanks man .

 

i have problem bcoz i set  recurringBilling  true .

after set it as false it's work with me :D