// If you want to see the full XML input/output, you can turn on debug mode
//$MS->useDebugMode(true);
// Now, let's create a credit card object, and authorize an amount agains the card
$name = 'Keith Palmer';
$number = '5105105105105100';
$expyear = date('Y');
$expmonth = date('m');
$address = '56 Cowles Road';
$postalcode = '06279';
$cvv = '349';
// Create the CreditCard object
$Card = new QuickBooks_MerchantService_CreditCard($name, $number, $expyear, $expmonth, $address, $postalcode, $cvv);
// Our customer #
$customerID = '1234ABCD';
// Add this credit card to the wallet
if ($walletID = $MS->addWallet($customerID, $Card)) {
    print 'New wallet ID created: ' . $walletID . "\n";
} else {
    print 'An error occurred: [' . $MS->errorNumber() . ': ' . $MS->errorMessage() . ']' . "\n";
}
exit;
// Now, let's update it
$Card->setName('Keith R. Palmer Jr.');
if ($MS->updateWallet($customerID, $walletID, $Card)) {
    print 'Wallet updated!' . "\n";
} else {
    print 'An error occurred: [' . $MS->errorNumber() . ': ' . $MS->errorMessage() . ']' . "\n";
}
// Fetch it
if ($CreditCard = $MS->getWallet($customerID, $walletID)) {
    print_r($CreditCard);