Show UCRM version on webhook test
| | |
| | | } elseif ($event['entity'] === 'payment') { |
| | | $synchronizer = new \SIPL\UCRM\wFirma\PaymentSynchronizer($wFirmaApi, $helper); |
| | | } elseif ($event['entity'] === 'webhook') { |
| | | echo 'Webhook OK!'; |
| | | echo 'Webhook OK! UCRM version: ' . $helper->getVersion(); |
| | | die(); |
| | | } else { |
| | | echo 'Nothing to do with entity ' . $event['entity']; |
| | |
| | | return $this->config; |
| | | } |
| | | |
| | | function getVersion() { |
| | | $response = $this->getApi()->get('/version'); |
| | | return $response['version']; |
| | | } |
| | | |
| | | function getCurrentEvent() { |
| | | if ($this->event === NULL) { |
| | | try { |