7 my( $username, $password ) = ( @ARGV );
9 my $uri = new URI 'http://localhost:8008/';
11 my $server = new Frontier::Client ( 'url' => $uri );
13 my $result = $server->call('FS.API.new_customer',
15 'secret' => 'sharingiscaring',
19 'refnum' => 1, #advertising source
20 'agent_custid' => '', #'323',
21 'referral_custnum' => 1,
25 'company' => 'Bank of Soymerica',
28 'address1' => '1234 Soybean Ln.',
41 'daytime' => '555 444 3211',
44 'mobile' => '123 466 3332',
47 'invoicing_list' => 'tofu@example.com', #comma-separated email addresses
48 'postal_invoicing' => 1,
51 'payby' => 'CARD', # DCRD, CHEK, DCHK, BILL, etc.
52 'payinfo' => '4111111111111111',#card number / acctno@routing / PO#
53 'paydate' => '11/2019', #card expiration
54 'paycvv' => '123', #card CVV/security code
55 'payname' => 'Thomas Beast', #"Exact name on card" if different
58 die $result->{'error'} if $result->{'error'};
60 my $custnum = $result->{'custnum'};
61 warn "added new customer w/custnum $custnum\n";