コード例 #1
0
 echo "<br/>";
 echo "countryCodeA3: " . $listCountry->countries[0]->countryCodeA3 . "<br/>";
 echo "countryName: " . $listCountry->countries[0]->countryName . "<br/>";
 echo "phoneCode: " . $listCountry->countries[0]->phoneCode . "<br/>";
 echo "hasStates: " . $listCountry->countries[0]->hasStates . "<br/>";
 echo "hasRegulationRequirement: " . $listCountry->countries[0]->hasRegulationRequirement . "<br/>";
 //List Restrictions
 $listRestrictions = $controller->getRestrictions($countryCodeA3);
 echo "<br/><br/><br/>";
 echo "<b>List Restrictions Request content</b><br/>";
 echo "<br/>";
 echo "countryCodeA3: " . $listRestrictions->restrictions[0]->countryCodeA3 . "<br/>";
 echo "restrictionType: " . $listRestrictions->restrictions[0]->restrictionType . "<br/>";
 echo "restrictionMessage: " . $listRestrictions->restrictions[0]->restrictionMessage . "<br/>";
 //List DID
 $listDid = $controller->getDids(1, 0);
 echo "<br/><br/><br/>";
 echo "<b>List DIDs Request content</b><br/>";
 echo "<br/>";
 echo "didId: " . $listDid->dids[0]->didId . "<br/>";
 echo "e164: " . $listDid->dids[0]->e164 . "<br/>";
 echo "type: " . $listDid->dids[0]->type . "<br/>";
 echo "countryCodeA3: " . $listDid->dids[0]->countryCodeA3 . "<br/>";
 echo "cityName: " . $listDid->dids[0]->cityName . "<br/>";
 echo "areaCode: " . $listDid->dids[0]->areaCode . "<br/>";
 echo "voiceUriId: " . $listDid->dids[0]->voiceUriId . "<br/>";
 echo "faxUriId: " . $listDid->dids[0]->faxUriId . "<br/>";
 echo "smsLinkGroupId: " . $listDid->dids[0]->smsLinkGroupId . "<br/>";
 echo "orderReference: " . $listDid->dids[0]->orderReference . "<br/>";
 echo "channels: " . $listDid->dids[0]->channels . "<br/>";
 echo "delivery: " . $listDid->dids[0]->delivery . "<br/>";
コード例 #2
0
 echo "companyDescription: " . $listAddresses->regulationAddresses[0]->companyDescription . "<br/>";
 echo "firstName: " . $listAddresses->regulationAddresses[0]->firstName . "<br/>";
 echo "lastName: " . $listAddresses->regulationAddresses[0]->lastName . "<br/>";
 echo "countryCodeA3: " . $listAddresses->regulationAddresses[0]->countryCodeA3 . "<br/>";
 echo "city: " . $listAddresses->regulationAddresses[0]->city . "<br/>";
 echo "zipCode: " . $listAddresses->regulationAddresses[0]->zipCode . "<br/>";
 echo "streetName: " . $listAddresses->regulationAddresses[0]->streetName . "<br/>";
 echo "buildingNumber: " . $listAddresses->regulationAddresses[0]->buildingNumber . "<br/>";
 echo "buildingLetter: " . $listAddresses->regulationAddresses[0]->buildingLetter . "<br/>";
 echo "customerReference: " . $listAddresses->regulationAddresses[0]->customerReference . "<br/>";
 echo "extraFields: " . $listAddresses->regulationAddresses[0]->extraFields . "<br/>";
 echo "rejectionReasons: " . $listAddresses->regulationAddresses[0]->rejectionReasons[0] . "<br/>";
 echo "<br/><br/>";
 //Link Address
 echo "<b>Link Address</b><br/>";
 $getDidId = $inventoryController->getDids(1, 0, NULL, NULL, NULL, NULL, NULL, 'DNK');
 $didId = $getDidId->dids[0]->didId;
 $didIds = array($didId);
 $body = new DidIdListModel($didIds);
 $linkAddress = $controller->addressLink($verifiedAddress, $body);
 echo "didId: " . $didId . "<br/>";
 echo "status: " . $verification->status . "<br/>";
 echo "<br/><br/><br/>";
 //Unlink Address
 echo "<b>Unink Address</b><br/>";
 $getDidId = $inventoryController->getDids(1, 0, NULL, NULL, NULL, NULL, NULL, 'DNK');
 $didId = $getDidId->dids[0]->didId;
 $didIds = array($didId);
 $body = array('didIds' => $didIds);
 $unlinkAddress = $controller->addressUnlink($body);
 echo "didId: " . $didId . "<br/>";
コード例 #3
0
 //List Cart
 $listTheCart = $controller->getCartDetails($cartIdentifier);
 echo "<b>Get orderProductId (listCart) Response</b><br/>";
 echo "orderProductId: " . $listTheCart->carts[0]->orderProducts[0]->orderProductId . "<br/>";
 echo "orderQuantity: " . $listTheCart->carts[0]->orderProducts[0]->quantity . "<br/>";
 echo "<br/><br/>";
 //Checkout Cart
 $cartCheckout = $controller->getCartCheckout($cartIdentifier);
 echo "<b>CheckoutCart Response</b><br/>";
 echo "orderReference: " . $cartCheckout->productCheckoutList[0]->orderReference . "<br/>";
 echo "status: " . $cartCheckout->status . "<br/>";
 echo "<br/><br/>";
 $orderReference = $cartCheckout->productCheckoutList[0]->orderReference;
 //Cancel DIDs
 //First listDidIds
 $getDidIds = $inventoryController->getDids(1, 0, NULL, NULL, NULL, NULL, $orderReference);
 echo "<b>Get DID Ordered Response</b><br/>";
 echo "didid: " . $getDidIds->dids[0]->didId . "<br/>";
 $didId = $getDidIds->dids[0]->didId;
 echo "<br/><br/>";
 $didIds = array($didId);
 $body = new DidIdListModel($didIds);
 $cancelDids = $controller->createCancel($body);
 echo "<b>Get Cancel Response</b><br/>";
 echo "numberCancelled: " . $cancelDids->numberCancelled . "<br/>";
 echo "<br/><br/>";
 function listTheOrder($orderReference)
 {
     //List Order
     $controller = new OrderingController();
     $listOrder = $controller->getOrders(0, 1, $orderReference, NULL, NULL, NULL, NULL, NULL, NULL);