Download the PHP package curesaba/php-subscriber without Composer
On this page you can find all versions of the php package curesaba/php-subscriber. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download curesaba/php-subscriber
More information about curesaba/php-subscriber
Files in curesaba/php-subscriber
Package php-subscriber
Short Description A PHP client library implementing a PubSubHubbub (WebSub) subscriber with hub.secret support.
License Apache-2.0
Homepage https://github.com/CureSaba/php-subscriber
Informations about the package php-subscriber
PHP PubSubHubbub (WebSub) Subscriber
This PHP library implements a subscriber for PubSubHubbub (WebSub) with support for the hub.secret parameter for secure HMAC signature verification and flexible configuration options including verify_token.
Originally written by Josh Fraser and currently maintained by CureSaba.
Released under the Apache 2.0 License.
Official package: pubsubhubbub/subscriber
Maintained fork: curesaba/php-subscriber
Install
Update your composer require block:
Or install via Composer:
Usage
Parameters
- $hub_url: The PubSubHubbub (WebSub) hub endpoint. (Required)
- $callback_url: Your endpoint to receive notifications. (Required)
- $credentials: (Optional) HTTP Basic Auth credentials for the hub.
- $secret: (Optional but recommended) Secret string for verifying HMAC signatures (
hub.secret). - $verify: (Optional) Verification mode
"async"or"sync". Default:"async". - $verify_token: (Optional) Token for intent verification.
- $lease_seconds: (Optional) Subscription lease duration in seconds.
Property Setters
All parameters (except $google_key) can also be set or changed after instantiation using the following setter methods:
setHubUrl($hub_url)setCallbackUrl($callback_url)setCredentials($credentials)setSecret($secret)setVerify($verify)setVerifyToken($verify_token)setLeaseSeconds($lease_seconds)
HMAC Signature Verification
When using hub.secret, notifications sent from the hub will include an X-Hub-Signature header.
You should verify this in your callback endpoint:
License
Apache License 2.0