NAME

FS::SignupClient - Freeside signup client API


SYNOPSIS

  use FS::SignupClient qw( signup_info new_customer );
  ( $locales, $packages, $pops ) = signup_info;
  $error = new_customer ( {
    'first'            => $first,
    'last'             => $last,
    'ss'               => $ss,
    'comapny'          => $company,
    'address1'         => $address1,
    'address2'         => $address2,
    'city'             => $city,
    'county'           => $county,
    'state'            => $state,
    'zip'              => $zip,
    'country'          => $country,
    'daytime'          => $daytime,
    'night'            => $night,
    'fax'              => $fax,
    'payby'            => $payby,
    'payinfo'          => $payinfo,
    'paydate'          => $paydate,
    'payname'          => $payname,
    'invoicing_list'   => $invoicing_list,
    'referral_custnum' => $referral_custnum,
    'pkgpart'          => $pkgpart,
    'username'         => $username,
    '_password'        => $password,
    'popnum'           => $popnum,
  } );


DESCRIPTION

This module provides an API for a remote signup server.

It needs to be run as the freeside user. Because of this, the program which calls these subroutines should be written very carefully.


SUBROUTINES

signup_info
Returns three array references of hash references.

The first set of hash references is of allowable locales. Each hash reference has the following keys: taxnum state county country

The second set of hash references is of allowable packages. Each hash reference has the following keys: pkgpart pkg

The third set of hash references is of allowable POPs (Points Of Presence). Each hash reference has the following keys: popnum city state ac exch

new_customer HASHREF
Adds a customer to the remote Freeside system. Requires a hash reference as a paramater with the following keys: first last ss comapny address1 address2 city county state zip country daytime night fax payby payinfo paydate payname invoicing_list referral_custnum pkgpart username _password popnum

Returns a scalar error message, or the empty string for success.


BUGS


SEE ALSO

fs_signupd, the FS::SignupServer manpage, the FS::cust_main manpage