Skip to content
A Java library to interface the Pushbullet REST API
Java
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
src/main/java/com/github/silk8192/jpushbullet
.editorconfig
.gitignore
.travis.yml
README.md
pom.xml

README.md

jpushbullet

A simple library to interface/use/access the Pushbullet API (v2) written with Java 8. Current feature set:

Ephemerals: sending clipboard, notification, and sms pushes

Chat: list, create, update, delete.

Device: list, create, update, delete.

Push: list, create, update, delete, delete all

Subscriptions: list, create, update, get channel info

User: get current user info

Dependencies:

How to use:

jpushbullet is intended to be very simple and lightweight. To start, you need to create a PushbulletClient.

PushbulletClient client = new PushbulletClient(api_key);
This creates the connection to Pushbullet's REST API and supplies the api_key used to identify users (as passed into the constructor). FYI, you can get the api key from https://www.pushbullet.com/account when logged in.

Chats:
getChats()
returns a list of all chats

createChat(the email to chat with)
returns data about the recipient

updateChat(identifing key of the chat, boolean muted)
returns data about the recipient

deleteChat(identifing key of the chat)

Device:
listDevices()
returns a list of all devices

getDevices()
returns a list of cached devices

createDevice(nickname of device, model of device, manufacturer, app version of pushbullet, icon ("desktop", "browser", "website", "laptop", "tablet", "phone", "watch", "system", "ios"), whether the device has SMS capability)
returns the new device 

deleteDevice(String iden)

Subscriptions:
listSubscriptions()
returns a list of all Subscriptions

createSubscription(the channel tag)
returns a Subscription object

updateSubscription(subscription iden, boolean muted)
returns the updated Subscription object

deleteSubscription(subscription iden)

channelInfo(channelTag, whether the method should return recent pushes)
returns a ChannelInfo object

General:
client.sendNotePush(title, body);

client.sendLinkPush(title, body, link);

sendFilePush(a message, exact filename including file extension, the file MIME type, a java File object that referneces the file)


Ephemerals:
For sms:
sendSMSPush(phone number, message, package name of application, targetDeviceIden)

For notification:
sendNotificationPush(notification title, the notification message, the name of the application, the version of the application, whether the notification is dismissable, whether the phone is rooted or not, a JPG icon that is base64 encoded, the notification id, name of the application package, the identity of the device where the notification is coming from)

For clipboard:
sendClipboardPush(the contents that should be transferred to the clipboard)

Thank you for using this!

You can’t perform that action at this time.