README
[![NPM](https://nodei.co/npm/node-superfeedr.svg?style=flat)](https://npmjs.org/package/node-superfeedr) [![npm](https://img.shields.io/npm/v/node-superfeedr.svg?style=flat-square)]() [![Gitter](https://img.shields.io/gitter/room/dreadjr/node-superfeedr.js.svg?style=flat-square)](https://gitter.im/dreadjr/node-superfeedr)
Installation
npm install node-superfeedr
Testing
npm test
API Reference
node-superfeedr
Install:
npm install node-superfeedr
Example:
var superfeedr = require('node-superfeedr');
Testing out this
superfeedr
node-superfeedr
Install:
npm install node-superfeedr
Example:
var superfeedr = require('node-superfeedr');
Helper
superfeedr
node-superfeedr
Install:
npm install node-superfeedr
Example:
var superfeedr = require('node-superfeedr');
superfeedr/subscribers/http
Superfeedr Subscribers Http Client
Example:
var superfeedr = require('node-superfeedr');
var options = {
username: process.env.SUPERFEEDR_USERNAME || 'username',
token: process.env.SUPERFEEDR_TOKEN || 'token'
};
var client = new superfeedr.Subscribers.HttpClient(options);
Submodule: http
Param | Type | Description |
---|---|---|
[options] | Object |
override default options |
options.username | string |
Superfeedr username |
options.token | string |
Superfeedr token value |
options.endpoint | url |
Superfeedr Push Api Endpoint |
Promise
superfeedr/subscribers/http~addFeed(topic, callback, [secret], [options]) ⇒ Kind: inner method of superfeedr/subscribers/http
Param | Type | Description |
---|---|---|
topic | url |
The URL of the HTTP resource to which you want to subscribe. It cannot be more than 2048 characters long. |
callback | url |
The webhook: it's the URL to which notifications will be sent. Make sure you it's web-accessible, ie not behind a firewall. Its size is currently limited to 250 characters. |
[secret] | string |
Recommended. A unique secret string which will be used by us to compute a signature. You should check this signature when getting notifications. |
[options] | Object |
Less used options |
options.verify | string |
Will perform a PubSubHubbub verification of intent synschronously or asynschronously |
options.format | string |
If you want to receive notifications as json format (for feeds only!). You can also use an Accept HTTP header like this: Accept: application/json. If you explicitly want to receive notification as Atom. This is used by default for any resource that's either Atom or RSS. If you don't specify any, we will send you the data pulled from the HTTP resource, (excluding feeds). |
options.retrieve | string |
If set to true, the response will include the current representation of the feed as stored in Superfeedr, in the format desired. Please check our Schema for more details. |
Promise
superfeedr/subscribers/http~removeFeed(topic, [callback], [options]) ⇒ Kind: inner method of superfeedr/subscribers/http
Param | Type | Description |
---|---|---|
topic | url |
The URL of the HTTP resource to which you want to unsubscribe. |
[callback] | url |
The URL to which notifications will be sent. It is optional if you are only subscribed to the feed 'once', with a single hub.callback. If you have multiple subscriptions, you will need to supply the hub.callback parameter. It is also required if you use the hub.verify param. |
[options] | Object |
Less used options |
options.verify | string |
We will perform a PubSubHubbub verification of intent synschronously or asynschronously. |