/**
* This file aims to show you how to use this generated package.
* In addition, the goal is to show which methods are available and the first needed parameter(s)
* You have to use an associative array such as:
* - the key must be a constant beginning with WSDL_ from AbstractSoapClientBase class (each generated ServiceType class extends this class)
* - the value must be the corresponding key value (each option matches a {@link http://www.php.net/manual/en/soapclient.soapclient.php} option)
* $options = array(
* \WsdlToPhp\PackageBase\AbstractSoapClientBase::WSDL_URL => 'https://e-nadawca.poczta-polska.pl/websrv/en.wsdl',
* \WsdlToPhp\PackageBase\AbstractSoapClientBase::WSDL_TRACE => true,
* \WsdlToPhp\PackageBase\AbstractSoapClientBase::WSDL_LOGIN => 'you_secret_login',
* \WsdlToPhp\PackageBase\AbstractSoapClientBase::WSDL_PASSWORD => 'you_secret_password',
* );
* etc...
*/
require_once __DIR__ . '/vendor/autoload.php';
/**
* Minimal options
*/
$options = array(
\WsdlToPhp\PackageBase\AbstractSoapClientBase::WSDL_URL => 'https://e-nadawca.poczta-polska.pl/websrv/en.wsdl',
\WsdlToPhp\PackageBase\AbstractSoapClientBase::WSDL_CLASSMAP => ClassMap::get(),
);
/**
* Samples for Add ServiceType
*/
$add = new \ServiceType\Add($options);
/**
* Sample call for addShipment operation/method
*/
if ($add->addShipment(new \StructType\AddShipment()) !== false) {
print_r($add->getResult());
} else {
print_r($add->getLastError());
}
/**
* Sample call for addReklamacje operation/method
*/
if ($add->addReklamacje(new \StructType\AddReklamacje()) !== false) {
print_r($add->getResult());
} else {
print_r($add->getLastError());
}
/**
* Sample call for addOdwolanieDoReklamacji operation/method
*/
if ($add->addOdwolanieDoReklamacji(new \StructType\AddOdwolanieDoReklamacji()) !== false) {
print_r($add->getResult());
} else {
print_r($add->getLastError());
}
/**
* Sample call for addRozbieznoscDoZapowiedziFaktur operation/method
*/
if ($add->addRozbieznoscDoZapowiedziFaktur(new \StructType\AddRozbieznoscDoZapowiedziFaktur()) !== false) {
print_r($add->getResult());
} else {
print_r($add->getLastError());
}
/**
* Sample call for addZalacznikDoReklamacji operation/method
*/
if ($add->addZalacznikDoReklamacji(new \StructType\AddZalacznikDoReklamacji()) !== false) {
print_r($add->getResult());
} else {
print_r($add->getLastError());
}
/**
* Samples for Change ServiceType
*/
$change = new \ServiceType\Change($options);
/**
* Sample call for changePassword operation/method
*/
if ($change->changePassword(new \StructType\ChangePassword()) !== false) {
print_r($change->getResult());
} else {
print_r($change->getLastError());
}
/**
* Samples for Send ServiceType
*/
$send = new \ServiceType\Send($options);
/**
* Sample call for sendEnvelope operation/method
*/
if ($send->sendEnvelope(new \StructType\SendEnvelope()) !== false) {
print_r($send->getResult());
} else {
print_r($send->getLastError());
}
/**
* Samples for Get ServiceType
*/
$get = new \ServiceType\Get($options);
/**
* Sample call for getUrzedyNadania operation/method
*/
if ($get->getUrzedyNadania(new \StructType\GetUrzedyNadania()) !== false) {
print_r($get->getResult());
} else {
print_r($get->getLastError());
}
/**
* Sample call for getUrzedyWydajaceEPrzesylki operation/method
*/
if ($get->getUrzedyWydajaceEPrzesylki(new \StructType\GetUrzedyWydajaceEPrzesylki()) !== false) {
print_r($get->getResult());
} else {
print_r($get->getLastError());
}
/**
* Sample call for getEnvelopeStatus operation/method
*/
if ($get->getEnvelopeStatus(new \StructType\GetEnvelopeStatus()) !== false) {
print_r($get->getResult());
} else {
print_r($get->getLastError());
}
/**
* Sample call for getKarty operation/method
*/
if ($get->getKarty(new \StructType\GetKarty()) !== false) {
print_r($get->getResult());
} else {
print_r($get->getLastError());
}
/**
* Sample call for getPasswordExpiredDate operation/method
*/
if ($get->getPasswordExpiredDate(new \StructType\GetPasswordExpiredDate()) !== false) {
print_r($get->getResult());
} else {
print_r($get->getLastError());
}
/**
* Sample call for getEnvelopeContentShort operation/method
*/
if ($get->getEnvelopeContentShort(new \StructType\GetEnvelopeContentShort()) !== false) {
print_r($get->getResult());
} else {
print_r($get->getLastError());
}
/**
* Sample call for getEnvelopeContentFull operation/method
*/
if ($get->getEnvelopeContentFull(new \StructType\GetEnvelopeContentFull()) !== false) {
print_r($get->getResult());
} else {
print_r($get->getLastError());
}
/**
* Sample call for getAddressLabel operation/method
*/
if ($get->getAddressLabel(new \StructType\GetAddressLabel()) !== false) {
print_r($get->getResult());
} else {
print_r($get->getLastError());
}
/**
* Sample call for getOutboxBook operation/method
*/
if ($get->getOutboxBook(new \StructType\GetOutboxBook()) !== false) {
print_r($get->getResult());
} else {
print_r($get->getLastError());
}
/**
* Sample call for getFirmowaPocztaBook operation/method
*/
if ($get->getFirmowaPocztaBook(new \StructType\GetFirmowaPocztaBook()) !== false) {
print_r($get->getResult());
} else {
print_r($get->getLastError());
}
/**
* Sample call for getEnvelopeList operation/method
*/
if ($get->getEnvelopeList(new \StructType\GetEnvelopeList()) !== false) {
print_r($get->getResult());
} else {
print_r($get->getLastError());
}
/**
* Sample call for getAddresLabelByGuid operation/method
*/
if ($get->getAddresLabelByGuid(new \StructType\GetAddresLabelByGuid()) !== false) {
print_r($get->getResult());
} else {
print_r($get->getLastError());
}
/**
* Sample call for getPlacowkiPocztowe operation/method
*/
if ($get->getPlacowkiPocztowe(new \StructType\GetPlacowkiPocztowe()) !== false) {
print_r($get->getResult());
} else {
print_r($get->getLastError());
}
/**
* Sample call for getGuid operation/method
*/
if ($get->getGuid(new \StructType\GetGuid()) !== false) {
print_r($get->getResult());
} else {
print_r($get->getLastError());
}
/**
* Sample call for getKierunki operation/method
*/
if ($get->getKierunki(new \StructType\GetKierunki()) !== false) {
print_r($get->getResult());
} else {
print_r($get->getLastError());
}
/**
* Sample call for getKierunkiInfo operation/method
*/
if ($get->getKierunkiInfo(new \StructType\GetKierunkiInfo()) !== false) {
print_r($get->getResult());
} else {
print_r($get->getLastError());
}
/**
* Sample call for getEnvelopeBufor operation/method
*/
if ($get->getEnvelopeBufor(new \StructType\GetEnvelopeBufor()) !== false) {
print_r($get->getResult());
} else {
print_r($get->getLastError());
}
/**
* Sample call for getEPOStatus operation/method
*/
if ($get->getEPOStatus(new \StructType\GetEPOStatus()) !== false) {
print_r($get->getResult());
} else {
print_r($get->getLastError());
}
/**
* Sample call for getAddresLabelCompact operation/method
*/
if ($get->getAddresLabelCompact(new \StructType\GetAddresLabelCompact()) !== false) {
print_r($get->getResult());
} else {
print_r($get->getLastError());
}
/**
* Sample call for getAddresLabelByGuidCompact operation/method
*/
if ($get->getAddresLabelByGuidCompact(new \StructType\GetAddresLabelByGuidCompact()) !== false) {
print_r($get->getResult());
} else {
print_r($get->getLastError());
}
/**
* Sample call for getEnvelopeBuforList operation/method
*/
if ($get->getEnvelopeBuforList(new \StructType\GetEnvelopeBuforList()) !== false) {
print_r($get->getResult());
} else {
print_r($get->getLastError());
}
/**
* Sample call for getUbezpieczeniaInfo operation/method
*/
if ($get->getUbezpieczeniaInfo(new \StructType\GetUbezpieczeniaInfo()) !== false) {
print_r($get->getResult());
} else {
print_r($get->getLastError());
}
/**
* Sample call for getBlankietPobraniaByGuids operation/method
*/
if ($get->getBlankietPobraniaByGuids(new \StructType\GetBlankietPobraniaByGuids()) !== false) {
print_r($get->getResult());
} else {
print_r($get->getLastError());
}
/**
* Sample call for getAccountList operation/method
*/
if ($get->getAccountList(new \StructType\GetAccountList()) !== false) {
print_r($get->getResult());
} else {
print_r($get->getLastError());
}
/**
* Sample call for getProfilList operation/method
*/
if ($get->getProfilList(new \StructType\GetProfilList()) !== false) {
print_r($get->getResult());
} else {
print_r($get->getLastError());
}
/**
* Sample call for getReklamacje operation/method
*/
if ($get->getReklamacje(new \StructType\GetReklamacje()) !== false) {
print_r($get->getResult());
} else {
print_r($get->getLastError());
}
/**
* Sample call for getZapowiedziFaktur operation/method
*/
if ($get->getZapowiedziFaktur(new \StructType\GetZapowiedziFaktur()) !== false) {
print_r($get->getResult());
} else {
print_r($get->getLastError());
}
/**
* Sample call for getListaPowodowReklamacji operation/method
*/
if ($get->getListaPowodowReklamacji(new \StructType\GetListaPowodowReklamacji()) !== false) {
print_r($get->getResult());
} else {
print_r($get->getLastError());
}
/**
* Sample call for getEZDO operation/method
*/
if ($get->getEZDO(new \StructType\GetEZDO()) !== false) {
print_r($get->getResult());
} else {
print_r($get->getLastError());
}
/**
* Sample call for getEZDOList operation/method
*/
if ($get->getEZDOList(new \StructType\GetEZDOList()) !== false) {
print_r($get->getResult());
} else {
print_r($get->getLastError());
}
/**
* Sample call for getWplatyCKP operation/method
*/
if ($get->getWplatyCKP(new \StructType\GetWplatyCKP()) !== false) {
print_r($get->getResult());
} else {
print_r($get->getLastError());
}
/**
* Sample call for getListaZgodEZwrotow operation/method
*/
if ($get->getListaZgodEZwrotow(new \StructType\GetListaZgodEZwrotow()) !== false) {
print_r($get->getResult());
} else {
print_r($get->getLastError());
}
/**
* Sample call for getJednostkaOrganizacyjna operation/method
*/
if ($get->getJednostkaOrganizacyjna(new \StructType\GetJednostkaOrganizacyjna()) !== false) {
print_r($get->getResult());
} else {
print_r($get->getLastError());
}
/**
* Sample call for getPrintForParcel operation/method
*/
if ($get->getPrintForParcel(new \StructType\GetPrintForParcel()) !== false) {
print_r($get->getResult());
} else {
print_r($get->getLastError());
}
/**
* Sample call for getShopEZwrotyList operation/method
*/
if ($get->getShopEZwrotyList(new \StructType\GetShopEZwrotyList()) !== false) {
print_r($get->getResult());
} else {
print_r($get->getLastError());
}
/**
* Sample call for getLibrariesForLegalDeposits operation/method
*/
if ($get->getLibrariesForLegalDeposits(new \StructType\GetLibrariesForLegalDeposits()) !== false) {
print_r($get->getResult());
} else {
print_r($get->getLastError());
}
/**
* Sample call for getPlacowkaPocztowa operation/method
*/
if ($get->getPlacowkaPocztowa(new \StructType\GetPlacowkaPocztowa()) !== false) {
print_r($get->getResult());
} else {
print_r($get->getLastError());
}
/**
* Sample call for getParcelContentList operation/method
*/
if ($get->getParcelContentList(new \StructType\GetParcelContentList()) !== false) {
print_r($get->getResult());
} else {
print_r($get->getLastError());
}
/**
* Sample call for getReturnDocumentsProfileList operation/method
*/
if ($get->getReturnDocumentsProfileList(new \StructType\GetReturnDocumentsProfileList()) !== false) {
print_r($get->getResult());
} else {
print_r($get->getLastError());
}
/**
* Sample call for getChecklistTemplateList operation/method
*/
if ($get->getChecklistTemplateList(new \StructType\GetChecklistTemplateList()) !== false) {
print_r($get->getResult());
} else {
print_r($get->getLastError());
}
/**
* Sample call for getAdditionalActivitiesList operation/method
*/
if ($get->getAdditionalActivitiesList(new \StructType\GetAdditionalActivitiesList()) !== false) {
print_r($get->getResult());
} else {
print_r($get->getLastError());
}
/**
* Samples for Clear ServiceType
*/
$clear = new \ServiceType\Clear($options);
/**
* Sample call for clearEnvelope operation/method
*/
if ($clear->clearEnvelope(new \StructType\ClearEnvelope()) !== false) {
print_r($clear->getResult());
} else {
print_r($clear->getLastError());
}
/**
* Sample call for clearEnvelopeByGuids operation/method
*/
if ($clear->clearEnvelopeByGuids(new \StructType\ClearEnvelopeByGuids()) !== false) {
print_r($clear->getResult());
} else {
print_r($clear->getLastError());
}
/**
* Samples for Upload ServiceType
*/
$upload = new \ServiceType\Upload($options);
/**
* Sample call for uploadIWDContent operation/method
*/
if ($upload->uploadIWDContent(new \StructType\UploadIWDContent()) !== false) {
print_r($upload->getResult());
} else {
print_r($upload->getLastError());
}
/**
* Samples for Download ServiceType
*/
$download = new \ServiceType\Download($options);
/**
* Sample call for downloadIWDContent operation/method
*/
if ($download->downloadIWDContent(new \StructType\DownloadIWDContent()) !== false) {
print_r($download->getResult());
} else {
print_r($download->getLastError());
}
/**
* Samples for Set ServiceType
*/
$set = new \ServiceType\Set($options);
/**
* Sample call for setAktywnaKarta operation/method
*/
if ($set->setAktywnaKarta(new \StructType\SetAktywnaKarta()) !== false) {
print_r($set->getResult());
} else {
print_r($set->getLastError());
}
/**
* Sample call for setEnvelopeBuforDataNadania operation/method
*/
if ($set->setEnvelopeBuforDataNadania(new \StructType\SetEnvelopeBuforDataNadania()) !== false) {
print_r($set->getResult());
} else {
print_r($set->getLastError());
}
/**
* Sample call for setStatusZgodyNaEZwrot operation/method
*/
if ($set->setStatusZgodyNaEZwrot(new \StructType\SetStatusZgodyNaEZwrot()) !== false) {
print_r($set->getResult());
} else {
print_r($set->getLastError());
}
/**
* Sample call for setJednostkaOrganizacyjna operation/method
*/
if ($set->setJednostkaOrganizacyjna(new \StructType\SetJednostkaOrganizacyjna()) !== false) {
print_r($set->getResult());
} else {
print_r($set->getLastError());
}
/**
* Samples for Hello ServiceType
*/
$hello = new \ServiceType\Hello($options);
/**
* Sample call for hello operation/method
*/
if ($hello->hello(new \StructType\Hello()) !== false) {
print_r($hello->getResult());
} else {
print_r($hello->getLastError());
}
/**
* Samples for Create ServiceType
*/
$create = new \ServiceType\Create($options);
/**
* Sample call for createEnvelopeBufor operation/method
*/
if ($create->createEnvelopeBufor(new \StructType\CreateEnvelopeBufor()) !== false) {
print_r($create->getResult());
} else {
print_r($create->getLastError());
}
/**
* Sample call for createAccount operation/method
*/
if ($create->createAccount(new \StructType\CreateAccount()) !== false) {
print_r($create->getResult());
} else {
print_r($create->getLastError());
}
/**
* Sample call for createProfil operation/method
*/
if ($create->createProfil(new \StructType\CreateProfil()) !== false) {
print_r($create->getResult());
} else {
print_r($create->getLastError());
}
/**
* Sample call for createShopEZwroty operation/method
*/
if ($create->createShopEZwroty(new \StructType\CreateShopEZwroty()) !== false) {
print_r($create->getResult());
} else {
print_r($create->getLastError());
}
/**
* Sample call for createParcelContent operation/method
*/
if ($create->createParcelContent(new \StructType\CreateParcelContent()) !== false) {
print_r($create->getResult());
} else {
print_r($create->getLastError());
}
/**
* Sample call for createReturnDocumentsProfile operation/method
*/
if ($create->createReturnDocumentsProfile(new \StructType\CreateReturnDocumentsProfile()) !== false) {
print_r($create->getResult());
} else {
print_r($create->getLastError());
}
/**
* Sample call for createChecklistTemplate operation/method
*/
if ($create->createChecklistTemplate(new \StructType\CreateChecklistTemplate()) !== false) {
print_r($create->getResult());
} else {
print_r($create->getLastError());
}
/**
* Samples for Update ServiceType
*/
$update = new \ServiceType\Update($options);
/**
* Sample call for updateEnvelopeBufor operation/method
*/
if ($update->updateEnvelopeBufor(new \StructType\UpdateEnvelopeBufor()) !== false) {
print_r($update->getResult());
} else {
print_r($update->getLastError());
}
/**
* Sample call for updateAccount operation/method
*/
if ($update->updateAccount(new \StructType\UpdateAccount()) !== false) {
print_r($update->getResult());
} else {
print_r($update->getLastError());
}
/**
* Sample call for updateProfil operation/method
*/
if ($update->updateProfil(new \StructType\UpdateProfil()) !== false) {
print_r($update->getResult());
} else {
print_r($update->getLastError());
}
/**
* Sample call for updateShopEZwroty operation/method
*/
if ($update->updateShopEZwroty(new \StructType\UpdateShopEZwroty()) !== false) {
print_r($update->getResult());
} else {
print_r($update->getLastError());
}
/**
* Sample call for updateParcelContent operation/method
*/
if ($update->updateParcelContent(new \StructType\UpdateParcelContent()) !== false) {
print_r($update->getResult());
} else {
print_r($update->getLastError());
}
/**
* Sample call for updateReturnDocumentsProfile operation/method
*/
if ($update->updateReturnDocumentsProfile(new \StructType\UpdateReturnDocumentsProfile()) !== false) {
print_r($update->getResult());
} else {
print_r($update->getLastError());
}
/**
* Sample call for updateChecklistTemplate operation/method
*/
if ($update->updateChecklistTemplate(new \StructType\UpdateChecklistTemplate()) !== false) {
print_r($update->getResult());
} else {
print_r($update->getLastError());
}
/**
* Samples for Move ServiceType
*/
$move = new \ServiceType\Move($options);
/**
* Sample call for moveShipments operation/method
*/
if ($move->moveShipments(new \StructType\MoveShipments()) !== false) {
print_r($move->getResult());
} else {
print_r($move->getLastError());
}
/**
* Samples for Is ServiceType
*/
$is = new \ServiceType\Is($options);
/**
* Sample call for isMiejscowa operation/method
*/
if ($is->isMiejscowa(new \StructType\IsMiejscowa()) !== false) {
print_r($is->getResult());
} else {
print_r($is->getLastError());
}
/**
* Sample call for isObszarMiasto operation/method
*/
if ($is->isObszarMiasto(new \StructType\IsObszarMiasto()) !== false) {
print_r($is->getResult());
} else {
print_r($is->getLastError());
}
/**
* Samples for Cancel ServiceType
*/
$cancel = new \ServiceType\Cancel($options);
/**
* Sample call for cancelReklamacja operation/method
*/
if ($cancel->cancelReklamacja(new \StructType\CancelReklamacja()) !== false) {
print_r($cancel->getResult());
} else {
print_r($cancel->getLastError());
}
/**
* Samples for Zamow ServiceType
*/
$zamow = new \ServiceType\Zamow($options);
/**
* Sample call for zamowKuriera operation/method
*/
if ($zamow->zamowKuriera(new \StructType\ZamowKuriera()) !== false) {
print_r($zamow->getResult());
} else {
print_r($zamow->getLastError());
}
/**
* Samples for Wyslij ServiceType
*/
$wyslij = new \ServiceType\Wyslij($options);
/**
* Sample call for wyslijLinkaOStatusieEZwrotu operation/method
*/
if ($wyslij->wyslijLinkaOStatusieEZwrotu(new \StructType\WyslijLinkaOStatusieEZwrotu()) !== false) {
print_r($wyslij->getResult());
} else {
print_r($wyslij->getLastError());
}
/**
* Samples for Delete ServiceType
*/
$delete = new \ServiceType\Delete($options);
/**
* Sample call for deleteShopEZwroty operation/method
*/
if ($delete->deleteShopEZwroty(new \StructType\DeleteShopEZwroty()) !== false) {
print_r($delete->getResult());
} else {
print_r($delete->getLastError());
}
/**
* Sample call for deleteParcelContent operation/method
*/
if ($delete->deleteParcelContent(new \StructType\DeleteParcelContent()) !== false) {
print_r($delete->getResult());
} else {
print_r($delete->getLastError());
}
/**
* Sample call for deleteReturnDocumentsProfile operation/method
*/
if ($delete->deleteReturnDocumentsProfile(new \StructType\DeleteReturnDocumentsProfile()) !== false) {
print_r($delete->getResult());
} else {
print_r($delete->getLastError());
}
/**
* Sample call for deleteChecklistTemplate operation/method
*/
if ($delete->deleteChecklistTemplate(new \StructType\DeleteChecklistTemplate()) !== false) {
print_r($delete->getResult());
} else {
print_r($delete->getLastError());
}
/**
* Samples for Order ServiceType
*/
$order = new \ServiceType\Order($options);
/**
* Sample call for orderEasyReturnSolutionLabel operation/method
*/
if ($order->orderEasyReturnSolutionLabel(new \StructType\OrderEasyReturnSolutionLabel()) !== false) {
print_r($order->getResult());
} else {
print_r($order->getLastError());
}
Don't be shy, don't hesitate to contact us for any subject, we'll be glad to help.
This platform is provided to give developpers and non developpers a way to easily consume SOAP Web Services or share their own SOAP Web Services with extra features powered by the platform.
© 2025 Providr.IO