Reply
Member
Posts: 1
Registered: ‎01-30-2018

Customer ID field ID

Hi - My client needs to send a customer ID to Authorize.net via a custom form.  (I'm using gravity forms/wordpress - so the code below is the hook I needed to add to my functions.php in order to pass a new field input to Auth.net.) 

 

I believe I just need to replace "your_field_name" with the actual id of the Customer ID field in authorize.  Any clues where I'd find this or does anyone know?

 

 

add_filter( 'gform_authorizenet_transaction_pre_capture', 'add_custom_field', 10, 5 );
function add_custom_field( $transaction, $form_data, $config, $form, $entry ) {
    if ( $form['id'] == 9 ) {
        $value = rgpost( 'input_9');
        $transaction->setCustomField( 'your_field_name', $value );
    }
 
    return $transaction;
}

 

Member
Posts: 1
Registered: ‎03-08-2018

Re: Customer ID field ID

 

The field name is cust_id, so in this case you would use:

$transaction->cust_id = $value;

 

Member
Posts: 2
Registered: ‎04-24-2019

Re: Customer ID field ID

I want to do the same thing. Gravity Forms gives this example

 

add_filter( 'gform_authorizenet_transaction_pre_capture', 'add_custom_field', 10, 5 );
function add_custom_field( $transaction, $form_data, $config, $form, $entry ) {
if ( $form['id'] == 1 ) {
$value = rgpost( 'input_6');
$transaction->setCustomField( 'Patient_Account_Number', $value );
}

return $transaction;
}

 

Will this pass the patient account number to Authorize?

Member
Posts: 2
Registered: ‎04-24-2019

Re: Customer ID field ID

I want to do the same thing. Gravity Forms gives this example

 

add_filter( 'gform_authorizenet_transaction_pre_capture', 'add_custom_field', 10, 5 );
function add_custom_field( $transaction, $form_data, $config, $form, $entry ) {
if ( $form['id'] == 1 ) {
$value = rgpost( 'input_6');
$transaction->setCustomField( 'Patient_Account_Number', $value );
}

return $transaction;
}

 

Will this pass the patient account number to Authorize?