[Webinar] Using RUM to Fight Latency and Supercharge Performance - Register Now!

Configuring Native NS1 Datafeeds

In situations where our integrations into third party monitoring solutions are not sufficient, NS1 offers an option to connect a webhook URL to a datafeed which will allow for remote systems to programmatically fail out an answer or answers.

Create an NS1 datafeed

Navigate to the Integrations tab, then select the Data Sources tab, and click 'Add a Data Source'.

Next, select the NS1 API source type and supply a name. Then select the option to create a new feed to attach to the new data source. Enter a name for the data feed and a label which will be used and click submit.

Once created also note the associated Feed URL. This will be the endpoint which will listen for incoming http POST data.

Connect the feed to an answer

Navigate to the record which this data feed will connect to and add a filter chain with the UP filter.  Next, click the metadata icon  next to the answer you wish to associate to the datafeed. In the metadata options, click the plug icon next to the Up metadata and select the newly added datafeed.

Construct and test the feed response

Once connected you will be able to test this datafeed and see how it reacts to incoming requests. The datafeeds are receptive to http POST method data which is used to inform them to either mark the UP metadata as either ‘true’ (or 1) and ‘false’ (or 0). The POST data should also contain the label of the feed as well. Here is an example curl command to mark the datafeed in this example as ‘false’:

curl -X POST -H "X-NSONE-Key: REMOVED" -d '{"Feed01":{"up":false}}' https://api.nsone.net/v1/feed/c304222af55edc2a8fde27b10350fd59

Using this format users can create custom scripts running on remote machines that are able to control the UP or DOWN status of an answer based on their own internal criteria.