# Creating an Account Credential
# Refer to API Usage section for how to
# create an instance of SOAP::Lite
# ie  $soap_client = new SOAP::Lite ....
  # create a network and capture its RII
  # see previous example for details
  # $soap_response = $soap_client->createNetwork($new_network_info);
  # $new_net_rii = $soap_response->result;
  $acct_rii = {
    resourceName => 'TestAcctCredName',
    resourceType => 'ACCT-CREDENTIAL',
    resourceKey => undef};
  bless $acct_rii, 'ResourceIdentityInfo';
  $acct_cred_info = {
    id => $acct_rii,
    userName => 'TestAcctUserName',
    password => 'TestAcctCredPass'};
  bless $acct_cred_info, 'AcctCredentialInfo';
  # build param 0
  $acct_param = new SOAP::Data
    name => 'in0',
    attr => {'xsi:type' => ref($acct_cred_info)},
    value => $acct_cred_info;
  # build param 1
  $net_param = new SOAP::Data
    name => 'in1',
    attr => {'xsi:type' =>  ref($new_net_rii)},
    value => $new_net_rii;
  # Create the account credential.
  $soap_response = 
    $soap_client->createAccountCredential($acct_param, $net_param);
  if ($soap_response->fault) {
    print "\nSOAP fault: ".$soap_response->faultstring."\n";
   }
  else {
    $acct_rii = $soap_response->result;
    print "\nNew resourceKey is: ".$acct_rii->{'resourceKey'}."\n";
  }