npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

@datafire/dweet

v6.0.0

Published

DataFire integration for dweet.io

Downloads

3

Readme

@datafire/dweet

Client library for dweet.io

Installation and Usage

npm install --save @datafire/dweet
let dweet = require('@datafire/dweet').create();

.then(data => {
  console.log(data);
});

Description

Dweet.io allows users to share data from mobile, tablets, and pcs, and them to other devices and accounts across social media platforms. Dweet.io provides an API to access the different functionality of the Dweet.io service. Users can make REST calls to read and create dweets, lock and unlock things, and perform other calls. The API returns JSON and JSONP.

Actions

createAlertGET

Create an alert for a thing. A thing must be locked before an alert can be set.

dweet.createAlertGET({
  "who": "",
  "thing": "",
  "condition": "",
  "key": ""
}, context)

Input

  • input object
    • who required string: A comma separated list of Email addresses to send the alert to.
    • thing required string: A unique name of a thing. It is recommended that you use a GUID as to avoid name collisions.
    • condition required string: A condition that returns a string or a true value if a condition is met.
    • key required string: A valid key for a locked thing. If the thing is not locked, this can be ignored.

Output

Output schema unknown

dweet.for.thing.post

Create a dweet for a thing.

dweet.dweet.for.thing.post({
  "thing": "",
  "content": ""
}, context)

Input

  • input object
    • thing required string: A unique name of a thing. It is recommended that you use a GUID as to avoid name collisions.
    • key string: A valid key for a locked thing. If the thing is not locked, this can be ignored.
    • content required string

Output

Output schema unknown

dweet.quietly.for.thing.post

Create a dweet for a thing. This method differs from /dweet/for/{thing} only in that successful dweets result in an HTTP 204 response rather than the typical verbose response.

dweet.dweet.quietly.for.thing.post({
  "thing": "",
  "content": ""
}, context)

Input

  • input object
    • thing required string: A unique name of a thing. It is recommended that you use a GUID as to avoid name collisions.
    • key string: A valid key for a locked thing. If the thing is not locked, this can be ignored.
    • content required string

Output

Output schema unknown

getAlert

Get the alert attached to a thing.

dweet.getAlert({
  "thing": "",
  "key": ""
}, context)

Input

  • input object
    • thing required string: A unique name of a thing.
    • key required string: A valid key for a locked thing. If the thing is not locked, this can be ignored.

Output

Output schema unknown

get.dweets.for.thing.get

Read the last 5 cached dweets for a thing.

dweet.get.dweets.for.thing.get({
  "thing": ""
}, context)

Input

  • input object
    • thing required string: A unique name of a thing.
    • key string: A valid key for a locked thing. If the thing is not locked, this can be ignored.

Output

Output schema unknown

getLatestDweet

Read the latest dweet for a thing.

dweet.getLatestDweet({
  "thing": ""
}, context)

Input

  • input object
    • thing required string: A unique name of a thing.
    • key string: A valid key for a locked thing. If the thing is not locked, this can be ignored.

Output

Output schema unknown

getStoredAlerts

Read all the saved alerts for a thing from long term storage. You can query a maximum of 1 day per request and a granularly of 1 hour.

dweet.getStoredAlerts({
  "thing": "",
  "key": "",
  "date": ""
}, context)

Input

  • input object
    • thing required string: A unique name of a thing.
    • key required string: A valid key for a locked thing. If the thing is not locked, this can be ignored.
    • date required string: The calendar date (YYYY-MM-DD) from which you'd like to start your query. The response will be a maximum of one day.
    • hour string: The hour of the day represented in the date parameter in 24-hour (00-23) format. If this parameter is included, a maximum of 1 hour will be returned starting at this hour.
    • responseType string: Current valid parameters for this are 'csv' and 'json'. If this parameter is left blank, all responses default to hapi-json dweet-speak.

Output

Output schema unknown

get.stored.dweets.for.thing.get

Read all the saved dweets for a thing from long term storage. You can query a maximum of 1 day per request and a granularly of 1 hour.

dweet.get.stored.dweets.for.thing.get({
  "thing": "",
  "key": "",
  "date": ""
}, context)

Input

  • input object
    • thing required string: A unique name of a thing.
    • key required string: A valid key for a locked thing. If the thing is not locked, this can be ignored.
    • date required string: The calendar date (YYYY-MM-DD) from which you'd like to start your query. The response will be a maximum of one day.
    • hour string: The hour of the day represented in the date parameter in 24-hour (00-23) format. If this parameter is included, a maximum of 1 hour will be returned starting at this hour.
    • responseType string: Current valid parameters for this are 'csv' and 'json'. If this parameter is left blank, all responses default to hapi-json dweet-speak.

Output

Output schema unknown

listenForDweets

Sorry, this function uses HTTP chunked responses and cannot be tested here. Try something like: curl --raw https://dweet.io/listen/for/dweets/from/{thing}

dweet.listenForDweets({
  "thing": ""
}, context)

Input

  • input object
    • thing required string

Output

Output schema unknown

lockThing

Reserve and lock a thing.

dweet.lockThing({
  "thing": "",
  "lock": "",
  "key": ""
}, context)

Input

  • input object
    • thing required string: A unique name of a thing.
    • lock required string: A valid dweet.io lock.
    • key required string: A valid dweet.io master key.

Output

Output schema unknown

removeAlert

Remove an alert for a thing.

dweet.removeAlert({
  "thing": "",
  "key": ""
}, context)

Input

  • input object
    • thing required string: A unique name of a thing.
    • key required string: A valid key for a locked thing. If the thing is not locked, this can be ignored.

Output

Output schema unknown

removeLock

Remove a lock from thing.

dweet.removeLock({
  "lock": "",
  "key": ""
}, context)

Input

  • input object
    • lock required string: A valid dweet.io lock.
    • key required string: A valid dweet.io master key.

Output

Output schema unknown

unlockThing

Unlock a thing.

dweet.unlockThing({
  "thing": "",
  "key": ""
}, context)

Input

  • input object
    • thing required string: A unique name of a thing.
    • key required string: A valid dweet.io master key.

Output

Output schema unknown

Definitions

This integration has no definitions