The following simple examples illustrate how to use the BCI API from an application built using PHP 5 and SOAP.
Example 1: Authenticatation using SOAP
__setLocation("https://api.bciaustralia.com/auth.cfc");
$result = $client->doLogin(array('clientID' => "apiuser", 'password' => "dummypassword"));
}
catch (SoapFault $fault) //catch any error with failed attempt
{
echo "Login Failed with this error: ".$fault->faultstring;
exit;
}
//continue with login and save token into variable
$token = $result->return->entry->value;