https://github.com/opencontentcoop/ocwebhookserver
https://github.com/opencontentcoop/ocwebhookserver
Last synced: 4 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/opencontentcoop/ocwebhookserver
- Owner: OpencontentCoop
- Created: 2019-12-05T17:57:11.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2024-02-26T11:21:36.000Z (over 2 years ago)
- Last Synced: 2025-10-03T07:53:32.165Z (9 months ago)
- Language: Smarty
- Size: 186 KB
- Stars: 0
- Watchers: 4
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: readme.md
Awesome Lists containing this project
README
# OpenContent Webhook Server
A webhook is a way to provide information to another app about a particular event.
The way the two apps communicate is with a simple HTTP request.
This eZPublish legacy extension allows you to configure and send webhooks easily.
### Installation
- Require package `composer require opencontent/ocwebhookserver-ls`
- Enable extension in site.ini
- Regenerate autoloads and clear cache
- Create your webhook in `/webhook/list`
- Run the worker `php extension/ocwebhookserver/bin/php/worker.php`
### Default trigger
A post publish trigger is available:
to activate it, you need to configure the workflow 'Post publish webhook' in content/after trigger
### Create new trigger
To add your own trigger:
- create a `OCWebHookTriggerInterface` implementation
- configure it in `webhook.ini [TriggersSettings]TriggerList`
- put in your code the event trigger method
```
OCWebHookEmitter::emit(
,
,
OCWebHookQueue::defaultHandler()
);
```
see for example *eventtypes/event/workflowwebhook/workflowwebhooktype.php*
### Todo
- trigger filter configurations
- payload configurations
- worker evolutions