Hosted Checkout Advanced Integration

Hosted Checkout — Advanced Integration

Pre-Populating Customer Data

$post = array(
    'security_key' => YOUR_PRIVATE_KEY,
    'type'         => 'sale',
    'amount'       => '49.99',
    'firstname'    => 'John',
    'lastname'     => 'Smith',
    'email'        => 'john@example.com',
    'address1'     => '123 Main St',
    'city'         => 'Miami',
    'state'        => 'FL',
    'zip'          => '33101',
    'country'      => 'US',
    'order_id'     => 'ORDER-789',
);

Recurring Billing via Hosted Checkout

$post = array(
    'security_key'    => YOUR_PRIVATE_KEY,
    'type'            => 'sale',
    'amount'          => '9.99',
    'recurring'       => 'add_subscription',
    'plan_payments'   => '0',        // 0 = indefinite
    'plan_amount'     => '9.99',
    'month_frequency' => '1',
    'day_of_month'    => '1',
    'start_date'      => date('Y-m-d', strtotime('+1 month')),
);

Storing to Customer Vault

$post['customer_vault']    = 'add_customer';
$post['customer_vault_id'] = 'CUST-' . $user_id;  // Optional custom ID

Key Notification Response Fields

FieldDescription
response1=Approved, 2=Declined, 3=Error
transactionidUnique gateway transaction ID
authcodeCard network authorization code
avsresponseAddress verification result
cvvresponseCVV verification result
amountTransaction amount charged
order_idYour order ID (echoed back)
Always validate that transactionid matches a pending order in your system and verify the amount before fulfilling any order.

Take Your Business to the Next Level

Find out how our innovative payment solutions can benefit your business. Reach out to us for more information or to get started!

Let's Get Started